FaceCard Docs
API reference

API reference

Base URL, credentials, conventions and an index of every FaceCard v1 route.

Base URL

https://api.facecard.dev

All routes are under /v1, except /health, /openapi.json and /.well-known/jwks.json. Requests and responses are JSON. The same contract is served as OpenAPI 3.1 at https://api.facecard.dev/openapi.json.

Credentials

CredentialHeaderUse
Publishable key fc_pk_live_xxxX-FaceCard-Key: fc_pk_live_xxx plus an allowed OriginBrowser routes: challenges, enroll, match
Secret key fc_sk_live_xxxAuthorization: Bearer fc_sk_live_xxxServer routes: users, token verification, usage
User token (ES256 JWT)Authorization: Bearer <jwt>/v1/me routes for that one user

The app is always derived from the credential. A request body app_id is ignored. See Apps and keys.

In the curl examples on these pages, fc_pk_live_xxx and fc_sk_live_xxx are placeholders. Use the keys from your own app. Browser routes need an Origin header that matches your allow list, so the examples send one.

Errors

Every error has the same shape and a matching HTTP status:

{ "error": { "code": "no_match", "message": "No matching face was found." } }

Some errors carry extra fields, for example limit, used and resets_at on plan_limit_reached. The full list is in Errors.

Routes

Method and pathCredentialPage
POST /v1/challengesPublishable keyChallenges
POST /v1/enrollPublishable keyEnroll
POST /v1/matchPublishable keyMatch
GET /v1/me, PATCH /v1/me, DELETE /v1/meUser tokenMe
POST /v1/me/email, POST /v1/me/email/confirmUser tokenMe
POST /v1/me/templatesUser tokenMe
GET /v1/users, GET /v1/users/{id}, DELETE /v1/users/{id}Secret keyUsers
POST /v1/tokens/verifySecret keyTokens
GET /v1/usageSecret keyUsage
GET /health, GET /.well-known/jwks.json, GET /openapi.jsonNoneHealth, JWKS and OpenAPI

The /internal/* routes are used by the developer portal and are not available from the internet. They are not part of the public API.

Rate limits

30 requests a minute per IP on challenge, enroll and match. 600 requests a minute per secret key. Over the limit you get 429 rate_limited with a Retry-After header. See Plans and limits.

On this page