Skip to main content
Version: Android SDK

Install

How to install the Android SDK in your app?

See the example to install the last version of the Screeb SDK dependency in a native Android app.

You can find here useful information if you are using one of these technologies:

  1. Flutter: Releases - sources - example
  2. React Native: Releases - sources - example

Maven Central

Screeb SDK Usage in CI Environments

Please note that if you are utilizing a Continuous Integration (CI) system, it is advisable to deactivate the Screeb SDK during CI execution. This precaution helps prevent the creation of numerous new anonymous users and potential exceedance of your MTU limit.

Technical requirements

The Screeb SDK is configured to work with Android SDK version 19 minimum.

The size of the SDK is approximately 13 KB.

The SDK needs the permissions INTERNET to work well.

<uses-permission android:name="android.permission.INTERNET" />

The SDK also need theses permissions if you want to use the Screeb Audio/Video feature.

<uses-permission android:name="android.permission.CAMERA"/>
<uses-permission android:name="android.permission.MICROPHONE" />
<uses-feature android:name="android.hardware.camera" android:required="true"/>
<uses-feature android:name="android.hardware.camera.autofocus"/>
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />

How to configure the Android SDK in your app?

Add Screeb as a dependency

# build.gradle
allprojects {
repositories {
mavenCentral()
}
}

implementation 'app.screeb.sdk:survey:x.x.x'

Import Screeb SDK into your package

import app.screeb.sdk.Screeb

Setup the SDK

// simple initialization
Screeb.initSdk(this, "<android-channel-id>")

// detailed initialization using a unique id and custom properties, see Identify visitors section
Screeb.initSdk(this,
"<android-channel-id>",
"<unique-user-id>", // optional
VisitorProperties().apply { // optional
this["firstname"] = "<user-firstname>"
this["lastname"] = "<user-lastname>"
this["plan"] = "<user-plan>"
this["age"] = 42
this["logged_at"] = Date()
this["authenticated"] = true
},
InitOptions(
automaticScreenDetection = true|false // optional, default: false
)
)

Fullscreen mode allows adapting screeb view bottom margin when an app is in fullscreen mode.

About SDK lifecycle

At any time, you can disable the Screeb SDK with the following command:

Screeb.close()

Next steps

1- Identify visitors

See here.

2- Event tracking

See here.

3- Screen tracking

See here.

4- Start the survey programmatically

See here.

SDK dependencies

If you face any issues with our dependencies, please contact our support team.

  • core-ktx:1.6.0
  • webkit:1.7.0
  • com.google.android.play:review:2.0.1
  • com.google.android.play:review-ktx:2.0.1