Reader SDK

Update your Project to a New Version of Reader SDK

Java (Android)

Upgrade your Android Studio project to use the latest Reader SDK library modifying a build.gradle file in your project.

This topic assumes that you have followed the steps in Build on Android to configure and build an Android Studio project that uses the Reader SDK library and you want to install a newer version of the library.

Get the next available Reader SDK version number Permalink Get a link to this section

Square maintains a changelog for released Reader SDK versions. Each changelog for Reader SDK that is tagged for Android and provides an SDK version number.


Your Reader SDK repository credentials do not work with Reader SDK versions prior to the version you obtained with the Reader SDK credential for your application. If you do not know the SDK version you initially used, the best practice is to choose the latest update of Reader SDK.

Update the Reader SDK dependencies Permalink Get a link to this section

You update the build.gradle file for the module that depends on Reader SDK in your project.

Set the value of def readerSdkVersion to the Reader SDK version number that you want to build your project with:

dependencies {
  def readerSdkVersion = "{DESIRED_SDK_VERSION_NUMBER}"
  implementation "com.squareup.sdk.reader:reader-sdk-$SQUARE_READER_SDK_APPLICATION_ID:$readerSdkVersion"
  runtimeOnly "com.squareup.sdk.reader:reader-sdk-internals:$readerSdkVersion"
  // ...