LUNA Backport 4 API (v.1.2.71)

Download OpenAPI specification:Download

VisionLabs Luna Backport 4 API. The API version is 5.

OpenAPI specification is the only valid document providing up-to-date information about the service API.

The specification can be used:

  • By documentation generation tools to visualize the API.
  • By code generation tools.

All the documents and code generated using this specification can include inaccuracies and should be carefully checked.

OpenAPI specification can be received using the "/docs/spec" resource. The "Accept" header should be set to "application/x-yaml".

Authentication

BasicAuth

Basic authorization with login and password. See accounts for details. Represents base64-encoded "username:password" credentials

Security Scheme Type HTTP
HTTP Authorization Scheme basic

LunaAccountIdAuth

Authorization using Luna-Account-Id header. Deprecated. If Authorization header specified, Luna-Account-Id will be ignored.

Security Scheme Type HTTP
HTTP Authorization Scheme Luna-Account-Id header

version

get version

get versions of services

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{
  • "luna-api": {
    },
  • "luna-faces": {
    },
  • "luna-image-store-faces-samples": {
    },
  • "luna-image-store-bodies-samples": {
    },
  • "luna-image-store-images": {
    },
  • "LUNA PLATFORM": {
    },
  • "luna-handlers": {
    },
  • "luna-events": {
    },
  • "luna-matcher-proxy": {
    },
  • "luna-tasks": {
    },
  • "luna-backport4": {
    }
}

version options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

accounts

create account

create a new account

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid> ^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]...
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

Account ID for new account creation.

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
login
required
string (login) [ 3 .. 128 ] characters ^[a-z0-9_\-\.]+@[a-z]+\.[a-z]{2,}$

account email

password
required
string (password) [ 3 .. 128 ] characters

account password

account_type
required
string (account_type_for_creation)
Enum: "advanced_user" "user"

specified user account type:

  • user - allows to interact with its own data

  • advanced_user - allows to interact with its own data and view other accounts data

description
string (account_description) <= 128 characters
Default: ""

account description

Responses

Request samples

Content type
application/json
{
  • "login": "mylogin",
  • "password": "string",
  • "account_type": "advanced_user",
  • "description": "main admin account"
}

Response samples

Content type
application/json
{
  • "account_id": "557d54ec-29ad-4f3c-93b4-c9092ef12515",
  • "url": "/1/account"
}

accounts options

Get options for the resource.

header Parameters
Luna-Account-Id
string <uuid> ^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]...
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

Account ID for new account creation.

Content-Type
string
Value: "application/json"

content type is application/json.

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get account

get account

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "account_id": "557d54ec-29ad-4f3c-93b4-c9092ef12515",
  • "login": "mylogin",
  • "account_type": "advanced_user",
  • "description": "main admin account"
}

patch account

patch account. At least one field must be specified

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
login
string (login) [ 3 .. 128 ] characters ^[a-z0-9_\-\.]+@[a-z]+\.[a-z]{2,}$

account email

password
string (password) [ 3 .. 128 ] characters

account password

account_type
string (account_type_for_creation)
Enum: "advanced_user" "user"

specified user account type:

  • user - allows to interact with its own data

  • advanced_user - allows to interact with its own data and view other accounts data

description
string (account_description) <= 128 characters
Default: ""

account description

Responses

Request samples

Content type
application/json
{
  • "login": "mylogin",
  • "password": "string",
  • "account_type": "advanced_user",
  • "description": "main admin account"
}

Response samples

Content type
application/json
Example
{
  • "error_code": 12022,
  • "desc": "Bad/incomplete input data",
  • "detail": "Failed to validate input json. Path: 'extra_field', message: 'extra fields not permitted'"
}

accounts options

Get options for the resource.

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

verify credentials

Verify account or login with password

  • In the case of success account id verification, account_type will be returned
  • In the case of success login/password verification, account_id and account_type will be returned
  • In the case of failure verification, error will be returned
header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
One of
login
required
string (login) [ 3 .. 128 ] characters ^[a-z0-9_\-\.]+@[a-z]+\.[a-z]{2,}$

account email

password
required
string (password) [ 3 .. 128 ] characters

account password

Responses

Request samples

Content type
application/json
Example
{
  • "login": "mylogin",
  • "password": "string"
}

Response samples

Content type
application/json
{
  • "account_type": "advanced_user",
  • "account_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e"
}

credentials verifier options

Get options for the resource.

header Parameters
Content-Type
string
Value: "application/json"

content type is application/json.

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

samples

detect faces

Detect faces in input images.

The request enables you to detect faces in input images, create samples, and estimate face properties.

You can specify thresholds for the head angles. If a head angle exceeds the specified threshold the image is not processed.

The estimated face properties are not saved to the Faces database. They are only returned in the response.

query Parameters
estimate_head_pose
integer (estimate_head_pose)
Default: 0
Enum: 0 1

whether to estimate head pose in the image. Not supported with warped images (see warped_image parameter).

estimate_emotions
integer (estimate_emotions)
Default: 0
Enum: 0 1

whether to estimate emotions in the image.

detect_landmarks68
integer (detect_landmarks68)
Default: 0
Enum: 0 1

whether to detect basic 68-point facial landmarks in the image. Not supported with warped images (see warped_image parameter).

estimate_exif
integer (extract_exif)
Default: 0
Enum: 0 1

whether to extract EXIF meta information from input JPEG images.

Exact output will vary since there are no mandatory requirements for both authoring software and digital cameras how to write the data.

This function will only parse the tags and output their names and values as they are. Please refer to JEITA CP-3451 EXIF specification for details.

estimate_quality
integer (estimate_quality)
Default: 0
Enum: 0 1

whether to estimate input face image quality. Each of the following parameters is estimated: light, darkness, saturation and blur

estimate_gaze
integer (estimate_gaze)
Default: 0
Enum: 0 1

whether to estimate eye gaze in the image. Not supported with warped images (see warped_image parameter).

estimate_eyes_attributes
integer (estimate_eyes_attributes)
Default: 0
Enum: 0 1

whether to estimate eye attributes in the image. Not supported with warped images (see warped_image parameter).

estimate_mouth_attributes
integer (estimate_mouth_attributes)
Default: 0
Enum: 0 1

