Upload a KYC document
Stores one document file for a customer. This is step 1 of server-to-server verification. Upload each document, and each side of a two-sided card, in a separate call. Nothing is sent for review until you call `POST /v1/customers/kyc/start-s2s`.
Stores one document file for a customer. This is step 1 of server-to-server verification. Upload each document, and each side of a two-sided card, in a separate call. Nothing is sent for review until you call POST /v1/customers/kyc/start-s2s.
Individual and UBO customers need one identity document (PASSPORT, ID_CARD or DRIVERS) with FRONT_SIDE, plus a SELFIE. Identity documents also need country, number and validUntil. A selfie must be a JPEG or PNG.
Business customers use idDocType: COMPANY_DOC for every file and set idDocSubType to INCORPORATION_CERT, SHAREHOLDER_REGISTRY, PROOF_OF_ADDRESS and TAX_DOCUMENT (or OTHER).
Gravv checks idDocType and idDocSubType before the other metadata. An unknown type, REGISTRATION_CERTIFICATE, or a subtype that doesn't fit the type returns 400 INVALID_DOCUMENT_TYPE with the accepted values. A type that belongs on another customer returns 400 DOCUMENT_TYPE_NOT_ALLOWED, which says where it goes. A person's documents go on their associated person, and company documents go on the business.
The response message lists the documents still required before POST /v1/customers/kyc/start-s2s, or says that all are uploaded and which call to make next.
Uploading the same type and subtype again replaces the earlier file. Once the customer's KYC is completed, uploads return 409 KYC_ALREADY_COMPLETED. A KYC that is not started, pending or failed still accepts uploads. On tenants with automatic document verification, the upload that completes the required set also completes KYC.
Headers
Idempotency-KeyBody parameters
customer_idmetadataidDocTypeType of document. Individual and UBO customers may upload PASSPORT, ID_CARD, DRIVERS, SELFIE, PROOF_OF_ADDRESS or TAX_DECLARATION. To start verification they need one identity document (PASSPORT, ID_CARD or DRIVERS) with a front image, plus a SELFIE. Business customers upload only COMPANY_DOC, once for each idDocSubType.
Possible values: PASSPORT, ID_CARD, DRIVERS, SELFIE, PROOF_OF_ADDRESS, TAX_DECLARATION, COMPANY_DOC
idDocSubTypeWhich part of the document this is. Values are case-sensitive. Identity documents need FRONT_SIDE, and BACK_SIDE as a separate upload for two-sided cards. COMPANY_DOC needs one of INCORPORATION_CERT, SHAREHOLDER_REGISTRY, PROOF_OF_ADDRESS, TAX_DOCUMENT or OTHER. A business needs each of the first three, plus TAX_DOCUMENT or OTHER. Omit it for SELFIE, PROOF_OF_ADDRESS and TAX_DECLARATION.
Possible values: FRONT_SIDE, BACK_SIDE, INCORPORATION_CERT, SHAREHOLDER_REGISTRY, PROOF_OF_ADDRESS, TAX_DOCUMENT, OTHER
countrySELFIE. The response gives it as alpha-3.numberPASSPORT, ID_CARD and DRIVERS.validUntilPASSPORT, ID_CARD and DRIVERS. The format is not checked here, but the verification review may reject a bad date.issuedDatefirstNamemiddleNamelastNamedobplaceOfBirthcontentdata: prefix. The decoded file must be a JPEG, PNG or PDF. The service checks the file bytes, not the name. The maximum decoded size is 5 MB. In sandbox, keep files under about 500 KB.filenameResponse
Returns 200 OK. Document stored
datastatusAlways success.
Possible values: success
customer_iddocument_typeidDocType you sent, in upper casedocument_sub_typeidDocSubType you sentdocument_idcountrymessagePOST /v1/customers/kyc/start-s2s, or says that every required document is uploaded and names the call to make. For a business, that call waits until every associated person's KYC is completed. On tenants with automatic document verification it reads Document saved., or says that KYC was auto-approved.kyc_statuscompleted when this upload completed verification at once. Only tenants with automatic document verification see it.
Possible values: completed
errorErrors
| Status | Meaning |
|---|---|
| 200 | Document stored |
| 400 | Invalid request, or a document type that is unknown or belongs on another customer |
| 404 | Customer not found |
| 409 | The customer's KYC is already completed, so its documents can't be replaced, or a request with the same Idempotency-Key is still running. |
| 413 | The file or the request body is too large. |
| 422 | The Idempotency-Key was used before with a different body. |
| 500 | The document could not be stored |
| 503 | The service is not configured or not reachable. Retry later. |