REST API

API Documentation

Integration guide for CheckoutPay face verification. Record one ~5 second guided clip (or a camera still), then match it to the enrolled face.

Getting Started

1. Request access

Create an account at /register. Emails on @check-outnow.com and @check-outpay.com are verified instantly and receive an API key immediately.

Machine bootstrap (first-party emails only):

curl -X POST https://face.check-outnow.com/v1/partner/register \
  -H "Content-Type: application/json" \
  -d '{"name":"CheckoutNow Wallet","company":"CheckoutNow","email":"wallet@check-outnow.com","password":"********"}'

Or ask for a bearer token for your service. The token authorizes enroll and verification calls.

Get Started

2. Base URL

https://face.check-outnow.com

3. Request format

  • Use HTTPS
  • Send Authorization: Bearer on enroll and verification routes
  • Send photos and the clip as multipart form data
  • Prefer one continuous 5 second camera video. JPEG/GIF stills are accepted; they match identity instead of blink/turn scores

Authentication

Protected routes expect the service token in the Authorization header.

Authorization: Bearer your_token_here

Security: Keep the token on your server. The mobile app should call your backend, and your backend should call Checkface.

API Endpoints

POST/enroll-face

Store the official face. We keep a small crop and a numeric signature. Optional extra poses teach more angles.

curl -X POST https://face.check-outnow.com/enroll-face \
  -H "Authorization: Bearer $TOKEN" \
  -F "user_id=cus_2041" \
  -F "photo=@face.jpg"
POST/liveness/session

Open a guided video session. The response lists the prompt order. Three prompts share one 5 second clip (~1.67s each). Follow clip_seconds and each prompt’s duration — do not record a still named .mp4.

{
  "session_id": "...",
  "challenges": ["center", "blink", "turn_left"],
  "clip_seconds": 5,
  "seconds_per_challenge": 1.67,
  "capture": "video",
  "expires_in": 180
}

Typical plan: hold still (center), then two of blink / smile / look left or right. Mouth is not always included.

POST/liveness/video

Upload the one clip recorded in that prompt order. A real video is scored for each movement; FaceNet checks the enrolled face. A snapshot still is matched on identity (liveness_mode: identity_still).

FieldRequiredDescription
session_idYesFrom the session response
clipYesPreferred: MP4 / WebM / MOV / 3GP, about 5 seconds, under 8 MB (hard cap 12 seconds). Also accepted: JPEG, PNG, WebP, GIF, HEIC from the camera.
{
  "authenticated": true,
  "liveness_score": 82.5,
  "liveness_mode": "active",
  "challenge_scores": {"blink": 1, "turn_left": 0.8},
  "identity_matched": true,
  "gallery_size": 2
}

liveness_mode is active for a motion clip and identity_still when the file is a single frame (including a JPEG labelled .mp4).

POST/verify-face

Compare one photo with the enrolled signatures. The first enroll stays as an anchor; each successful match also becomes the latest face used on the next check (so aging still works). If the latest score misses, the original enroll is tried. Use the video route when the service needs a live person on camera.

curl -X POST https://face.check-outnow.com/verify-face \
  -H "Authorization: Bearer $TOKEN" \
  -F "user_id=cus_2041" \
  -F "selfie=@selfie.jpg"
GET/learning-status?user_id=cus_2041

Returns how many signatures are stored for that person.

Error Handling

StatusMeaning
401Missing or wrong bearer token
404That person is not enrolled, or the session expired
422Unreadable clip, clip longer than 12 seconds, face not visible, or (on a real video) blink/turn not clear enough