Delete person by ID (or multiple IDs)

Description

The method deletes one or more persons from the specified list by their identifier. A JWT token in the header is required.

Request format

  • HTTP method: POST
  • URL: /person/delete
  • 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
person_idstring[]Array of person identifiers

Example request (cURL)

curl -X POST "https://api.enface.ai/person/delete" 
  -H "Content-Type: application/json" 
  -H "Authorization: Bearer jwt.temporary.token" 
  -d '{
    "token": "jwt.temporary.token",
    "list_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "person_id": [
      "75e55780-8943-11ea-9773-e96daa282099",
      "51b755a0-8c02-11ea-830b-5a7682ee42b9"
    ]
  }'

Response examples

Success (200 OK)
{
  "message": "1 person(s) deleted",
  "status": "ok"
}
Error (400 Bad Request)
{
  "message": "invalid schema",
  "status": "error"
}
Error (401 Unauthorized)
{
  "message": "access denied",
  "status": "error"
}
Error (404 Not Found)
{
  "message": "item with this id not found",
  "status": "error"
}