Android SDK
Integrate the WarpLink Android SDK with Gradle to add deep linking, deferred deep links, and install attribution to your app.
Requirements: Android API 26+ (Android 8.0+), Kotlin 1.8+. A physical device is recommended for App Links verification.
Source: github.com/WarpLinkApp/warplink-android-sdk
Installation
Add the dependency to your app's build.gradle.kts:
dependencies {
implementation("app.warplink:sdk:1.1.0")
}
Sync your project with Gradle files.
Configure the SDK
Initialize WarpLink in your Application.onCreate(). Pass an onLink callback and configure() auto-registers cold-start handling and auto-fires the deferred deep link check. Your one callback receives every resolved link.
The credential below is an SDK key, created in the dashboard under API Keys > SDK key. An API key looks identical but cannot record installs: deep links still resolve, so the integration looks healthy while every attribution call is rejected.
import android.app.Application
import app.warplink.WarpLink
import app.warplink.WarpLinkOptions
class MyApp : Application() {
override fun onCreate() {
super.onCreate()
WarpLink.configure(
context = this,
apiKey = "wl_live_yoursdkkeyhere000000000000000000",
options = WarpLinkOptions(onLink = { result ->
result.onSuccess { deepLink ->
// Fired for taps AND deferred installs. Check deepLink.isDeferred.
navigateTo(deepLink)
}
})
)
}
}
Register your Application class in AndroidManifest.xml and grant internet access:
<uses-permission android:name="android.permission.INTERNET" />
<application
android:name=".MyApp"
... >
Warm Start Needs One Line
Cold start is automatic. For warm start (app already running when a link arrives), forward the new intent from your launch Activity:
override fun onNewIntent(intent: Intent) {
super.onNewIntent(intent)
WarpLink.onNewIntent(intent)
}
Set android:launchMode="singleTask" on that Activity so warm-start links reuse the existing instance.
Opt Out of Automatic Handling
WarpLink.configure(
context = this,
apiKey = "wl_live_yoursdkkeyhere000000000000000000",
options = WarpLinkOptions(
debugLogging = true, // WarpLink Logcat tag
automaticDeepLinks = false, // you call WarpLink.handleDeepLink yourself
automaticDeferredDeepLinks = false // you call WarpLink.checkDeferredDeepLink yourself
)
)
Add App Links Intent Filter
Add the intent filter to your main Activity in AndroidManifest.xml:
<activity
android:name=".MainActivity"
android:launchMode="singleTask"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<!-- WarpLink App Links -->
<intent-filter android:autoVerify="true">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" android:host="aplnk.to" />
</intent-filter>
</activity>
The android:autoVerify="true" attribute triggers automatic assetlinks.json verification at install time.
Serving links from a custom domain? Add a second <data> line for it (android:host="links.yourapp.com"), then declare it to the SDK as below.
Declare Your Link Domains
The SDK always recognizes aplnk.to. If your links are served from a custom domain, tell the SDK which domains are yours. Then a link on that domain resolves on the very first launch, with no network round trip.
This matters because the decision is synchronous. The launch intent arrives before the SDK has ever reached the server, so a domain it has not been told about is treated as somebody else's link and left to your own routing.
Declare them in code:
WarpLink.configure(
context = this,
apiKey = "wl_live_yoursdkkeyhere000000000000000000",
options = WarpLinkOptions(
linkDomains = listOf("links.yourapp.com", "go.yourapp.com"),
onLink = { result -> result.onSuccess { navigateTo(it) } }
)
)
Or declare them with no code at all, in AndroidManifest.xml. The value is a comma separated list, inside <application>:
<meta-data
android:name="app.warplink.DOMAINS"
android:value="links.yourapp.com,go.yourapp.com" />
Both forms are optional and both are additive. The SDK uses the union of aplnk.to, linkDomains, the manifest list, and the domains it learns from the server, so an app that declares nothing keeps working exactly as before.
Entries are normalized for you: whitespace is trimmed, the value is lowercased, and a full URL is reduced to its host, so https://Links.YourApp.com/ and links.yourapp.com mean the same thing. www. is left alone, because www.yourapp.com and yourapp.com are different hosts.
Get Your SHA256 Fingerprint
Register your signing key fingerprint in the WarpLink dashboard for App Links verification.
keytool -list -v -keystore ~/.android/debug.keystore \
-alias androiddebugkey -storepass androidkeytool -list -v -keystore your-release-key.keystore -alias your-aliasCopy the SHA256 value and paste it into the dashboard under Apps.
Test on a Physical Device
# Verify App Links status
adb shell pm get-app-links com.yourcompany.yourapp
# Open a test link
adb shell am start -a android.intent.action.VIEW \
-d "https://aplnk.to/abc123" com.yourcompany.yourapp
# Filter Logcat for WarpLink messages
adb logcat -s WarpLink
Next Steps
- Deep Links: Handle App Links in Activity and Compose
- Deferred Deep Links: Preserve context through Play Store installs
- Attribution: Play Install Referrer and fingerprint matching
- API Reference: Full Kotlin API documentation