Custom Flow EKYC-ANDROID
Use Custom Flow in Android when your app already has a WebView-based journey
What is Custom Flow?
Custom Flow lets you launch our EKYC flow from your own web page inside your Android app, so your users can continue the verification journey without switching between two separate WebViews.
This integration is useful when your application already includes a WebView-based flow and you want to bundle our EKYC experience into that journey with a more seamless handoff between your web content and the native SDK.
When to use Custom Flow
Use Custom Flow when:
- You already have your own website and want to connect it with our EKYC flow in one app experience.
- Your native Android app includes some screens that are rendered inside a WebView.
- You want to avoid handling one WebView for your own flow and another WebView for our EKYC site.
Except for the custom flow entry point, the Android integration is the same as the standard EKYC Android integration. This page focuses only on the parts that are different.
Custom Flow Integration
Follow the standard EKYC Android integration first. After you complete the standard setup, add the Custom Flow-specific configuration described in this page: customStartPageURL and CustomStatusListener.
customStartPageURL
Set customStartPageURL to the web page that should be shown first when the SDK starts. Use this when your user is already inside your own WebView-based journey and you want EKYC to begin from that page instead of using the default entry point.
When you set customStartPageURL, the SDK loads that URL as the first page instead of opening our default EKYC page. After the user finishes the flow on your custom page, your application must redirect the user to our EKYC URL by itself.
val ekycConfig = EkycConfig(
clientName = "{{clientName}}",
ekycServiceURL = "https://mac-portal.appmanteam.com/api/{{version}}/kyc",
tenantServiceURL = "https://mac-portal.appmanteam.com/api/v1/tenant-config",
ekycSiteURL = "https://{{clientName}}.mac.appmanteam.com/apps/identity-verification",
verificationId = "{{verificationID}}",
language = Language.THAI,
emulatorMode = false,
enableManualCaptureMode = false,
customStartPageURL = "https://{{your-domain}}/{{your-start-page}}"
)CustomStatusListener
CustomStatusListener lets your app receive status values from the Custom Flow and decide how to continue in the native layer.
ekycFragment.customStatusListener = object : CustomStatusListener {
override fun onStatus(status: String) {
// Example values: DASHBOARD, LEVEL2
Toast.makeText(
this@MainActivity,
"GOTO $status",
Toast.LENGTH_SHORT
).show()
}
}Use this callback when you want to:
- detect which step or route the Custom Flow is returning
- navigate the user to another native screen
- keep your app state in sync with the WebView-based journey
Updated 8 days ago