whether to estimate mouth attributes in the image.

pitch_threshold
integer (pitch_threshold) [ 0 .. 180 ]
Example: pitch_threshold=180

maximum deviation pitch angle from 0.

roll_threshold
integer (roll_threshold) [ 0 .. 180 ]
Example: roll_threshold=180

maximum deviation roll angle from 0.

yaw_threshold
integer (yaw_threshold) [ 0 .. 180 ]
Example: yaw_threshold=180

maximum deviation yaw angle from 0.

warped_image
integer (warped_image)
Default: 0
Enum: 0 1

Whether input image is a sample or not.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Enum: "image/jpeg" "image/png" "image/bmp" "image/x-portable-pixmap" "image/tiff" "multipart/form-data" "application/json" "image/x-jpeg-base64" "image/x-png-base64" "image/x-bmp-base64" "image/x-tiff-base64" "image/x-portable-pixmap-base64"
Request Body schema:
string <binary>

Responses

Request samples

Content type
No sample

Response samples

Content type
application/json
{
  • "failed_images": {
    },
  • "succeeded_images": [
    ]
}

detector options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

save sample

Save sample to the storage.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Enum: "image/jpeg" "image/png" "image/bmp" "image/tiff" "image/gif" "image/x-portable-pixmap"
Request Body schema:
string <binary> (image_binary)

The sample has the following properties

  • its size is always 250x250 pixels
  • it's always in RGB color format
  • it always contains just a single face
  • the face is always centered and rotated so that imaginary line between the eyes is horizontal.

Responses

Response samples

Content type
application/json
{
  • "sample_id": "b5d6fd45-fcca-453d-ac05-3e594054b813",
  • "url": "/5/samples/b5d6fd45-fcca-453d-ac05-3e594054b813"
}

samples options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get sample

Get sample by ID.

path Parameters
sample_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515
header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

check to exist a sample

Check existence of the sample with id=sample_id.

path Parameters
sample_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515
header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

remove sample

Remove sample by ID.

path Parameters
sample_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515
header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

sample options

get options for the resource

path Parameters
sample_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515
header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

attributes

extract attributes

Extract descriptors and basic attributes from samples. WARNING: Extracted attributes are temporary. Lifetime of temporary attributes can be configured using ATTRIBUTES_STORAGE_POLICY.MAX_TTL setting.

query Parameters
score_threshold
number (score_threshold) [ 0 .. 1 ]
Default: 0
Example: score_threshold=0.74

descriptor quality score threshold. The higher the quality score for the image, the better the extraction results.

All the attributes with a quality score below the threshold will be ignored (and not stored in the DB). The function will proceed as usual with all the remaining descriptors (if left).

Consult VisionLabs about the recommended value of this parameter.

Note! This parameter is not related to the image quality estimated in the detect faces request (estimate_quality request parameter).

extract_descriptor
integer (extract_descriptor)
Default: 1
Enum: 0 1
Example: extract_descriptor=1

whether to extract face descriptor(s).

extract_basic_attributes
integer (extract_basic_attributes)
Default: 0
Enum: 0 1

whether to extract basic attributes (gender, age, ethnicity).

aggregate_attributes
integer (aggregate_attributes)
Default: 0

whether to aggregate face attributes.

If the value is set to "0", a descriptor and basic attributes are extracted for each sample.

If the value is set to "1", you can create an aggregated descriptor, receive aggregated basic attributes, or both. The behavior depends on the extract_basic_attributes and extract_descriptor parameters:

  • If extract_descriptor is enabled, all the samples in the request will be used to create a single descriptor. An aggregated descriptor gives you more accurate results upon descriptors comparison.

  • If extract_basic_attributes is enabled, all the samples in the request will be used to extract basic attributes. Age, gender and ethnicity values received from several samples are more precise.

Make sure that all the samples in the request belong to the same person.

If there are several faces in the input image, an error occurs.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
Array ()
string <uuid4> (sample_id) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...

sample ID.

Responses

Request samples

Content type
application/json
[
  • "b668c4a5-2191-476e-a261-3b4f9ce2e25e"
]

Response samples

Content type
application/json
[
  • {
    }
]

extractor options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get attributes ids

Get temporary attributes IDs by filters. WARNING: Resource works with temporary attributes. Lifetime of temporary attributes can be configured using ATTRIBUTES_STORAGE_POLICY.MAX_TTL setting.

query Parameters
attribute_ids
required
string <list of uuid4>
Example: attribute_ids=8950722f-3fd4-4223-b48f-03f95f0e8dfb,346a5645-ec89-4806-820a-dbcb6e0dc38

list of comma-separated temporary attribute ids.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "attributes": [
    ]
}

attributes options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get attributes count

Count temporary attributes. WARNING: Resource works with temporary attributes. Lifetime of temporary attributes can be configured using ATTRIBUTES_STORAGE_POLICY.MAX_TTL setting.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
text/plain
123

attributes count options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get basic attributes

Get basic attributes (gender, age, ethnicity) by temporary attribute ID. If temporary attribute with specified ID does not exist, try to get face attribute with face_id equal to attribute_id.

path Parameters
attribute_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

attribute id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "create_time": "2019-08-24T14:15:22Z",
  • "basic_attributes": {
    }
}

check attributes existence

Check the existence of the attribute with the ID equal to attribute_id. If temporary attribute with specified ID does not exist, try to check face attribute existence with face_id equal to attribute_id.

path Parameters
attribute_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

attribute id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

delete attributes

Delete the attribute by its ID. If temporary attribute with specified ID does not exist, try to delete face attribute existence with face_id equal to attribute_id.

path Parameters
attribute_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

attribute id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

attribute options

get options for the resource

path Parameters
attribute_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

attribute id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get samples of attributes

Get samples associated with attribute ID. If temporary attribute with specified ID does not exist, try to get face samples with face_id equal to attribute_id.

path Parameters
attribute_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

attribute id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
[
  • {
    }
]

attribute samples options

get options for the resource

path Parameters
attribute_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

attribute id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

faces

create face

Create a new face.

The face can be attached to one or several lists.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema:
external_id
string (face_external_id) <= 36 characters
Default: ""

user-defined external ID for the face. External ID can be used to link several faces which belong to one person.

