Skip to main content

Create an App Registration

Endpoint

POST https://api.verifik.co/v2/app-registrations

An App Registration is an instance within Verifik's system that allows a user to initiate the authentication and validation process using specified project flows, email, and/or phone details. This process ensures the identity of the user and provides secure validation through various verification steps.

warning

When creating an App Registration, a token is returned in the request. You must use this token to create document validations, email validations, phone validations and biometric validations for App Registrations. This ensures the validations are related to the app registrant.

The create token is valid for 120 minutes. Do not call this endpoint again with the same email or phone to "refresh" the session — that returns 409:email_is_registered_already or 409:phone_is_registered_already. To resume an incomplete hosted enrollment, call Resend an App Registration Link and redirect the user to data.link. Product guide: Resume an Incomplete Enrollment.

Headers

NameValue
Content-Typeapplication/json
AuthorizationBearer <token>

Params

NameTypeRequiredDescription
projectstringYesThe unique ID of the project associated with this registration
projectFlowstringYesThe unique ID of the project flow that defines the registration and validation process
emailstringNoThe email address for the user to be registered. Either email or phone is required
phonestringNoThe phone number for the user to be registered (digits only, no spaces). Either email or phone is required
countryCodestringNoThe country code associated with the phone number. Required if phone is provided. Format: +123
fullNamestringNoThe full name of the person being registered
firstNamestringNoThe first name of the person being registered
lastNamestringNoThe last name of the person being registered
languagestringNoLocale for OTP and related emails during registration (for example en, es). The hosted SmartEnroll SDK sends the enrollee’s active UI language. This is not controlled by which language tab you last edited in the project-flow email template editor. Default: "en"

Request

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

async function run() {
const res = await fetch("https://api.verifik.co/v2/app-registrations", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Bearer ${process.env.VERIFIK_TOKEN}`,
},
body: JSON.stringify({
project: "507f1f77bcf86cd799439011",
projectFlow: "507f1f77bcf86cd799439015",
email: "user@example.com",
phone: "1234567890",
countryCode: "+1",
fullName: "John Doe",
language: "en",
}),
});
console.log(await res.json());
}

run();

Response

{
"data": {
"appRegistration": {
"_id": "674de8df21c72be3cc42b8a7",
"client": "507f1f77bcf86cd799439013",
"project": "507f1f77bcf86cd799439011",
"projectFlow": "507f1f77bcf86cd799439015",
"status": "STARTED",
"email": "user@example.com",
"phone": "1234567890",
"countryCode": "+1",
"currentStep": "1",
"language": "en",
"createdAt": "2024-12-02T17:05:36.788Z",
"updatedAt": "2024-12-02T17:05:36.788Z"
},
"informationValidation": {
"_id": "674de8df21c72be3cc42b8a8",
"fullName": "John Doe",
"firstName": "John",
"lastName": "Doe"
},
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
}

Notes

  • Token Generation: A JWT token is returned in the response that must be used for subsequent validation requests (email, phone, document, biometric).
  • Contact Information: Either email or phone (with countryCode) must be provided. Both can be provided.
  • Name Fields: You can use either fullName or firstName/lastName combination.
  • Phone Format: Phone numbers should contain only digits (no spaces, dashes, or other characters).
  • Country Code: Must be in format +XXX where X are digits (1-3 digits maximum).
  • Status: New app registrations start with status STARTED.
  • Language: Defaults to "en" if not provided.
  • Resume an incomplete session: Use Resend an App Registration Link. Do not recreate the registration with the same contact details.