Skip to main content

List All Persons

Endpoint​

https://api.verifik.co/v2/face-recognition/persons

This endpoint allows you to bring all the people stored in Verifik for all the collections.

Headers​

Content-Type​

Type: String
Required: Required
Value: application/json

Authorization​

Type: String
Required: Required
Value: Bearer <token>

Query Parameters​

page​

Type: Number
Required: No

Page number for pagination (default: 1).

limit​

Type: Number
Required: No

Number of records per page (default: 10, max: 100).

collection​

Type: String
Required: No

Filter by specific collection ID.

status​

Type: String
Required: No

Filter by status: active, inactive, pending.

populates[]​

Type: String
Required: No

Optional array of related data to include. Available options: collections, client.

Request​

import axios from 'axios';

const options = {
method: 'GET',
url: 'https://api.verifik.co/v2/face-recognition/persons',
params: {
page: 1,
limit: 10,
status: "active",
"populates[]": ["collections"]
},
headers: {
Accept: 'application/json',
Authorization: 'jwt <tu_token>'
}
};

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

Response​

{
"success": true,
"data": [
{
"_id": "person_123456789",
"name": "John Doe",
"gender": "M",
"date_of_birth": {
"year": 1990,
"month": 1,
"day": 15
},
"nationality": "US",
"images": [
"base64_encoded_image_1",
"base64_encoded_image_2"
],
"collections": [
{
"_id": "collection_123456789",
"name": "VIP Customers",
"description": "High-value customers"
}
],
"notes": "VIP customer",
"client": "client_123456789",
"status": "active",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T10:30:00Z"
}
],
"pagination": {
"page": 1,
"limit": 10,
"total": 1,
"pages": 1
}
}

Features​

  • Person List Retrieval: Retrieve all persons with detailed information
  • Pagination Support: Navigate through large datasets with page-based pagination
  • Filtering Options: Filter by collection, status, and other criteria
  • Population Support: Include related collection and client information
  • Structured Response: Organized data format for easy integration
  • Multiple Programming Languages: Support for JavaScript, Python, PHP, and Swift
  • Error Handling: Comprehensive error responses for various scenarios