attribute_id
string <uuid4> (attribute_id) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...

attribute ID. This ID links the descriptor, the face attributes, the sample, and the face received from a single image.

user_data
string (face_user_data) <= 128 characters
Default: ""

user data associated with face

avatar
string <uri-reference> (avatar) <= 256 characters
Default: ""

avatar is a visual representation of a face.

The avatar can be used in the user interface.

You can use a sample or an external image as the avatar.

lists
Array of strings <uuid4> (list_id) non-empty

luna lists for linking face with them.

event_id
string <uuid4> Nullable ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...

the event ID associated with the face creation.

Responses

Request samples

Content type
{}

Response samples

Content type
application/json
{
  • "face_id": "b5d6fd45-fcca-453d-ac05-3e594054b813",
  • "url": "/5/faces/b5d6fd45-fcca-453d-ac05-3e594054b813"
}

get faces

Get faces according to filters.

query Parameters
page
integer >= 1
Default: 1

a page number.

page_size
integer [ 1 .. 1000 ]
Default: 10

the number of items on page.

time__lt
string <date-time> (time)
Example: time__lt=2018-08-11T09:11:41.674Z

upper bound for object create_time.

time__gte
string <date-time> (time)
Example: time__gte=2018-08-11T09:11:41.674Z

lower included bound for object create_time.

face_ids
string <list of uuid4>
Example: face_ids=8950722f-3fd4-4223-b48f-03f95f0e8dfb,346a5645-ec89-4806-820a-dbcb6e0dc38

list of comma-separated face ids.

external_id
string <= 36 characters

external ID. When filtering by an external ID, you must specify the full external_id value.

user_data
string
Example: user_data=user_data_text

find all objects with user_data that is similar to this parameter. You can specify only part of the user_data value for this filter.

list_id
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: list_id=557d54ec-29ad-4f3c-93b4-c9092ef12515

id of a list that contains faces.

targets
string
Enum: "face_id" "attribute_id" "event_id" "user_data" "create_time" "external_id" "avatar" "lists"
Example: targets=face_id,user_data

Comma-separated list of face fields. If set, each face from result will contain only specified fields, otherwise, faces with all the fields will be returned.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
[
  • {
    }
]

faces options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get face count

Count faces according to the filters.

query Parameters
time__lt
string <date-time> (time)
Example: time__lt=2018-08-11T09:11:41.674Z

upper bound for object create_time.

time__gte
string <date-time> (time)
Example: time__gte=2018-08-11T09:11:41.674Z

lower included bound for object create_time.

face_ids
string <list of uuid4>
Example: face_ids=8950722f-3fd4-4223-b48f-03f95f0e8dfb,346a5645-ec89-4806-820a-dbcb6e0dc38

list of comma-separated face ids.

external_id
string <= 36 characters

external ID. When filtering by an external ID, you must specify the full external_id value.

user_data
string
Example: user_data=user_data_text

find all objects with user_data that is similar to this parameter. You can specify only part of the user_data value for this filter.

list_id
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: list_id=557d54ec-29ad-4f3c-93b4-c9092ef12515

id of a list that contains faces.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
text/plain
105

faces count options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get face

Get face by ID.

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of the face (face_id received in the "create face" request).

query Parameters
targets
string
Enum: "face_id" "attribute_id" "event_id" "user_data" "create_time" "external_id" "avatar" "lists"
Example: targets=face_id,user_data

Comma-separated list of face fields. If set, each face from result will contain only specified fields, otherwise, faces with all the fields will be returned.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "face_id": "426542d6-5509-4e5b-8a01-e2abd5c0a8c6",
  • "external_id": "2xQ2gprbMUePw1s9gw9fvA==",
  • "attribute_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "user_data": "fox1991",
  • "create_time": "2018-08-11T09:11:41.674Z",
  • "lists": [
    ],
  • "event_id": "f9687459-986b-406d-9c1f-0d6289be5256"
}

patch face

