VeryAI Raises $10M Seed Round
Integration Methods /

Android Integration

Android Integration

1. Install the SDK

Add the dependency to your app-level build.gradle:

dependencies {
    implementation("org.very:sdk:1.0.13")
}

2. Configure your app

Add permissions to AndroidManifest.xml:

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

3. Enroll a new user

Pass null for userId to register a new user. The SDK opens a consent screen, collects the user's email, then guides them through a palm scan.

import org.very.sdk.VerySDK
import org.very.sdk.VeryConfig
import org.very.sdk.VeryResult
import org.very.sdk.VeryPresentationStyle

// Check device support first
if (!VerySDK.isSupported(context)) {
    Log.w("Very", "Device not supported")
    return
}

val config = VeryConfig(
    sdkKey = "your_sdk_key",       // from Developer Portal
    userId = null,                  // null = new enrollment
    themeMode = "dark"              // "dark" or "light"
)

VerySDK.authenticate(
    context = this,
    config = config,
    presentationStyle = VeryPresentationStyle.FULL_SCREEN
) { result: VeryResult ->
    if (result.isSuccess) {
        // Send result.code to your backend to exchange for id_token
        Log.d("Very", "Auth code: ${result.code}")
        Log.d("Very", "User ID: ${result.userId}")
    } else {
        Log.e("Very", "Error: ${result.errorType} — ${result.errorMessage}")
    }
}

4. Verify an existing user

Pass the user's ID from a previous enrollment to verify their identity.

val config = VeryConfig(
    sdkKey = "your_sdk_key",
    userId = "vu-1ed0a927-...",    // existing user's ID from previous enrollment
    themeMode = "dark"
)

VerySDK.authenticate(
    context = this,
    config = config,
    presentationStyle = VeryPresentationStyle.FULL_SCREEN
) { result: VeryResult ->
    if (result.isSuccess) {
        Log.d("Very", "Verified: ${result.code}")
    } else {
        Log.e("Very", "Error: ${result.errorType} — ${result.errorMessage}")
    }
}

5. Exchange the auth code (backend)

When authentication succeeds, the SDK returns an authorization code in result.code. Send this to your backend, which exchanges it for an id_token:

POST https://api.very.org/oauth2/token
Content-Type: application/x-www-form-urlencoded

grant_type=authorization_code
&client_id=your_client_id
&client_secret=your_client_secret
&code=AUTH_CODE_FROM_SDK
&redirect_uri=your_redirect_uri

Response:

{
  "access_token": "eyJhbGciOi...",
  "token_type": "Bearer",
  "expires_in": 3600,
  "id_token": "eyJhbGciOi..."
}

Decode the id_token JWT to get the user's identity:

{
  "iss": "https://connect.very.org",
  "sub": "vu-1ed0a927-a336-45dd-9c73-20092db9ae8d",
  "aud": ["your_client_id"],
  "email": "user@example.com",
  "exp": 1761013475,
  "iat": 1761009875
}
  • For enrollment: store the sub (user ID) — use it for future verifications
  • For verification: confirm the sub matches the expected user

VeryConfig

Parameter Type Description
sdkKey String Your SDK API key from the Developer Portal
userId String? null for enrollment, user ID for verification
language String? Locale code (e.g. "en", "es"). Defaults to device language.
themeMode String "dark" (default) or "light"
baseUrl String? Override API endpoint (for staging/testing)

VeryResult

Property Type Description
isSuccess Boolean true if authentication completed successfully
code String Authorization code to exchange for id_token
userId String The user's VeryAI ID
signedToken String? Signed JWT token (when available)
errorType VeryErrorType? Typed error code (see Error Handling)
errorMessage String? Human-readable error message

Presentation styles

  • FULL_SCREEN — full-screen activity (default)
  • BOTTOM_SHEET — bottom sheet dialog

Important: The client_secret for token exchange must only be stored on your backend. Never embed it in the mobile app.

VeryAI

Get the VeryAI app

Scan the QR code to download the app