Skip to main content

📄 Guide

Whether you want to hand the whole KYC experience over to us or simply want no documents and no face data anywhere near your own backend, the H5 KYC guidance page is the answer: send the user to a DCS-hosted H5 page where they select their nationality, upload their document, complete the face scan and fill in their address themselves. DCS is a licensed card issuer, so the entire KYC flow is verified and stored securely on our side. Your only jobs are to hand the link to the user and to receive the result. H5 mode and API mode are alternatives; pick one:

Mental model: who does what

In H5 mode you do exactly three things; DCS carries everything else.
Division of work between DCS and the partner in H5 modeDivision of work between DCS and the partner in H5 mode

Step 1: create the user (you)

Call POST /open-api/customer/v1/create-customer to create the user and take the customerId. See Create a user.

Step 2: apply for the H5 KYC ticket (you)

Call POST /open-api/kyc-ticket/v1/apply-kyc-h5 to create the ticket. Request body (APIApplyKycH5Request)
Note that kycApplyMode follows the endpoint definition. It is not part of the standard flow guide. Send H5-RENEWAL when an existing user has to resubmit or refresh their information. This page covers first-time KYC (H5) only. For re-verification after the information expires, see Updating KYC information; for reusing KYC the user already holds under the DeCard-Managed model, see KYC information migration.
Minimum request
Response (APIApplyKycH5Response, with the common envelope stripped)
The common envelope is {code, message, messageDetail, data}: code is the business status code (SYS_SUCCESS on success) and messageDetail carries extra error detail (null on success). For what the fields mean, see Authorization declines and error codes.
Idempotency behavior
  • The kycTicketRef has not been seen before: a new INIT ticket is created.
  • The kycTicketRef already exists, belongs to the same enterprise and customer, and the ticket is still INIT: the existing ticket is returned unchanged, which is what makes retries safe.
  • Anything else, such as a mismatched owner or a ticket already at PENDING or PASSED: the call fails with one of the error codes listed below.

Call POST /open-api/card-redirect/v1/guidance-link with type=7 to turn the ticket into an H5 URL you can send to the user. Request body (the H5 KYC fields of APIGuidanceRequest) The full type enumeration, as defined by the code:
A naming discrepancy worth knowing: the code labels type=4 as apply for KYC (liveness) and defines a type=8 for updating KYC information, whereas the API reference calls type=4 face recognition and lists no type=8. This page follows the code.
Minimum request
Response The H5 URL comes back in the data field of the common envelope, as a plain string. Send that URL to the user.
H5 links expire, so get the user through the flow while the link is still valid. If it does expire, call this endpoint again for a fresh one, as long as the ticket is still INIT.

Step 4: receive the result (webhook, with a query as backup)

Webhook (recommended; DCS pushes to you). Once your webhook is configured, every ticket status change arrives as a KYC_TICKET event. For the webhook payload, see Webhook events and schema. Query as backup (you): call GET /open-api/kyc-ticket/v1/detail at any time with either kycTicketId or kycTicketRef to read the current status.

KYC ticket statuses (H5 mode)

Standard H5 mode normally shows only INIT, PENDING and PASSED; a problem in review usually leaves the ticket at PENDING pending manual intervention. The newer H5-RENEWAL route has its own statuses, RENEWAL_INIT / PENDING / RETRY / PASS / REJECT, which map back onto the ticket as INIT / PASSED / REJECTED. Regenerating a link for the same kycTicketRef still requires the ticket to be INIT: NEED_VERIFY and PENDING return in progress, PASSED returns already approved, and REJECTED returns verification failed. For the statuses used by H5-MIGRATION, see KYC information migration.

apply-kyc-h5 error codes

For how the apply-kyc-h5 error codes are grouped, see KYC reject codes; for the general and authorization error codes, see Authorization declines and error codes.

Prerequisites

  • You hold the Enterprise ApiKey / SecretKey — see First steps.
  • You have created the user (step 1) — see Create a user.
  • You have the profileId (card profile ID) from the DCS team.

Next steps

  • Once KYC is PASSED, go to Apply for a virtual card and issue the card by submitting kycTicketId and customerId with cardApplyMode=NORMAL. The same kycTicketId can be reused for any further cards you issue to that user.
  • Prefer to submit documents through the API rather than a hosted page? See Apply for KYC.
  • To read a ticket’s current status at any time, see Query KYC.