Skip to main content

Create an App Registration Document Validation

Endpoint​

POST https://api.verifik.co/v2/document-validations/app-registration

A Document Validation is an instance within Verifik's system that allows you to process and validate identity documents during the app registration process. This process ensures the authenticity of user documents and provides secure verification through various analysis methods.

warning

The JWT Token you should use when creating App Registration Document Validations is provided from the App Registration in creation. You must use the token returned when creating an App Registration to authenticate this request.

Headers​

NameValue
Content-Typeapplication/json
AuthorizationBearer <token>

Params​

NameTypeRequiredDescription
imagestringNoThe base64 encoded image of the document that will be scanned and analyzed. Either image or backImage is required
backImagestringNoThe base64 encoded image of the back side of the document that will be scanned and analyzed. Either image or backImage is required
forcebooleanNoUse force to overwrite values from previous attempts. When set to true, this will allow creating a new document validation even if one already exists for the app registration. Defaults to false

Request​

const fetch = require("node-fetch");

async function run() {
const res = await fetch("https://api.verifik.co/v2/document-validations/app-registration", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Bearer ${process.env.VERIFIK_TOKEN}`,
},
body: JSON.stringify({
image: "base64_encoded_document_image",
backImage: "base64_encoded_back_image",
force: true
}),
});
console.log(await res.json());
}

run();

Response​

{
"data": {
"documentValidation": {
"_id": "507f1f77bcf86cd799439011",
"appRegistration": "507f1f77bcf86cd799439012",
"client": "507f1f77bcf86cd799439013",
"project": "507f1f77bcf86cd799439014",
"projectFlow": "507f1f77bcf86cd799439015",
"documentType": "Passport",
"documentCategory": "ID",
"status": "ASSESSING",
"validationMethod": "OCR",
"inputMethod": "FILE_UPLOAD",
"imageValidated": false,
"namesMatch": false,
"fullNameMatchPercentage": 0,
"firstNameMatchPercentage": 0,
"lastNameMatchPercentage": 0,
"type": "validation",
"createdAt": "2025-01-01T00:00:00.000Z",
"updatedAt": "2025-01-01T00:00:00.000Z"
}
}
}

Notes​

  • App Registration Required: This endpoint requires an active app registration session. You must use the token returned from creating an App Registration.
  • At Least One Image Required: Either image or backImage (or both) must be provided in the request.
  • Document Processing: Documents are processed using OCR (Optical Character Recognition) to extract and validate information.
  • Status Values: The document validation status can be ASSESSING, VALIDATED, FAILED, or other status values depending on the validation process.
  • Credit Charging: This endpoint automatically charges credits from your SmartEnroll plan.
  • Force Flag: Use the force parameter to overwrite existing document validations if needed.