post https://staging.cypherface.com/check-liveness/
This endpoint verifies whether the user is truly present and whether their live face matches the registered user. It performs both liveness detection and face matching using the session ID generated earlier.
curl --location 'https://staging.cypherface.com/check-liveness/' \
--header 'authorization: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJtZXJjaGFudElkIjoiNjdiNDg4ZDhiNGI5NWIzOTNmYmRmZjc0IiwieEFwaUtleSI6IjY3ZjUxMGZmLTk1ZGYtNGM1Mi1iNjhjLTgwNzExNTVhOWU3MSIsImlhdCI6MTc0NTIzNTIzMCwiZXhwIjoxNzQ1NDA4MDMwfQ.APzhVIXZFVoRUs7vRwUWwJZzAHgHc-BG0780XK6ZU7A' \
--header 'Content-Type: application/json' \
--header 'Cookie: connect.sid=s%3AnHqQPNZ3Jmy6zDqQN5Ofk-jzXBpDadcs.XMpdkbBU9kTDOZVmgx3StED99X3kHSRX8TEIy2C28Ws' \
--data '{
"sessionId":"b1d1091a-1ff0-4073-9953-dc53cc07597e"
}'
Authentication
- Authorization header: Bearer JWT token is required.
- Content-Type: application/json
- Optional Cookie:
connect.sid
if session-based tracking is used.
Request Body
{
"sessionId": "b1d1091a-1ff0-4073-9953-dc53cc07597e"
}
"sessionId": "b1d1091a-1ff0-4073-9953-dc53cc07597e"
}
Field | Type | Required | Description |
---|---|---|---|
sessionId | string | β Yes | Unique session ID from /start-liveness-session/ |
π API: /check-liveness/
- Response Examples
β Example: Success - Face Match
{ "livenessSuccess": true, "faceMatch": true, "message": "Face matched successfully. Similarity is 97.45%.", "response": { "$metadata": { "httpStatusCode": 200, "requestId": "example-success-request-id", "attempts": 1, "totalRetryDelay": 0 }, "Confidence": 97.4523, "SessionId": "your-session-id", "Status": "MATCHED" } }
β Example: Face Mismatch
{ "success": true, "faceMatch": false, "message": "Face mismatch. Similarity is 0.00%. Please try again.", "response": { "$metadata": { "httpStatusCode": 200, "requestId": "a483a5ec-eb1d-4c95-bf1c-608d39fc209a", "attempts": 1, "totalRetryDelay": 0 }, "AuditImages": [], "Confidence": 84.83293914794922, "ReferenceImage": { "BoundingBox": { "Height": 280.5039994106625, "Left": 202.4097442626953, "Top": 125.2803395507812 } } } }
β Example: Session Expired
{ "livenessSuccess": false, "faceMatch": false, "message": "Your session has expired. Please try again.", "response": { "$metadata": { "httpStatusCode": 200, "requestId": "399c01e4-4b06-4ece-ae28-fd27c93f41a5", "attempts": 1, "totalRetryDelay": 0 }, "SessionId": "b1d1091a-1ff0-4073-9953-dc53cc07597e", "Status": "EXPIRED" } }
Notes
- Use this endpoint only after a successful frontend liveness flow.
- Ensure the sessionId is valid and corresponds to an active session.
- This step confirms both the userβs presence and identity through face match.