Migrate 1.x.x to 2.x.x

Please use this guide to migrate your apps using versions 1.x.x to 2.x.x. It is recommended to migrate to latest versions of the SDKs to get the best experience and stability.

Prerequisites

Kotlin version 1.9.10 Android gradle plugin 8.1.4

Dependencies rename

Migrate from previous module specific dependencies from

implementation "com.yoco:payment-ui:$payments_sdk_version"
implementation "com.yoco.ono.android:bluetoothAndroid:$ono_sdk_version"
implementation "com.yoco.ono.android:dspreadAndroid:$ono_sdk_version"
implementation "com.yoco.ono.android:miuraAndroid:$ono_sdk_version"
implementation "com.yoco.ono.android:datecsAndroid:$ono_sdk_version"
implementation "com.yoco.ono.common:bluetooth-android:$ono_sdk_version"
implementation "com.yoco.ono.common:dspread-android:$ono_sdk_version"
implementation "com.yoco.ono.common:datecs-android:$ono_sdk_version"
implementation "com.yoco.ono.common:miura-android:$ono_sdk_version"

to

implementation "com.yoco:payment-ui:$payments_sdk_version"
implementation "com.yoco.ono.common:onoSdkAndroidWrapper:$ono_sdk_version"
implementation "com.yoco.ono.android:onoAndroid:$ono_sdk_version"
implementation "com.yoco.ono.common:core:$ono_sdk_version"
implementation "com.yoco.ono.common:bluetooth:$ono_sdk_version"
implementation "com.yoco.ono.common:dspread:$ono_sdk_version"
implementation "com.yoco.ono.common:datecs:$ono_sdk_version"
implementation "com.yoco.ono.common:miura:$ono_sdk_version"
implementation "com.yoco.ono.common:client:$ono_sdk_version"

Current latest released versions are below:

ono_sdk_version = 2.0.9

payments_sdk_version = 2.0.11

Package name updates

Update imports to match new package naming:

Rename imports from com.yoco.payments.sdk to com.yoco.payments.sdk