KYCIS SDK Docs
Android

Overview

Complete Android integration guide

Android SDK Architecture

Module: android-sdk/sdk/. Package root: com.kycis.sdk.

Public Surface (AI.kt)

  • AI.init(apiKey, userId, policy = RuntimePolicy()) — Generates a UUID session_id per process init, builds RuntimeContext, wires HttpBackendClient with policy.backendBaseUrl and optional policy.clientId / policy.mappingVersion.
  • AI.setUser(id, phone?) — Delegates to runtime / backend setUser path.
  • **AI.setKycStep(step)``** — Updates runtime hint; skipped when KycStepStrategy.INFER_ONLY`.
  • AI.trackError(code, properties) — Posts error_reported with optional JSON-serializable properties; may invoke trigger evaluation when autoTriggerEnabled.
  • AI.trackValidationFailure(...) — Posts validation_failed with optional component metadata; may invoke trigger evaluation the same way as trackError.
  • AI.attach(application) — Registers LifecycleTracker once (idempotent guard).
  • AI.setStatusListener, AI.setVoiceSessionListener — Callbacks for status and VoiceSessionResult after successful session/start.
  • AI.startAssistant() — Manual start (SdkInvokeSource.MANUAL_START_ASSISTANT).
  • AI.traceHeadersForRequest(invokeSource) — Header map for host-initiated HTTP to correlate with SDK.
  • AI.onRequestPermissionsResult(...) — Forwards to SdkRuntime.handlePermissionResult when host uses non-FragmentActivity permission path.

Module Layout

  • com.kycis.sdk — public AI, InvokeSources, VoiceSessionResult
  • com.kycis.sdk.core — runtime, HTTP, lifecycle, permissions, status, trace propagation
  • com.kycis.sdk.voice — LiveKit connector, FAB, overlays

Integration Tiers

TierWhat to implementWhat you get
Tier 0 — RequiredAI.init(Application, …), AI.attach(), AI.setKycStep()Voice agent aware of current screen; trigger evaluation runs; resource defaults load
Tier 1 — RecommendedAI.registerScreenSchema + AI.trackValidationFailure(...)Backend receives screen_schema events; validation events carry structured metadata
Tier 2 — OptionalAI.reportComponentInput(), clientId / mappingVersion, AI.traceHeadersForRequest(), AI.getConfig()Redacted value hints; multi-tenant routing; log correlation; read merged config

Most teams should do Tier 0 + Tier 1.

Configuration

RuntimePolicy Defaults

  • triggerStartMode: CONFIRM_UI
  • backendBaseUrl: http://localhost:8000/v1
  • Optional clientId / mappingVersion: sent on all SDK HTTP bodies for backend screen→business mapping
  • passiveEvalEnabled: true, interval 10 seconds
  • TriggerSettings: autoTriggerEnabled true; time spent and idle signals false by default

SDK XML Config

Located in android-sdk/sdk/src/main/res/values/kycis_config.xml:

  • kycis_lazy_schema_push_default — push schemas on navigation
  • kycis_config_refresh_interval_seconds — remote config refresh interval
  • kycis_component_input_hints_masked_default — whether hints are masked

Next Steps

Continue through this section:

  1. Native Setup — initialize SDK in Application
  2. Platform Config — XML defaults and backend policy
  3. Runtime Config — dynamic config refresh behavior
  4. Triggers and Lifecycle — passive evaluation and session flow

On this page