Update face fields: user_data, external_id, attribute_id.

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of the face (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
external_id
string <= 36 characters

user-defined external ID for the face.

attribute_id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...

the attribute ID associated with the face.

event_id
string <uuid4> Nullable ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...

the event ID associated with the face creation.

user_data
string <= 36 characters

user-defined data for the face.

avatar
string <uri-reference> (avatar) <= 256 characters
Default: ""

avatar is a visual representation of a face.

The avatar can be used in the user interface.

You can use a sample or an external image as the avatar.

Responses

Request samples

Content type
application/json
{}

Response samples

Content type
application/json
{}

remove face

Remove face by ID.

When a face is removed, attributes (descriptors and basic attributes) linked to the face are deleted. Samples linked to the face are not deleted.

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of the face (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

check to exist a face

Check a face with id=face_id existence

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of the face (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

face options

get options for the resource

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of the face (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get face attributes

Get face attributes.

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

face id (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "age": 20,
  • "gender": 1,
  • "ethnic_group": 2,
  • "create_time": "2018-08-11T09:08:29.414Z",
  • "attribute_id": "00000000-0000-4000-a000-000000000000"
}

face attributes options

get options for the resource

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

face id (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get samples of faces

Get samples associated with the attribute ID linked to the face.

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of the face (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
[
  • {
    }
]

face attributes samples options

get options for the resource

path Parameters
face_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of the face (face_id received in the "create face" request).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

lists

create list

Create a new list.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
user_data
required
string (list_user_data) <= 128 characters
Default: ""

user data associated with list

Responses

Request samples

Content type
application/json
{
  • "user_data": "list of good persons"
}

Response samples

Content type
application/json
{
  • "list_id": "b5d6fd45-fcca-453d-ac05-3e594054b813",
  • "url": "/lists/b5d6fd45-fcca-453d-ac05-3e594054b813"
}

get lists

Get lists according to the filters.

query Parameters
create_time__lt
string <date-time> (time)
Example: create_time__lt=2018-08-11T09:11:41.674Z

upper bound for list create_time.

create_time__gte
string <date-time> (time)
Example: create_time__gte=2018-08-11T09:11:41.674Z

lower included bound for list create_time.

last_update_time__lt
string <date-time> (time)
Example: last_update_time__lt=2018-08-11T09:11:41.674Z

upper excluded bound for list last_update_time.

last_update_time__gte
string <date-time> (time)
Example: last_update_time__gte=2018-08-11T09:11:41.674Z

lower included bound for list last_update_time.

page
integer >= 1
Default: 1

a page number.

page_size
integer [ 1 .. 10000 ]
Default: 10

the number of items on page.

user_data
string
Example: user_data=user_data_text

find all objects with user_data that is similar to this parameter. You can specify only part of the user_data value for this filter.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
[
  • {
    }
]

lists options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get list count

Count lists according to the filters.

query Parameters
user_data
string
Example: user_data=user_data_text

find all objects with user_data that is similar to this parameter. You can specify only part of the user_data value for this filter.

create_time__lt
string <date-time> (time)
Example: create_time__lt=2018-08-11T09:11:41.674Z

upper bound for list create_time.

create_time__gte
string <date-time> (time)
Example: create_time__gte=2018-08-11T09:11:41.674Z

lower included bound for list create_time.

last_update_time__lt
string <date-time> (time)
Example: last_update_time__lt=2018-08-11T09:11:41.674Z

upper excluded bound for list last_update_time.

last_update_time__gte
string <date-time> (time)
Example: last_update_time__gte=2018-08-11T09:11:41.674Z

lower included bound for list last_update_time.

list_ids
string <list of uuid4>

list of comma-separated list ids.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
text/plain
15

lists count options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get list

Get list by id

path Parameters
list_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

list id (list_id received in the "create list" request)

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "list_id": "c004aae2-f191-4a1a-9d2a-e5894f8cecbf",
  • "user_data": "good guys",
  • "create_time": "2018-08-11T09:11:41.674Z",
  • "last_update_time": "2018-08-11T09:11:41.674Z"
}

check list existence

Check existence of the list with id=list_id.

path Parameters
list_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

list id (list_id received in the "create list" request)

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

update list

Update the user_data field of the list.

path Parameters
list_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

list id (list_id received in the "create list" request)

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
user_data
required
string (list_user_data) <= 128 characters
Default: ""

user data associated with list

Responses

Request samples

Content type
application/json
{
  • "user_data": "list of good persons"
}

Response samples

Content type
application/json
{}

delete list

Delete list by id

path Parameters
list_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

list id (list_id received in the "create list" request)

query Parameters
with_faces
integer (int01)
Default: 0
Enum: 0 1

whether to delete list with all its' faces

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

list options

get options for the resource

path Parameters
list_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

list id (list_id received in the "create list" request)

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

attach/detach faces to the list

Attach or detach faces to the list.

path Parameters
list_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

list id (list_id received in the "create list" request)

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
action
required
string
Enum: "attach" "detach"

expected action with list and faces.

face_ids
required
Array of strings <uuid4> (face_id) non-empty

faces to attach or detach to/from list.

Responses

Request samples

Content type
application/json
{
  • "action": "attach",
  • "face_ids": [
    ]
}

Response samples

Content type
application/json
Example
{}

link options

get options for the resource

path Parameters
list_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

list id (list_id received in the "create list" request)

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

matcher

matching

Matcher API allows to submit tasks to a service that searches for faces similar to a given reference(s) by matching them.

Note! Descriptors must be extracted for reference(s) and candidate(s). Objects without descriptors cannot be matched.

The sources for references are events, attributes, face external IDs and faces. The sources for candidates are faces and lists.

If reference source is attribute and there is face with specified ID, matching will be executed against attributes of this face.

query Parameters
limit
integer [ 1 .. 100 ]
Default: 3

count of match result for each reference by every candidate list.

targets
string
Enum: "face_id" "attribute_id" "event_id" "user_data" "create_time" "external_id" "avatar" "lists"
Example: targets=face_id,user_data

Comma-separated list of candidate face fields to enrich the match result. If set, each face from result will contain specified fields besides the "face_id", otherwise, faces with all fields will be returned.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Content-Type
string
Value: "application/json"
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
required
object

candidates for matching. You can specify the array of face IDs or the array of lists.

required
Array of Face_Reference (object) or Event_Reference (object) or Attribute_Reference (object) or External_Face_Reference (object) [ 1 .. 30 ] items

references for matching. Each reference is matched with all the given candidates. You can specify one or several references of one or several types.

Responses

Request samples

Content type
application/json
{
  • "candidates": {
    },
  • "references": [
    ]
}

Response samples

Content type
application/json
[
  • {
    }
]

matcher options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

handlers

create handler

Create a new handler.

The handler determines the list of rules (policies) for the processing of input images.

After the handler is created, you should use the "create events" request to process images using the handler.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
description
required
string <= 128 characters

description of the handler.

Use it to distinguish the handler from other created handlers and filter handlers using corresponding requests.

required
object (Policies) Nullable

the set of rules, which determine input images processing.

Responses

Request samples

Content type
application/json
{
  • "description": "Handler example",
  • "policies": {
    }
}

Response samples

Content type
application/json
{
  • "handler_id": "b5d6fd45-fcca-453d-ac05-3e594054b813",
  • "url": "/5/handlers/b5d6fd45-fcca-453d-ac05-3e594054b813"
}

get handlers

Get handlers by filters.

query Parameters
page
integer >= 1
Default: 1

a page number.

page_size
integer [ 1 .. 1000 ]
Default: 10

the number of items on page.

description
string

find all the handlers with description similar to this parameter.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
[
  • {
    }
]

handlers options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get handler count

Count handlers.

query Parameters
description
string

Find all the handlers with description similar to this parameter.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "handlers_count": 1
}

handler count options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get handler

Get handler by ID.

path Parameters
handler_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

handler id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "handler_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "description": "string",
  • "policies": {
    },
  • "create_time": "2019-08-24T14:15:22Z",
  • "last_update_time": "2019-08-24T14:15:22Z"
}

update handler

Update a handler. You cannot update a part of a handler, so you must specify all the fields for your handler.

path Parameters
handler_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

handler id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
description
required
string <= 128 characters

description of the handler.

Use it to distinguish the handler from other created handlers and filter handlers using corresponding requests.

required
object (Policies) Nullable

the set of rules, which determine input images processing.

Responses

Request samples

Content type
application/json
{
  • "description": "Handler example",
  • "policies": {
    }
}

Response samples

Content type
application/json
Example
{}

check to exist a handler

Check a handler with id=handler_id existence.

path Parameters
handler_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

handler id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

remove handler

Remove handler by id.

path Parameters
handler_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

handler id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

handler options

get options for the resource

path Parameters
handler_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

handler id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

events

generate events

Process images using the specified handler and generate events.

If the Events service support is disabled on the server, events will not be saved to the database.

path Parameters
handler_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

handler id

query Parameters
external_id
string (event_external_id) <= 36 characters
Default: ""
Example: external_id=3.1415926

external ID for created faces.

user_data
string (event_user_data) <= 128 characters
Default: ""
Example: user_data=save event

User data for created faces

warped_image
integer (warped_image)
Default: 0
Enum: 0 1

Whether input image is a sample or not.

aggregate_attributes
integer (aggregate_attributes)
Default: 0

whether to aggregate face attributes.

If the value is set to "0", a descriptor and basic attributes are extracted for each sample.

If the value is set to "1", you can create an aggregated descriptor, receive aggregated basic attributes, or both. The behavior depends on the extract_basic_attributes and extract_descriptor parameters:

  • If extract_descriptor is enabled, all the samples in the request will be used to create a single descriptor. An aggregated descriptor gives you more accurate results upon descriptors comparison.

  • If extract_basic_attributes is enabled, all the samples in the request will be used to extract basic attributes. Age, gender and ethnicity values received from several samples are more precise.

Make sure that all the samples in the request belong to the same person.

If there are several faces in the input image, an error occurs.

source
string (Source) <= 128 characters
Example: source=Main_hall_camera

Additional information, provided by user with event.

tags
Array of strings (tag) >= 0 items
Example: tags=tag_1,tag_2

A comma-separated list of tags. Each event from result will contain all of the given tags. Each tag can be at most 36 characters.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Luna-Event-Time
string <date-time> (time)
Examples:
  • - time with timezone
  • - utc time

user defined event time. All events will be saved with this time as "create_time". Format of time is rfc3339. All other format is ignored.

Content-Type
string
Enum: "image/jpeg" "image/png" "image/bmp" "image/x-portable-pixmap" "image/tiff" "multipart/form-data" "application/json" "image/x-jpeg-base64" "image/x-png-base64" "image/x-bmp-base64" "image/x-tiff-base64" "image/x-portable-pixmap-base64"
Request Body schema:
string <binary>

Responses

Request samples

Content type
No sample

Response samples

Content type
application/json
{
  • "events": [
    ],
  • "detections": {
    }
}

generate events options

get options for the resource

path Parameters
handler_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

handler id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get statistics on events.

Get event statistics by target(s) with applied filters.

Event fields and/or functions (count, min, etc.) can be set as targets for aggregation of events.

Grouping by frequency or grouping by time intervals is available.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Value: "application/json"

content type is application/json.

Request Body schema: application/json
Array of objects (targets) >= 0 items
Default: [{"column":"event_id","aggregator":"count"}]

You can specify one or several event fields and functions for them for data aggregation.

The table includes event fields and available functions for them:

Field Function
count max min avg group_by
event_id + - - - +
external_id + - - - +
handler_id + - - - +
attribute_id + - - - +
source + - - - +
top_similar_face_id + - - - +
top_similar_face_list + - - - +
create_time + + + - -
top_similar_face_similarity + + + + -
face_id + - - - +
gender + + + + +
age + + + + +
emotion + + + + +
ethnic_group + + + + +
user_data + - - - +
tags + + + - -

Note! There must be at least one function different from group_by in the targets, otherwise an error occurs.

Array of objects (filters) >= 0 items

specifies filters for events.

Operators available for each filter:

Filter Operator
like, nlike in, nin eq, neq gt, gte, lt, lte
tags + - - -
source - + + -
user_data - + + -
event_id - + + +
external_id - + + +
handler_id - + + +
attribute_id - + + +
top_similar_face_id - + + +
top_similar_face_list - + + +
top_similar_face_similarity - - - +
face_id - + + +
gender - + + +
age - + + +
emotion - + + +
ethnic_group - + + +
Array of objects (periods) >= 0 items

specifies the period of event creation. All the events created during this period will be included in the statistics.

You can set the start and end of the period or only one of the bounds.

Note! You can specify only one period!

group_by
string (group_by)

enables you to group events by creation time according to one of two ways:

1) Grouping by time intervals - number and dimension

The parameter value Description
1m one minute
2h two hours
7d seven days
5w five weeks
3M three months
10y ten years

2) The frequency grouping - one of the following

The parameter value Description
monthOfYear by month of year
weekOfYear by week of year
dayOfYear by day of year
dayOfMonth by day of month
dayOfWeek by day of week
hourOfDay by hours of day
minuteOfHour by minutes of hour

Responses

Request samples

Content type
application/json
{
  • "targets": [
    ],
  • "filters": [
    ],
  • "period": [
    ],
  • "group_by": "dayOfWeek"
}

Response samples

Content type
application/json
{
  • "fields": [
    ],
  • "stats": [
    ]
}

events statistics options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get events

Get events that satisfy filters. The target parameter determines field that will be shown for each event. If target is not set, the response will contain all the fields.

query Parameters
target
string
Enum: "create_time" "event_id" "handler_id" "external_id" "attribute_id" "source" "top_similar_face_id" "top_similar_face_list" "top_similar_face_similarity" "match_result" "extract_result" "face_id" "attach_result" "gender" "age" "emotion" "ethnic_group" "tags" "user_data"
Example: target=create_time,event_id,extract_result

Comma-separated list of event fields. If set, each event from result will contain only specified fields, otherwise, events with all fields will be returned.

create_time__gte
string <date-time> (time)
Example: create_time__gte=2018-08-11T09:11:41.674Z

lower included bound for object create_time.

create_time__lt
string <date-time> (time)
Example: create_time__lt=2018-08-11T09:11:41.674Z

upper bound for object create_time.

sources
string
Example: sources=cam1,cam2

Comma-separated list of sources. Each event from result will contain one of the given sources.

top_similar_face_list
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: top_similar_face_list=557d54ec-29ad-4f3c-93b4-c9092ef12515

ID of top similar face list.

top_similar_face_ids
Array of strings <uuid4> (uuid4)
Example: top_similar_face_ids=557d54ec-29ad-4f3c-93b4-c9092ef12515

Comma-separated list of top similar face ids. Each event from result will contain one of the given top similar face ids.

top_similar_face_similarity__gte
number
Example: top_similar_face_similarity__gte=0.5

Top similar face similarity lower included bound.

top_similar_face_similarity__lt
number
Example: top_similar_face_similarity__lt=0.5

Top similar face similarity upper excluded bound.

age__lt
integer
Example: age__lt=50

age upper excluded bound.

age__gte
integer
Example: age__gte=50

age lower included bound.

gender
integer
Enum: 0 1
Example: gender=1

Gender. 1 - male, 0 - female.

emotions
string <list of integer (1, 2, 3, 4, 5, 6, 7)>
Example: emotions=1,2,3

comma-separated list of predominant emotions. Each event from result will contain one of the given emotions.

emotions value
anger 1
disgust 2
fear 3
happiness 4
neutral 5
sadness 6
surprise 7
ethnic_groups
string <list of integer (1, 2, 3, 4)>
Example: ethnic_groups=1,2

comma-separated list of dominant ethnic group. Each event from result will contain one of the given ethnic groups.

ethnicity value
AfricanAmerican 1
Indian 2
Asian 3
Caucasian 4
face_ids
string <list of uuid4>
Example: face_ids=8950722f-3fd4-4223-b48f-03f95f0e8dfb,346a5645-ec89-4806-820a-dbcb6e0dc38

list of comma-separated face ids.

event_ids
string <list of uuid4.>
Example: event_ids=8950722f-3fd4-4223-b48f-03f95f0e8dfb,346a5645-ec89-4806-820a-dbcb6e0dc38

a list of comma-separated event ids.

handler_ids
string <list of uuid4.>
Example: handler_ids=8950722f-3fd4-4223-b48f-03f95f0e8dfb,346a5645-ec89-4806-820a-dbcb6e0dc38

a list of comma-separated handler ids.

external_ids
string <list of string.>
Example: external_ids=external_id_1,external_id_2

a list of comma-separated external ids.

user_data
string
Example: user_data=user_data_text

find all objects with user_data that is similar to this parameter. You can specify only part of the user_data value for this filter.

tags
Array of strings (tag) >= 0 items
Example: tags=tag_1,tag_2

A comma-separated list of tags. Each event from result will contain all of the given tags. Each tag can be at most 36 characters.

order
string
Enum: "asc" "desc"

the sort order. If "desc" is set, the newest events will be shown first. If "asc" is set, the oldest events will be shown first.

page
integer >= 1
Default: 1

a page number.

page_size
integer [ 1 .. 1000 ]
Default: 10

the number of items on page.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "total": 1,
  • "events": [
    ]
}

