Appearance
Face Match API
Compare a source face with a target face. The API returns a boolean match decision and a numeric similarity score.
Access to this API is provided separately. Confirm that Face Match is enabled for your credentials before integrating it.
API endpoint
Use the regional base URL provided for your account:
https://api-us.idphotoapp.com— US regionhttps://api-eu.idphotoapp.com— EU region
http
POST /v2/faceMatchKeep credentials and both image payloads on your server. Do not send an API secret from browser code or log complete Base64 images.
Request
| Field | Type | Required | Description |
|---|---|---|---|
apiKey | string | Yes | API key with Face Match access. |
apiSecret | string | Yes | API secret paired with the key. |
sourceImageBase64 | string | Yes | Base64-encoded reference image. |
targetImageBase64 | string | Yes | Base64-encoded image to compare with the reference. |
similarityThreshold | number | No | Optional match threshold. Omit it to use the service configuration for your integration. |
json
{
"apiKey": "your-api-key",
"apiSecret": "your-api-secret",
"sourceImageBase64": "data:image/jpeg;base64,...",
"targetImageBase64": "data:image/jpeg;base64,..."
}Response
json
{
"isMatch": true,
"similarity": 0.82
}| Field | Type | Description |
|---|---|---|
isMatch | boolean | Whether the similarity met the threshold used for the request. |
similarity | number | Similarity score produced by the comparison. Interpret it together with the configured threshold. |
Integration guidance
- Use one clearly visible face in each image.
- Avoid extreme pose, heavy blur, strong occlusion, or very small faces.
- Do not compare scores produced by different services or assume they share the same scale.
- If your workflow uses a custom threshold, validate it against representative images and the consequences of false matches and false rejections.
- A match result is a technical comparison signal, not by itself a legal identity decision.
- Handle authentication failures, invalid image data, missing faces, and timeouts separately from a valid non-match result.
