Create a Person [With Liveness detection]
Endpoint
https://api.verifik.co/v2/face-recognition/persons/search-live-face
Comprehensive service for the proper creation of persons within a collection, ensuring optimal management of individuals through the following workflow:
It first conducts a search in the collection 1:N to ensure that no duplicate person is generated within the same collection.
If no match is found stored in the collection, it proceeds to perform a Liveness Detection on the incoming selfie.
Once the above steps are completed, the service accurately creates a new person within the collection. Verifik ensures that a new person request with the same face is stored by performing the search (1:N) and additionally performs a liveness test.
NOTE: The "images" parameter is an array in which up to 3 images of the same person can be sent. If they are not of the same person, the system will not create the user correctly.
Headers
Content-Type
application/json
Authorization
Bearer <token>
Parameters
name
String
Yes
Full name of the person
images
Array
Yes
An array containing Base64-encoded images of the person. You can send up to 3 images of the same person. Images must be Base64-encoded strings.
notes
String
No
Optional notes or remarks about the person (e.g., employment status, additional details).
date_of_birth
String
No
The person's date of birth in YYYY-MM-DD
format.
nationality
String
No
The person's nationality (e.g., "Colombian").
gender
String
No
The person's gender. Accepted values: "M" (Male), "F" (Female).
min_score
Float
No
The minimum score for face matching (Search 1:N), ranging from 0
to 1
. A higher value requires a stronger match to avoid duplicates. Default is usually around 0.8
.
search_mode
String
No
Defines the search speed. Accepted values: "FAST"
(faster but potentially less accurate), "ACCURATE"
(slower but more precise). we set as default "FAST"
liveness_min_score
Float
No
The minimum liveness score, ranging from 0
to 1
. A value of 0.65
is typical, where values closer to 1
increase strictness in confirming liveness.
Request
const axios = require('axios');
let data = JSON.stringify({
"name": "Juan Miguel Trevino Morales",
"images": [
"/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAYGBgYHB...dz/9k="
],
"gender": "M",
"date_of_birth": "1992-03-02",
"nationality": "Mexican",
"notes": "Created via API",
"collection_id": "b26cb8c3-0778-4ec5-8bc4-a7cac66b5291",
"liveness_min_score": 0.7,
"min_score": 0.67,
"search_mode": "FAST"
});
let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://api.verifik.co/v2/face-recognition/persons/search-live-face',
headers: {
'Authorization': 'Bearer eyJhbGciOiJIUzkpXVCJ9.eyJjbGllbnRJZC...4Cw',
'Content-Type': 'application/json'
},
data : data
};
axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
Last updated