events options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get event

Get event by ID.

path Parameters
event_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

event id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "create_time": "2018-08-11T09:11:41.674Z",
  • "event_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "handler_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "attribute_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "external_id": "3.1415926",
  • "source": "Main_hall_camera",
  • "top_similar_face_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "top_similar_face_list": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "top_similar_face_similarity": 0.7,
  • "match_result": [
    ],
  • "extract_result": [
    ],
  • "face_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "attach_result": [
    ],
  • "gender": 0,
  • "age": 0,
  • "emotion": 1,
  • "ethnic_group": 1,
  • "tags": [
    ],
  • "user_data": "save event"
}

check event existence

Check existence of the event with id=event_id.

path Parameters
event_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

event id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

event options

get options for the resource

path Parameters
event_id
required
string <uuid4> (uuid4) ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Example: 557d54ec-29ad-4f3c-93b4-c9092ef12515

event id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

task processing

clustering task

Create a new clustering task.

The Filters section enables to specify filters for faces or events clustering. Objects corresponding to all of the filters will be added to the cluster.

Available filters depend on the object type: events or faces.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Content-Type
string
Value: "application/json"

content type is application/json.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
description
string

provided user data for current task

required
object

clustering task content

Responses

Request samples

Content type
application/json
{
  • "description": "clustering faces",
  • "content": {
    }
}

