Skip to content

Biometrics & documents

Browser capture for liveness, documents and selfies

@speedmap/capture runs active liveness, document and selfie capture in the browser, guides in five languages and uploads straight to your capture session.

What it does

Capture SDK, in detail.

Three flows, one component

Run liveness, document and selfie steps in any order, with progress reported through DOM events and callbacks.

On-device guidance

A browser face landmarker checks framing, pose and challenge completion before any frame is sent.

Five languages, your brand

en, pcm, ha, yo or ig, with your name, logo, accent colour, theme and inline or modal layout.

Web, React, script tag

ESM import, a React component and hook, a UMD build, or the <speedmap-capture> web component.

Server-issued trust

The SDK holds only a short-lived token; challenges and the nonce come from the server, so a modified client cannot pass.

How it works

From request to decision.

  1. 1

    Create a session server-side

    POST /v1/capture-sessions with steps, purpose, locale and brand returns a token and hosted url, shown once.

  2. 2

    Mount the SDK with the token

    Call SpeedmapCapture.open({ flow, sessionToken, apiBaseUrl }) or render <SpeedmapCapture /> in React.

  3. 3

    Read results server-side

    GET /v1/capture-sessions/{id} returns each step’s verification, or subscribe to capture_session.completed.

Routing and providers

The SDK is MIT-licensed and ships no secrets: frames go to Speedmap’s public capture endpoint with the session token, and your API key stays on your server.

Use it

One request. One normalized response.

Call POST /v1/capture-sessions through @speedmap/node, speedmap for Python.

Request
curl -X POST http://localhost:4000/v1/capture-sessions \
  -H "Authorization: Bearer sk_test_..." \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "steps": [
    "liveness",
    "document"
  ],
  "reason": "employmentRecruitment",
  "document_types": [
    "drivers_license"
  ],
  "locale": "yo",
  "brand": {
    "name": "Example Rides",
    "color": "#0B6E4F"
  },
  "expires_in_minutes": 60
}'
Response · 201 Created
{
  "id": "cap_f51416771fcc7f36",
  "object": "capture_session",
  "mode": "sandbox",
  "status": "created",
  "steps": [
    "liveness",
    "document"
  ],
  "document_types": [
    "drivers_license"
  ],
  "reason": "employmentRecruitment",
  "locale": "yo",
  "completed_steps": [],
  "results": {},
  "expires_at": "2026-10-20T13:53:49.358Z",
  "token": "6Ln3j2RoBgU8E5guhmJ_NpnjHHfGNPlVj2AqrZqVDaQ",
  "url": "https://speedmap.ng/capture/6Ln3j2RoBgU8E5guhmJ_NpnjHHfGNPlVj2AqrZqVDaQ"
}

Use cases

Where Nigerian teams use it.

Lending app onboarding

Liveness and NIN slip capture inside your web app, in the applicant’s language.

Driver onboarding

Licence capture and active liveness on the driver’s phone, under your brand.

Agent networks

Super-agents onboard sub-agents from a tablet using the inline layout.

Background checks

Send the hosted url when you would rather not embed anything.

Part of:Mobility & logistics

What you get back

The fields you will read.

  • onComplete / speedmap:complete

    Meaning
    CaptureResult: the liveness, document and selfie captures, plus uploads per step with status and reference_id
  • onError / speedmap:error

    Meaning
    permission_denied, no_camera, camera_failed, model_load_failed, retry_limit, timeout, cancelled, upload_failed, unsupported_browser, internal
  • GET /v1/capture-sessions/{id}

    Meaning
    Server-side truth: results and the verification for each step, keyed by step

Assertion tier

The browser receives assertions only, never the extracted record.

Full tier

Read the full verification by reference_id from your server, subject to your tier.

Pricing

The SDK is free and open source; you pay for the verifications a session produces.

FAQ

Capture SDK questions.

Need more detail? Read the documentation or talk to our team.

Does the SDK work on feature phones or old browsers?
It needs a modern browser with camera access. Others raise unsupported_browser so you can fall back to another channel.
Is there a native mobile SDK?
Not yet. The web SDK works inside web views, and the hosted capture page works in any mobile browser.
Where is the face model loaded from?
MediaPipe loads from jsDelivr and the model from Google’s storage by default; set assetsBaseUrl and faceModelUrl to self-host both.

Start verifying in minutes. Go live when you’re ready.

Create your account in under a minute and explore the full dashboard. We switch your workspace live after a short compliance review.