Liveness

Liveness is passive presentation attack detection (PAD). You send a single face image and Sovera decides whether it is a real, present person rather than a photo, screen replay, or mask. It requires the verify:liveness scope.

How liveness works

Passive liveness needs no user action beyond looking at the camera. Sovera analyzes one frame and returns isLive plus a score. For a stronger anti-spoofing signal that also proves the user can respond to instructions, use active liveness, which adds an oval plus a turn-left or turn-right challenge.

Check liveness

Send a base64-encoded image. Pass a sessionId if this call belongs to a verification session.

POST
/v1/verify/liveness
IMAGE_B64=$(base64 -i selfie.jpg | tr -d '\n')

curl -X POST https://verify.lioncapventures.com/v1/verify/liveness \
  -H "Authorization: Bearer svk_live_xxxxxxxx" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d "{\"image\":\"$IMAGE_B64\"}"
  • Name
    image
    Type
    string (required)
    Description

    Base64-encoded face image (JPEG or PNG).

  • Name
    sessionId
    Type
    string
    Description

    Optional session this check belongs to, so the result is recorded on the session report.

Response

Response

{
  "isLive": true,
  "score": 0.982,
  "threshold": 0.5,
  "latencyMs": 214,
  "detail": "passive_pad"
}
  • Name
    isLive
    Type
    boolean
    Description

    Sovera's accept or reject decision for this frame using the provisional threshold.

  • Name
    score
    Type
    number
    Description

    Confidence from 0 to 1 that the face is real and present.

  • Name
    threshold
    Type
    number
    Description

    The cut-off score was compared against. Provisional pending in-house ROC calibration.

  • Name
    latencyMs
    Type
    integer
    Description

    Server-side detection time in milliseconds.

  • Name
    detail
    Type
    string
    Description

    A short label describing the detection path, useful for logging.

Was this page helpful?