Response samples

Content type
application/json
{
  • "task_id": 123
}

clustering options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

linker task

Create a new linker task.

The task enables you to attach faces to the specified list according to the filters.

You can use faces or events as objects for the task. When events are used, a new face is created for each of the events.

A list is required for the task processing:

  • If you specified a list, the Tasks service checks its existence. If there is no such a list, it will be created.
  • If you set new list creation using create_list = 1, a new list is created.
header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Content-Type
string
Value: "application/json"

content type is application/json.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
description
string

provided user data for current task

required
object (LinkerTaskContent)

linker task content

Responses

Request samples

Content type
application/json
{
  • "description": "linker task one",
  • "content": {
    }
}

Response samples

Content type
application/json
{
  • "task_id": 123
}

linker options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

garbage collection task

Task is not available because all attributes is temporary and will be removed automatically.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Responses

Response samples

Content type
application/json
{}

gc options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

reporter task

Create a report in csv format for a task.

Now the report is only created for clustering tasks.

The report contains additional information about clustering objects (faces or events). You can specify additional information that will be added to the report. The first and the second columns in the report always correspond to a cluster number and an object ID.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Content-Type
string
Value: "application/json"

content type is application/json.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
description
string

provided user data for the current task

required
object (ReporterTaskContent)

reporter task content

Responses

Request samples

Content type
application/json
{
  • "description": "report clustering events from cam1",
  • "content": {
    }
}

Response samples

Content type
application/json
{
  • "task_id": 123
}

reporter options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

cross-matching task

Create a new cross-matching task.

The cross-matching task enables you to compare references (faces or events) with candidates (faces or events) according to the specified filters.

All the references are matched with all the candidates.

You can limit the number of candidates returned in matching results and set the minimum acceptable similarity threshold.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Content-Type
string
Value: "application/json"

content type is application/json.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
description
string

provided user data for current task

required
object (CrossMatchTaskContent)

cross match task content

Responses

Request samples

Content type
application/json
{
  • "description": "matching visitors with the list of VIP customers",
  • "content": {
    }
}

Response samples

