Optional Risk Analysis feature is available since version 5.17.0. Risk Analysis is built in collaboration with [Sardine](https://www.sardine.ai/). Consult their [Getting Started documentation](https://docs.sardine.ai/docs/risk/getting-started) for more info on the Risk Analysis feature.

To use Incode's Risk Analysis feature, you'll need to add the Sardine SDK dependency to enable it. Sardine's SDK documentation is protected. See their documentation on [getting API access](https://docs.sardine.ai/docs/risk/api-access) if needed.

Instructions on how to provide the dependency can be found here: [https://docs.sardine.ai/docs/risk-sdk/android](https://docs.sardine.ai/docs/risk-sdk/android)

# Create onboarding session

Create an onboarding session to receive an `access_token`.

In the following command, replace `sessionKey` and `customerId` with actual values, e.g. `"sessionKey": "e821b8fe-e3b4-4d90-b792-919c8bc3341e-test"` and `"customerId": "incode-test"`.

```undefined
curl --location --request POST 'https://api.sandbox.sardine.ai/v1/identity-documents/tokens' \
--header 'Authorization: Basic ZDg5NDg1ZjMtOTA2Ny00NTliLWI2MDMtNmFlMDYyMzFjYzgwOmNlNmQ2MTE4LWM0MzktNGI2MC1hNjE4LTcxOTM5Yzk1NmU2ZQ==' \
--header 'Content-Type: application/json' \
--data-raw '{
"sessionKey": "YOUR_SESSION_KEY",
"customerId": "YOUR_CUSTOMER_ID",
"platform": "android",
"provider": "incode"
}'
```

Run the above command from the Terminal, and store the `access_token` from the response.

# Init the SDK

Once you have an `access_token`, please follow this [guide](https://developer.incode.com/docs/user-guide#init-sdk-with-external-token-no-apikey-approach) on how to initialize the SDK and provide the `access_token` as a parameter for `SessionConfig.Builder.setExternalToken(access_token)` when building `SessionConfig` before starting the flow.

# See Risk Analysis on the dashboard

Once the flow is completed, Risk Analysis results are shown on this webpage:

[https://dashboard.sandbox.sardine.ai/document-verifications](https://dashboard.sandbox.sardine.ai/document-verifications)

For access to this webpage, please contact your Incode representative.
