Requirements
minSdk26 (Android 8.0)- JDK 17
- Jetpack Compose in the host app
- A physical device for capture steps
1. Get access to the packages
Artifacts are published to GitHub Packages. Ask your Legal Talent contact to add your GitHub users to the partner team, then create a classic personal access token withread:packages and repo (read).
Store the credentials in ~/.gradle/gradle.properties, never in the project:
GitHub Packages requires authentication even for public packages. On CI, inject
gpr.user / gpr.token as Gradle properties from your secrets store.2. Add the dependency
settings.gradle.kts
app/build.gradle.kts
legaltalent-ui brings in core, forensics and liveness. Use legaltalent-core alone for a headless integration.
3. Permissions and network
The SDK’s manifest already declaresCAMERA (and NFC in the NFC module); the SDK requests the runtime permission when a capture step opens. You don’t need to add anything.
Keep HTTPS only. Recommended res/xml/network_security_config.xml:
4. Create a session on your backend
Your backend creates the session with its API key and returns only theaccess_token to the app:
data.access_token to the app. See Create Session for every parameter.
5. Present the flow
environment defaults to KYCEnvironment.DEV. Always pass it explicitly: STAGING while you integrate, PRODUCTION when you go live. The token must come from the same environment.ViewModel keyed by the access token, so it survives configuration changes such as rotation.
6. Handle the result
onComplete fires once, after the last step is submitted. Treat it as a UX signal:
- Navigate away from the flow and show a “verification in progress” screen.
- Wait for your backend to receive
kyc.session.processed(or the manualapproved/rejectedevents), or pollGET /kyc/sessions/{id}from your backend. - Update the app from your backend’s state.
Android does not have an
onExit callback yet. The applicant leaves the flow with the system back gesture, handled by your navigation. The session stays open until it expires, so presenting the flow again with the same token resumes where they left off.Headless
LegalTalentError; see Reference.