Skip to main content

EKYC

Query verified personal and business identity information via Cas ID

With the Cas ID app, Cas can verify both the customer's identity and any businesses owned by them. From there, Cas provides this API to allow customers to grant your application access to their verified information.

Steps to integrate eKYC​

Below are the steps to integrate eKYC into your product.

  1. Create a grant /grant/token with the scopes value set to ekyc.

  2. Open the Cas Link interface using the grantToken returned from the step above. See details

  3. Your customer opens the Cas ID app and scans the QR code on Cas Link.

  4. After the user completes the authorization to allow your application access to their information,
    your interface will receive a publicToken, which is used to obtain an accessToken for the grant.
    This accessToken is only valid for 5 minutes. If your application needs to access the information again after that, you must repeat from step 1.

  5. You can now call the Identity Query API.

Call API​

Create grant for eKYC​

curl --location 'https://sandbox.bankhub.dev/grant/token' \
--header 'X-BankHub-Api-Version: 2023-01-01' \
--header 'x-client-id: <CLIENT_ID_HERE>' \
--header 'x-secret-key: <SECRET_KEY_HERE>' \
--header 'Content-Type: application/json' \
--data '{
"scopes": "ekyc:personal",
"language": "vi",
"redirectUri": "https://your-domain.vn/link",
}'
info

There are two scopes, one for individuals and one for businesses:

  • Individual: ekyc:personal
  • Business: ekyc:business

For API details, see here

Exchange publicToken for accessToken​

  curl --location 'https://sandbox.bankhub.dev/grant/exchange' \
--header 'X-BankHub-Api-Version: 2023-01-01' \
--header 'x-client-id: <CLIENT_ID_HERE>' \
--header 'x-secret-key: <SECRET_KEY_HERE>' \
--header 'Content-Type: application/json' \
--data '{
"publicToken": "bdbde2bad-7685-4f95-987c-71309a4a3"
}'
info

For API details, see here

API to query verified Personal or Business Identity Information​

  curl --location 'https://sandbox.bankhub.dev/ekyc' \
--header 'X-BankHub-Api-Version: 2023-01-01' \
--header 'Authorization: <ACCESS_TOKEN_HERE>' \
--header 'x-client-id: <CLIENT_ID_HERE>' \
--header 'x-secret-key: <SECRET_KEY_HERE>'
info

For API details, see here