Android SDK Quick Start Guide
Overview
This section shows how to integrate Spyne SDK in your Android app. Before getting started, complete the Android SDK Quick Start Guide. The quick start guide shows how to install the Spyne SDK, click your first shoot, and refer the subject on dashboard.
Install SDK
To use the Spyne Android SDK, please follow the steps required below:
Install using Android Studio and Gradle
Add the Jitpack repository to your project-level build.gradle
file at the end of repository
project-level build.gradle
allprojects {
repositories {
}
google()
mavenCentral()
maven {
}
mavenCentral()
maven {
url "https://jitpack.io"
credentials { username authToken }
}
credentials { username authToken }
Adding SDK dependency version
Add the dependency to your module-level build.gradle
file. spyne_sdk_version the latest sdk version as shared with you by the Spyne team.
module-level build.gradle
dependencies {
implementation
'com.github.Spyne-Tech:spyne-android-sdk:spyne_sdk_version'
}
Authenticating the SDK
Add the token to your module-level gradle.properties
file
module-level gradle.properties
authToken = jp_g1e1t35osldunpv5a8u4dcjovr
Initializing the SDK
Initialise the client in your Application sub-class. To generate the API Key, please click here
Java
public class SampleApp extends Application {
private static final String API_KEY = "API_KEY"
private static final String CATEGORY_ID = "cat_d8R14zUNE"
} private static final String CATEGORY_ID = "cat_d8R14zUNE"
@Override
public void onCreate() {
Spyne.init(context:this, API_KEY, CATEGORY_ID)
}
public void onCreate() {
Spyne.init(context:this, API_KEY, CATEGORY_ID)