Skip to main content

Create an App Login Biometric Validation

Endpoint​

POST https://api.verifik.co/v2/biometric-validations/app-login

Overview​

A Biometric Validation is an instance within Verifik's system that allows you to process and validate user identities through facial recognition and liveness detection during the login process. This endpoint is specifically designed for users who are in the middle of an app login flow.

Headers​

NameValue
Content-Typeapplication/json
AuthorizationBearer {YOUR_ACCESS_TOKEN}
warning

The JWT Token you should use when creating App Login Biometric Validations is provided from the App Login in creation.

Parameters​

NameTypeRequiredDescription
projectstringYesThe unique identifier for the project where this biometric validation will be used.
projectFlowstringYesThe unique identifier for the project flow configuration.
identifierstringYesA unique identifier for the user or session (e.g., email, phone, or custom ID).
typestringYesMust be set to login for this endpoint.
expiresAtstringNoOptional expiration date for the validation session.
redirectUrlstringNoOptional URL for redirect after validation.
webhookUrlstringNoOptional webhook URL for validation notifications.
requires2FAbooleanNoOptional flag indicating if two-factor authentication is required.
ipAddressstringNoOptional IP address of the user.
sendViaEmailbooleanNoOptional flag to send validation link via email.
emailstringNoEmail address to send validation link to (required if sendViaEmail is true).
languagestringNoLanguage for email templates (en/es). Defaults to "en".

Request​

import axios from 'axios';

const options = {
method: 'POST',
url: 'https://api.verifik.co/v2/biometric-validations/app-login',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer <your_token>'
},
data: {
project: '507f1f77bcf86cd799439011',
projectFlow: '507f1f77bcf86cd799439015',
identifier: 'user@example.com',
type: 'login',
expiresAt: '2024-12-31T23:59:59.000Z',
redirectUrl: 'https://yourapp.com/success',
webhookUrl: 'https://yourapp.com/webhook',
requires2FA: false,
ipAddress: '192.168.1.1',
sendViaEmail: true,
email: 'user@example.com',
language: 'en'
}
};

try {
const { data } = await axios.request(options);
console.log(data);
} catch (error) {
console.error(error);
}

Response​

{
"data": {
"livenessSession": {
"_id": "674de8df21c72be3cc42b8a7",
"identifier": "user@example.com",
"client": "507f1f77bcf86cd799439013",
"project": "507f1f77bcf86cd799439011",
"projectFlow": "507f1f77bcf86cd799439015",
"status": "active",
"expiresAt": "2024-12-02T17:15:35.000Z",
"createdAt": "2024-12-02T17:05:36.788Z",
"updatedAt": "2024-12-02T17:05:36.788Z"
},
"biometricValidation": {
"_id": "674de8df21c72be3cc42b8a8",
"client": "507f1f77bcf86cd799439013",
"project": "507f1f77bcf86cd799439011",
"projectFlow": "507f1f77bcf86cd799439015",
"status": "new",
"livenessSession": "674de8df21c72be3cc42b8a7",
"type": "login",
"url": "https://access.verifik.co/sign-in/507f1f77bcf86cd799439011?type=liveness",
"assignedCollection": "507f1f77bcf86cd799439016",
"collectionCode": "col_12345",
"redirectUrl": null,
"webhook": null,
"requires2FA": false,
"createdAt": "2024-12-02T17:05:36.788Z",
"updatedAt": "2024-12-02T17:05:36.788Z"
},
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
}

Features​

  • Login-Specific Validation: Designed specifically for app login biometric validation flows
  • Liveness Detection: Advanced facial recognition with anti-spoofing technology
  • Secure Sessions: Automatic creation of secure liveness sessions with expiration
  • Multiple Programming Languages: Support for JavaScript, Python, PHP, and Swift
  • Email Integration: Optional email notifications with validation links
  • Webhook Support: Real-time notifications for validation events
  • Multi-language Templates: Support for English and Spanish email templates
  • Security Features: IP address tracking and 2FA support