Get a person record from the list

Description

The method returns data about a person from the specified list (default or selected). JWT token in the header is required for access.

Request format

  • HTTP method: POST
  • URL: /person
  • Content-Type: application/json
  • Authorization: required

Request parameters

ParameterTypeWhere passedRequiredDescription
tokenstringHeaderUser JWT token

Request body (JSON)

FieldTypeRequiredDescription
tokenstringUser JWT token
list_idstringIdentifier of the person list
limitintegerMaximum number of returned records
cursorstringCursor for pagination
thumbsboolWhether to return image thumbnails
embeddingsboolWhether to return embeddings

Example request (cURL)

curl -X POST "https://api.enface.ai/person" 
  -H "Content-Type: application/json" 
  -H "Authorization: Bearer jwt.temporary.token" 
  -d '{
    "token": "jwt.temporary.token",
    "list_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "limit": 10,
    "cursor": "",
    "thumbs": true,
    "embeddings": true
  }'

Response examples

Success (200 OK)
{
  "created": "2023-10-17T09:30:47Z",
  "features": {
    "eye_distance": 63,
    "eye_left": [10, 20],
    "eye_right": [73, 20],
    "gender": "male",
    "glasses": "none",
    "yaw": 0,
    "pitch": 0,
    "roll": 0,
    "facial_hair": "none"
  },
  "fields": [
    "Jim",
    "Carry",
    "21 Solter street",
    "New York"
  ],
  "group_id": "a53910d3-44c6-40a7-98f0-0a93772495fa",
  "image_url": "https://api.enface.ai/images/7114d3d0-94a0-11ea-930e-d601cafe23fd/random/token",
  "list_id": "1ad22a7e-e5de-4a50-b066-d9f00f81ff5f",
  "person_id": "55e2c7d0-951c-11ea-83be-36b62cef36f0",
  "source_id": "ccf4c6ca-95f3-4d73-8819-13918497e59e",
  "status": "init",
  "yaw": 45
}
Error (400 Invalid schema)
{
  "message": "item with this id not found",
  "status": "error"
}
Error (401 Unauthorized request)
{
  "message": "access denied",
  "status": "failed"
}
Error (404 Invalid schema)
{
  "message": "item with this id not found",
  "status": "error"
}