Content type
application/json
{
  • "task_id": 123
}

cross match options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

ROC-curve calculating task

create a ROC-curve calculating task.

ROC (or Receiver Operating Characteristic) is a performance measurement for the classification problem at various threshold settings. The ROC-curve is plotted with TPR (True Positive Rate) against the FPR (False Positive Rate).

TPR is a true positive match pair count divided by a count of total expected positive match pairs, and FPR is a false positive match pair count divided by a count of total expected negative match pairs. Each point (FPR, TPR) of the ROC-cure corresponds to a certain similarity threshold.

Using ROC the model performance is determined by looking at the area under the ROC-curve (or AUC) and the ROC-curve and the secondary main diagonal intersection point, where type I and type II error rates are equal. The model performance also determined by getting into the top-N probability, i.e. probability of getting a positive match pair into the top-N for any match result group sorted by similarity.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Content-Type
string
Value: "application/json"

content type is application/json.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Request Body schema: application/json
description
string

provided user data for current task.

required
object (ROCTaskContent)

roc task content.

Responses

Request samples

Content type
application/json
{
  • "description": "matching famous people with customers",
  • "content": {
    }
}

Response samples

Content type
application/json
{
  • "task_id": 123
}

roc options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

tasks

get tasks

Get tasks according to the filters.

query Parameters
page
integer >= 1
Default: 1

a page number.

page_size
integer [ 1 .. 1000 ]
Default: 10

the number of items on page.

create_time__lt
string <date-time> (time)
Example: create_time__lt=2018-08-11T09:11:41.674Z

upper bound for object create_time.

create_time__gte
string <date-time> (time)
Example: create_time__gte=2018-08-11T09:11:41.674Z

lower included bound for object create_time.

end_time__lt
string <date-time> (time)
Example: end_time__lt=2018-08-11T09:11:41.674Z

upper bound for object end_time.

end_time__gte
string <date-time> (time)
Example: end_time__gte=2018-08-11T09:11:41.674Z

lower included bound for object end_time.

task_ids
string <comma-separate task ids> (taskIds)
Example: task_ids=1,2,3

comma-separated task ids

task_type
integer (taskType)
Enum: 0 1 2 3 4 6 7
Example: task_type=1

task type

task type value
unknown 0
linker 1
clustering 2
report 3
garbage collection 4
cross match 6
ROC calculation 7
task_status
integer (taskStatus)
Enum: 0 1 2 3 4 5
Example: task_status=1

task status

task status value
pending 0
in progress 1
cancelled 2
failed 3
collect results 4
done 5
header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "tasks": [
    ]
}

tasks options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get tasks count

Count tasks according to the filters.

query Parameters
create_time__lt
string <date-time> (time)
Example: create_time__lt=2018-08-11T09:11:41.674Z

upper bound for object create_time.

create_time__gte
string <date-time> (time)
Example: create_time__gte=2018-08-11T09:11:41.674Z

lower included bound for object create_time.

end_time__lt
string <date-time> (time)
Example: end_time__lt=2018-08-11T09:11:41.674Z

upper bound for object end_time.

end_time__gte
string <date-time> (time)
Example: end_time__gte=2018-08-11T09:11:41.674Z

lower included bound for object end_time.

task_ids
string <comma-separate task ids> (taskIds)
Example: task_ids=1,2,3

comma-separated task ids

task_type
integer (taskType)
Enum: 0 1 2 3 4 6 7
Example: task_type=1

task type

task type value
unknown 0
linker 1
clustering 2
report 3
garbage collection 4
cross match 6
ROC calculation 7
task_status
integer (taskStatus)
Enum: 0 1 2 3 4 5
Example: task_status=1

task status

task status value
pending 0
in progress 1
cancelled 2
failed 3
collect results 4
done 5
header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "count": 152
}

tasks count options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get task

Get task by ID.

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "task_id": 123,
  • "create_time": "2018-08-11T09:11:41.674Z",
  • "end_time": "2018-08-11T09:11:41.674Z",
  • "last_update_time": "2018-08-11T09:11:41.674Z",
  • "task_type": 3,
  • "task_status": 1,
  • "result_id": "b668c4a5-2191-476e-a261-3b4f9ce2e25e",
  • "count_task_parts_done": 10,
  • "count_task_parts_all": 100,
  • "content": {
    },
  • "description": "task description"
}

cancel task

Cancel task by ID.

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{}

delete task

Delete a task and the task results by the task ID.

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
Example
{}

task options

get options for the resource

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get task result

Get task result by the task ID.

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
Example
{
  • "result": [
    ],
  • "errors": []
}

task result options

get options for the resource

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get subtasks

Get subtasks of a task by ID.

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
[
  • {
    }
]

subtasks options

get options for the resource

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

task errors

get task errors

Get errors of a task by the task ID.

path Parameters
task_id
required
integer >= 1

task id

query Parameters
page
integer >= 1
Default: 1

a page number.

page_size
integer [ 1 .. 1000 ]
Default: 10

the number of items on page.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{}

task errors options

get options for the resource

path Parameters
task_id
required
integer >= 1

task id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get errors

Get errors according to the filters.

query Parameters
page
integer >= 1
Default: 1

a page number.

page_size
integer [ 1 .. 1000 ]
Default: 10

the number of items on page.

task_ids
string <comma-separate task ids> (taskIds)
Example: task_ids=1,2,3

comma-separated task ids

error_code
integer (error_code)
Example: error_code=22004

error code

error_ids
string <comma-separate task ids> (errorIds) non-empty
Example: error_ids=4,5,6

comma-separated error ids

error_time__lt
string <date-time> (time)
Example: error_time__lt=2018-08-11T09:11:41.674Z

upper bound for object error_time.

error_time__gte
string <date-time> (time)
Example: error_time__gte=2018-08-11T09:11:41.674Z

lower included bound for object error_time.

task_type
integer (taskType)
Enum: 0 1 2 3 4 6 7
Example: task_type=1

task type

task type value
unknown 0
linker 1
clustering 2
report 3
garbage collection 4
cross match 6
ROC calculation 7
status_code
integer (status_code) [ 400 .. 599 ]
Example: status_code=500

http status code

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{}

errors options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get errors count

Count errors according to the filters.

