API reference guide
Last updated
This document includes the description of the API of the service provided in the product FacePhi INE Service.
JWT authentication is optional and is configured only at startup. When enabled, GET /api/v1/health and GET /api/v1/version remain public, while POST /api/v1/facial/authentication requires a valid JWT.
The service offers the following endpoints:
/api/v1/facial/authentication: This endpoint is used to authenticate two facial photos. It supports image-image, template-template, and mixed image-template combinations. It returns a score value indicating whether the face belongs to the same person, and a probability indicating the similarity between the two faces. The image or template must be encoded in base64.
/api/v1/health: This endpoint returns the service health status and remains public even when JWT authentication is enabled.
/api/v1/version: This endpoint returns the service version and the SDK information.
The service does not expose endpoints GET/POST /config at runtime.
INE = 0
JPEG = 1
TEMPLATE_RAW = 2
BEST_IMAGE_TOKEN = 3Payloads with malformed JSON or Base64 are returned as HTTP 400 BadRequest with a field message that describes the problem.
Last updated
OK = 0
MALFORMED_JSON = 400
PHOTOA_EMPTY = 401
PHOTOB_EMPTY = 402
NO_PHOTOS = 403
POSE_INVALID = 404
PHOTOA_INVALID = 405
PHOTOB_INVALID = 406