POST/api/v1/liveness/check

Real-Time Liveness Detection API

Protect your platform from spoofing attacks. Our multi-model liveness engine detects paper photos, screen replays, 3D masks, and deepfakes with sub-second response times.

POST /api/v1/liveness/check

REQUEST

curl -X POST https://api.faceguard.io/api/v1/liveness/check \
  -H "X-API-Key: fg_live_your_key_here" \
  -F "file=@face.jpg"
200 OK
{
  "is_live": true,
  "confidence": 0.97,
  "spoof_type": null,
  "models": {
    "onnx": { "is_live": true, "score": 0.96 },
    "deepface": { "is_live": true, "score": 0.98 }
  },
  "processing_time_ms": 420
}

Key Features

Everything you need from a production-ready Liveness Detection API.

Multi-Model Fusion

Combines ONNX MiniFASNet and DeepFace models with majority voting for maximum accuracy.

Sub-Second Response

Optimised for real-time use cases — average response under 800ms on standard images.

Spoof Type Detection

Identifies whether a spoof is a photo, screen replay, or 3D mask.

Confidence Scoring

Every result includes a confidence score so you can tune your own acceptance threshold.

How it works

Integrate in minutes with our developer-friendly REST API.

01

Send a face image

POST a face image (JPG, PNG) to the liveness endpoint with your API key.

02

AI analysis

Two independent models analyse the image for texture, depth, and reflection cues.

03

Get a verdict

Receive a live/spoof verdict with a confidence score in under a second.

Data Output

Fields You Can Extract

All data returned as structured JSON — map directly to your database schema.

is_live
confidence
spoof_type
models.onnx
models.deepface
processing_time_ms
response.json
{
  "is_live": true,
  "confidence": 0.97,
  "spoof_type": null,
  "models": {
    "onnx": { "is_live": true, "score": 0.96 },
    "deepface": { "is_live": true, "score": 0.98 }
  },
  "processing_time_ms": 420
}

Ready to integrate Liveness Detection?

Create a free account. Get 50 test API requests instantly — no credit card required.