query Parameters
error_time__lt
string <date-time> (time)
Example: error_time__lt=2018-08-11T09:11:41.674Z

upper bound for object error_time.

error_time__gte
string <date-time> (time)
Example: error_time__gte=2018-08-11T09:11:41.674Z

lower included bound for object error_time.

task_type
integer (taskType)
Enum: 0 1 2 3 4 6 7
Example: task_type=1

task type

task type value
unknown 0
linker 1
clustering 2
report 3
garbage collection 4
cross match 6
ROC calculation 7
status_code
integer (status_code) [ 400 .. 599 ]
Example: status_code=500

http status code

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{
  • "count": 101
}

task errors count options

get options for the resource

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get error

Get error by ID.

path Parameters
error_id
required
integer >= 1

error id

query Parameters
error_id
integer (errorId)
Example: error_id=10

error id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Responses

Response samples

Content type
application/json
{}

error options

get options for the resource

path Parameters
error_id
required
integer >= 1

error id

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

liveness

predict liveness

Predict liveness probability in input images.

The response contains the probability that there is a real person in the image, and it is not a presentation attack.

"meta" and "x_meta" sections of the request are used for backward compatibility and are deprecated now.

The incoming images should correspond the requirements of the utilized Liveness. See "Administrator’s manual" for details.

Liveness estimation is not supported for samples (warped images).

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Luna-Account-Id
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Content-Type
string
Enum: "image/jpeg" "image/png" "image/bmp" "image/x-portable-pixmap" "image/tiff" "multipart/form-data" "application/json" "image/x-jpeg-base64" "image/x-png-base64" "image/x-bmp-base64" "image/x-tiff-base64" "image/x-portable-pixmap-base64"
Request Body schema:
object (LivenessMeta)
Deprecated

Device information. This information can significantly decrease the overall error rate.

The "meta" object is not mandatory. If you are not sure about any of the parameters, set "UNKNOWN" value or don't pass meta.

The specified meta is applied to all the images within the request.

x_meta
object
Deprecated

The JSON string with any additional information

required
Array of image_binary_for_multipart (string) or image_base64_for_multipart (string) (image_list_for_multipart) non-empty

Responses

Request samples

Content type
No sample

Response samples

Content type
application/json
{}

ws

ws handshake

ws handshake

Attention!

Subscription to events occurs via WebSocket. Messages sent by ws you can view in callback section. Connection supports autoping.

query Parameters
handler_ids
string <list of uuid4.>
Example: handler_ids=8950722f-3fd4-4223-b48f-03f95f0e8dfb,346a5645-ec89-4806-820a-dbcb6e0dc38

a list of comma-separated handler ids.

sources
string
Example: sources=cam1,cam2

Comma-separated list of sources. Each event from result will contain one of the given sources.

top_similar_face_lists
Array of strings <uuid4> (uuid4)
Example: top_similar_face_lists=557d54ec-29ad-4f3c-93b4-c9092ef12515

IDs of top similar face lists.

top_similar_face_similarity__gte
number
Example: top_similar_face_similarity__gte=0.5

Top similar face similarity lower included bound.

top_similar_face_similarity__lt
number
Example: top_similar_face_similarity__lt=0.5

Top similar face similarity upper excluded bound.

age__lt
integer
Example: age__lt=50

age upper excluded bound.

age__gte
integer
Example: age__gte=50

age lower included bound.

gender
integer
Enum: 0 1
Example: gender=1

Gender. 1 - male, 0 - female.

ethnic_groups
string <list of integer (1, 2, 3, 4)>
Example: ethnic_groups=1,2

comma-separated list of dominant ethnic group. Each event from result will contain one of the given ethnic groups.

ethnicity value
AfricanAmerican 1
Indian 2
Asian 3
Caucasian 4
tags
Array of strings (tag) >= 0 items
Example: tags=tag_1,tag_2

A comma-separated list of tags. Each event from result will contain all of the given tags. Each tag can be at most 36 characters.

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Account-Id
required
string <uuid4> ^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][...
Deprecated
Example: 8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

account ID. Account is a limitation for all user actions (matching, removing, updating and other) on data which does not have corresponding account id. For example: it is impossible to attach a face with one account to a list with another account id. User can make a limited set of requests without this header (requests with methods GET, HEAD, OPTIONS, match requests and getting events statistics requests).

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{
  • "event": {
    },
  • "handler_id": "557d54ec-29ad-4f3c-93b4-c9092ef12515",
  • "event-time": "2019-08-24T14:15:22Z",
  • "Luna-Request-id": "1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a"
}

documents

get openapi documentation

Get service OpenApi documentation. If Accept request header is of type application/x-yaml, returns documentation in yaml format or returns html documentation, if Accept-Type is text/html

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Accept
string (accept_docs_handler)
Enum: "application/x-yaml" "text/html"

acceptable type of recieving data

Responses

Response samples

Content type
application/json
{}

get development manual

Get sphinx documentation - Development Manual. After the request you will be redirected to the page /docs/dev/index.html

header Parameters
Origin
string
Example: http://example.com

The Origin header indicates the origin of the cross-site access request

Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

config

get service configuration

Get service configuration. Passwords and tokens will be hidden in the response.

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Accept
string
Enum: "application/json" "text/plain"

acceptable type of receiving data

Responses

Response samples

Content type
{
  • "INFLUX_MONITORING": {
    }
}

health

get health

get health of service

query Parameters
include_luna_services
integer
Default: 0
Enum: 0 1

whether to perform healthchecks for dependent luna services.

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{
  • "execution_time": 0.123
}

health options

get options for the resource

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{}

get health (redirect)

get health of service (redirect)

query Parameters
include_luna_services
integer
Default: 0
Enum: 0 1

whether to perform healthchecks for dependent luna services.

header Parameters
Luna-Request-Id
string <timestamp,uuid> ^[0-9]{10},[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4...
Example: 1536751345,8b8b5937-2e9c-4e8b-a7a7-5caf86621b5a

external request id. Helps to uniquely identify messages that correspond to particular requests, in system logs. If it was not set, the system will set it to the default format ("timestamp,UUID"). It will be returned with response.

Responses

Response samples

Content type
application/json
{
  • "execution_time": 0.123
}