Table of contents
Overview
Use this method to:
- Add documents to verification flows for individual applicants.
- Add company documents to company applicant profiles.
The method gets a multipart form:
- Document JSON metadata.
- [Optionally] A document photo or scanned copy.
If the document with the same idDocType
and country
already exists, the new data will be merged with the existing one, and any existing data will be overwritten if it is present in the new object. However, a new image will always be added.
If you do not yet know the document metadata, include the mandatory idDocType
and country
fields. For example, you can send PASSPORT
and GBR
.
To add a proof of address or identity type of documents, it is advised to use the X-Return-Doc-Warnings
header with the value of true
, which allows determining if the document data is readable and acceptable before moving the applicant to the pending
status. In response, the errors or warnings array will be present.
If you encounter errors during the upload process, the image you uploaded will be marked as inactive. This means that it will not be used as the primary document for the verification step. You will need to upload another image in order to proceed with the verification process successfully. For double-sided documents (FRONT_SIDE
and BACK_SIDE
of the idDocType
value), both images will be marked as inactive, even if you have got an error for only one of them. An array of warnings just makes a notice that there might be something wrong with the document.
Note
- If a document is double-sided, submit two images and set up the
idDocSubType
properly (FRONT_SIDE
andBACK_SIDE
). Make sure to sendBACK_SIDE
ifFRONT_SIDE
was already sent, otherwise verification step will not be completed, and you will not be able to initiate a check.- Warnings and errors are shown only for the first four attempts to upload the document. For the next cases, we assume that the document should be checked within the full verification process.
- We may change the
country
andidDocType
values that were sent to us on image upload; if such a mapping is important on your side, make sure to compare these two objects from our response.
Attention
The applicant cannot be moved to the
pending
status for a check if one of the verification steps is not active (does not have active images). To check if a verification step is active, use this method.
Upload document data only
If you need to upload only the document data, use the following request:
curl -X POST \
'https://api.sumsub.com/resources/applicants/5b75a5e80a975a3ef2102a87/info/idDoc' \
-H 'Content-Type: multipart/form-data' \
-F 'metadata={
"idDocType": "PASSPORT",
"country": "GBR",
"number": "123456789",
"issuedDate": "2015-01-02",
"dob": "2000-02-01",
"placeOfBirth": "London"
}'
The response would be:
{
"idDocType": "PASSPORT",
"country": "GBR",
"issuedDate": "2015-01-02",
"number": "40111234567",
"dob": "2000-02-01",
"placeOfBirth": "London"
}
Response explained
The response is a JSON file that represents the added document information.
Tip
You can find the
imageId
of the photo in theX-Image-Id
response header.
errors
array attributes
errors
array attributesName | Description |
---|---|
forbiddenDocument | Document type or country is unsupported or unacceptable. |
differentDocTypeOrCountry | Document type or country does not match the data sent as metadata and the recognized type is forbidden by the document settings. |
missingImportantInfo | Not all required document data can be recognized. |
dataNotReadable | There is no data to be recognized from the image. |
expiredDoc | Document validity date is expired. |
documentWayTooMuchOutside | Parts of the document are cropped. |
noIdDocFacePhoto | Face is not clearly visible on the document. |
selfieFaceBadQuality | Face is not clearly visible on the selfie. |
screenRecapture | Image might be a photo of the screen. |
screenshot | Image is a screenshot. |
sameSides | Image of the same side of the document was uploaded as front and back sides. |
shouldBeMrzDocument | Sent document type should have an MRZ, but there is no readable MRZ on the image. |
shouldBeDoubleSided | Two sides of the sent document should be submitted. |
shouldBeDoublePaged | The full double-page of the document (usually, two main passport pages) are required. |
documentDeclinedBefore | The same image was uploaded and declined earlier in the same applicant. |
warnings
array attributes
warnings
array attributesName | Description |
---|---|
badSelfie | Make sure that your face and the photo in the document are clearly visible. |
dataReadability | Make sure that information in the document is easy to read. |
inconsistentDocument | Make sure that all uploaded photos are of the same document. |
maybeExpiredDoc | Your document appears to be expired. |
documentTooMuchOutside | Make sure that the document completely fits the photo. |
Supported document types
Value | Description |
---|---|
ID_CARD | ID card. |
PASSPORT | Passport. |
DRIVERS | Driving license. |
RESIDENCE_PERMIT | Residence permit or registration document in the foreign city/country. |
UTILITY_BILL | Proof of address document. |
SELFIE | Selfie with a document. |
VIDEO_SELFIE | Selfie video (can be used in WebSDK and MobileSDK). |
PROFILE_IMAGE | Profile image, i.e. avatar (in this case, no additional metadata should be sent). |
ID_DOC_PHOTO | Photo from an ID document like a photo from the passport (In this case, no additional metadata should be sent). |
AGREEMENT | Agreement, e.g. for processing personal information. |
CONTRACT | A contract. |
DRIVERS_TRANSLATION | Translation of the driving license required in the target country. |
INVESTOR_DOC | Document from an investor, e.g. documents which disclose assets of the investor. |
VEHICLE_REGISTRATION_CERTIFICATE | Certificate of vehicle registration. |
INCOME_SOURCE | Proof of income. |
PAYMENT_METHOD | Entity confirming payment (like bank card, crypto wallet, etc). |
BANK_CARD | Bank card, like Visa or Maestro. |
COVID_VACCINATION_FORM | COVID vaccination document (may contain the QR code). |
ARBITRARY_DOC | Arbitrary document. |
OTHER | Should be used only when nothing else applies. |
Specifics of adding company documents
When adding a company document, the request should contain the company document JSON metadata and a document photo or a scanned copy.
Note
Do not send documents of individuals (e.g. beneficiary identity documents) to a company applicant profile for check results consistency.
Request attributes and element fields
The following section includes the attributes and element fields that are specific for company documents.
Request headers
Name | Type | Value |
---|---|---|
Content-Type | String | multipart/form-data |
Request arguments
Name | Type | Required | Description |
---|---|---|---|
applicantId | String | Yes | Unique applicant identifier in the Sumsub system. This identifier is a random combination of 24 digits and lowercase Latin characters. It is automatically generated when the applicant is created on the Sumsub side, and can be found in the Dashboard . If the applicantId is unknown to you, use the Get applicant data (externalUserId) method to fetch it. |
Form data
Name | Type | Required | Description |
---|---|---|---|
metadata | Object | Yes | Object that represents an ID document. |
content | Binary | No | Document photo. |
Request metadata
body part fields
metadata
body part fieldsName | Type | Required | Description |
---|---|---|---|
idDocType | String | Yes | Document type. |
idDocSubType | String | No | See the supported idDocSubTypes for COMPANY_DOC . |
country | String | Yes | Three-letter code of the country that issued the document. |
Example request
curl -X POST \
'https://api.sumsub.com/resources/applicants/5e9412223cc1813b4db0b0e3/info/idDoc' \
-H 'content-type: multipart/form-data' \
-F 'metadata={"idDocType":"COMPANY_DOC","country":"GBR"}' \
-F 'content={path to file (file contents)}'
Supported company document types
The tables below include the company document types and subtypes that are supported for company verification.
Supported idDocType
s for company verification
idDocType
s for company verificationValue | Description |
---|---|
COMPANY_DOC | Default type of the document for company verification. |
TRANSPARENCY_REGISTRY_EXTRACT | Recent excerpt from a transparency company registry. |
POWER_OF_ATTORNEY | Power of attorney. |
Supported idDocSubType
s for COMPANY_DOC
:
idDocSubType
s for COMPANY_DOC
:Value | Description |
---|---|
DIRECTORS_REGISTRY | Directors registry. |
STATE_REGISTRY | Recent excerpt from a state company registry. |
INCUMBENCY_CERT | Certificate of incumbency. |
PROOF_OF_ADDRESS | Proof of address. For example, a utility bill, rent contract or an electricity bill. |
TRUST_AGREEMENT | Trust agreement. |
INFORMATION_STATEMENT | Statement of information. |
INCORPORATION_CERT | Certificate of incorporation/registration. |
INCORPORATION_ARTICLES | Memorandum/articles of incorporation/association/registration. |
SHAREHOLDER_REGISTRY | Shareholder registry. |
GOOD_STANDING_CERT | Certificate of good standing. |
POWER_OF_ATTORNEY | Power of attorney. |
OTHER | Subtype for a document when none of above subtypes apply. |
Response
The response is a JSON file that represents the document information added to the company profile.
Note
If you need to know the
imageId
of the photo, you can find it in the response headerX-Image-Id
.
Example response
{
"idDocType": "COMPANY_DOC",
"country": "USA"
}