Skip to content

YeboVerify API Reference

Base URL

https://api.yeboverify.com

Authentication

All API endpoints (except health check) require authentication via the X-API-Key header.

X-API-Key: your_api_key_here

Endpoints

Health Check

Check API status and availability.

GET /health

Response:

json
{
  "status": "ok",
  "timestamp": "2024-01-15T12:00:00.000Z",
  "service": "yeboverify-api",
  "version": "1.0.0"
}

Verification Endpoints

Selfie Match Verification

Compare a selfie against a profile picture URL using facial recognition.

POST /v1/verify/selfie-match

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key
Content-TypestringYesmultipart/form-data

Request Body (multipart/form-data):

FieldTypeRequiredDescription
selfiefileYesSelfie image (JPEG, PNG, max 10MB)
profilePictureUrlstringYesURL of the profile picture to compare against
externalRefstringNoYour internal reference ID

Response:

json
{
  "success": true,
  "data": {
    "verificationId": "vrf_sm_abc123xyz",
    "samePerson": true,
    "matchScore": 94.5,
    "confidence": "high",
    "processingMs": 2340
  }
}

Response Fields:

FieldTypeDescription
verificationIdstringUnique verification ID (prefixed with vrf_sm_)
samePersonbooleantrue if faces match (score ≥ 80)
matchScorenumberSimilarity score (0-100)
confidencestringhigh (≥90), medium (75-89), low (<75)
processingMsnumberProcessing time in milliseconds

ID Document Verification

Full identity verification with face matching, liveness detection, and document OCR.

POST /v1/verify/id-document

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key
Content-TypestringYesmultipart/form-data

Request Body (multipart/form-data):

FieldTypeRequiredDescription
selfiefileYesLive selfie image (JPEG, PNG, max 10MB)
idFrontfileYesFront of ID document (JPEG, PNG, max 10MB)
idBackfileNoBack of ID document (JPEG, PNG, max 10MB)
externalRefstringNoYour internal reference ID
documentTypestringNoDocument type hint (e.g., passport, national_id)

Response:

json
{
  "success": true,
  "data": {
    "verificationId": "vrf_id_xyz789abc",
    "status": "approved",
    "decision": "approved",
    "confidence": "high",
    "faceMatch": {
      "score": 92.3,
      "samePerson": true
    },
    "documentData": {
      "surname": "SMITH",
      "names": "JOHN MICHAEL",
      "dateOfBirth": "1990-05-15",
      "idNumber": "9005151234567",
      "sex": "M",
      "nationality": "ZA",
      "documentType": "NATIONAL_ID",
      "expiryDate": "2030-05-15"
    },
    "ocrConfidence": 85,
    "processingMs": 5420
  }
}

Response Fields:

FieldTypeDescription
verificationIdstringUnique verification ID (prefixed with vrf_id_)
statusstringapproved, rejected, or needs_review
decisionstringSame as status
confidencestringhigh, medium, or low
faceMatch.scorenumberFace similarity score (0-100)
faceMatch.samePersonbooleantrue if faces match (score ≥ 70)
documentDataobjectExtracted document information
ocrConfidencenumberOCR confidence (0-100)
processingMsnumberProcessing time in milliseconds

Document Data Fields:

FieldTypeDescription
surnamestringLast name from document
namesstringFirst and middle names
dateOfBirthstringDate of birth (YYYY-MM-DD)
idNumberstringID/Document number
sexstringM or F
nationalitystringNationality code
documentTypestringType of document
expiryDatestringDocument expiry date (YYYY-MM-DD)

Session Endpoints

For redirect-based verification flows.

Create Session

Create a verification session for redirect-based flows.

POST /v1/sessions/create

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key
Content-TypestringYesapplication/json

Request Body:

json
{
  "userId": "user_123",
  "callback": "https://yourapp.com/verification-complete"
}
FieldTypeRequiredDescription
userIdstringYesYour user identifier
callbackstringNoCallback URL after verification
themeobjectNoPer-session branding override — see White-Label Branding

Any other top-level field, or any theme sub-field outside logoUrl/companyName/primaryColor/darkMode, is rejected with 400.

Response:

json
{
  "success": true,
  "session": "eyJhbGciOiJIUzI1NiIs...",
  "verifyUrl": "https://verify.yeboverify.com?session=eyJhbGciOiJIUzI1NiIs...",
  "expiresIn": 1800
}

Validate Session

Validate a session token.

POST /v1/sessions/validate

Request Body:

json
{
  "session": "eyJhbGciOiJIUzI1NiIs..."
}

Response:

json
{
  "success": true,
  "userId": "user_123",
  "businessId": "clxxxxx",
  "callback": "https://yourapp.com/verification-complete",
  "expiresAt": 1705323600000,
  "branding": { "logoUrl": null, "companyName": null, "primaryColor": null, "darkMode": true }
}

Upload Photo (progressive)

Upload a single photo against a session token. Useful on slow networks — your client uploads each captured photo as soon as it's ready, then calls Submit Session with just the keys instead of bytes.

POST /v1/sessions/upload

Request Body:

json
{
  "session": "eyJhbGciOiJIUzI1NiIs...",
  "photo": "data:image/jpeg;base64,/9j/4AAQ...",
  "type": "selfie"
}
FieldTypeRequiredDescription
sessionstringYesSession token from Create Session
photostringYesBase64-encoded image (with or without data: URL prefix)
typestringYesOne of selfie, idFront, idBack, liveness1, liveness2

Response:

json
{
  "success": true,
  "key": "sessions/user_123/selfie-abcd1234efgh",
  "type": "selfie",
  "size": 184320
}

The returned key can be passed to Submit Session instead of re-uploading the bytes.


Submit Session

Submit a verification with photos that were either uploaded progressively (using *Key fields) or sent inline as base64 (using non-Key fields). Triggers AI processing — the result lands in your webhook as verification.completed after ~5–10 seconds. A verification.submitted webhook fires immediately on success.

POST /v1/sessions/submit

Request Body (using progressive upload keys):

json
{
  "session": "eyJhbGciOiJIUzI1NiIs...",
  "selfieKey": "sessions/user_123/selfie-abcd",
  "idFrontKey": "sessions/user_123/idFront-efgh",
  "idBackKey": "sessions/user_123/idBack-ijkl"
}

Request Body (using inline base64):

json
{
  "session": "eyJhbGciOiJIUzI1NiIs...",
  "selfie": "data:image/jpeg;base64,...",
  "idFront": "data:image/jpeg;base64,...",
  "idBack": "data:image/jpeg;base64,..."
}
FieldTypeRequiredDescription
sessionstringYesSession token from Create Session
selfie / selfieKeystringYes (one of)Selfie photo
idFront / idFrontKeystringYes (one of)Front of ID document
idBack / idBackKeystringNoBack of ID document (some types only)

Response:

json
{
  "success": true,
  "verificationId": "vrf_id_abc123xyz",
  "status": "PENDING",
  "message": "Verification submitted. Results will be sent via webhook."
}

Listen for the verification.completed webhook to receive the final decision. See Webhooks for details.


Verification History

List Verifications

Get a paginated list of verifications for your business.

GET /v1/verifications

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key

Query Parameters:

ParameterTypeDefaultDescription
pagenumber1Page number
limitnumber20Results per page (max 100)
statusstring-Filter by status: PENDING, PROCESSING, COMPLETED, FAILED, NEEDS_REVIEW

Response:

json
{
  "success": true,
  "data": {
    "verifications": [
      {
        "verificationId": "vrf_sm_abc123",
        "externalRef": "order_456",
        "status": "COMPLETED",
        "decision": "APPROVED",
        "confidence": "high",
        "createdAt": "2024-01-15T12:00:00.000Z",
        "completedAt": "2024-01-15T12:00:03.000Z"
      }
    ],
    "pagination": {
      "page": 1,
      "limit": 20,
      "total": 156,
      "totalPages": 8
    }
  }
}

Get Verification Details

Get detailed information about a specific verification.

GET /v1/verifications/:verificationId

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key

Response:

json
{
  "success": true,
  "data": {
    "verificationId": "vrf_id_xyz789abc",
    "externalRef": "user_123",
    "status": "COMPLETED",
    "decision": "APPROVED",
    "decisionReason": "High face match and document verification confidence",
    "confidence": "high",
    "faceScore": 92.3,
    "ocrConfidence": 85,
    "extractedData": {
      "surname": "SMITH",
      "names": "JOHN MICHAEL",
      "dateOfBirth": "1990-05-15",
      "idNumber": "9005151234567",
      "documentType": "NATIONAL_ID"
    },
    "processingMs": 5420,
    "createdAt": "2024-01-15T12:00:00.000Z",
    "completedAt": "2024-01-15T12:00:05.000Z"
  }
}

Delete Verification

Remove a verification record. Triggers a verification.deleted webhook so downstream systems (e.g., your KYC store) can reset state for the user. Useful for letting a user re-verify after a rejected decision, or for honouring a "delete my data" request.

DELETE /v1/verifications/:verificationId

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key

Response:

json
{
  "success": true,
  "message": "Verification deleted"
}

Errors with 404 if the verification doesn't exist or doesn't belong to your business. The associated images are removed from R2 storage immediately as part of the delete.


Account Endpoints

Get Account Info

Get your business account information.

GET /v1/account

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key

Response:

json
{
  "success": true,
  "data": {
    "id": "clxxxxx",
    "name": "Acme Corp",
    "email": "[email protected]",
    "webhookUrl": "https://acme.com/webhooks/yeboverify",
    "plan": "business",
    "active": true,
    "createdAt": "2024-01-01T00:00:00.000Z"
  }
}

Update Webhook URL

Update your webhook configuration.

PUT /v1/account/webhook

Headers:

HeaderTypeRequiredDescription
X-API-KeystringYesYour API key
Content-TypestringYesapplication/json

Request Body:

json
{
  "webhookUrl": "https://yourapp.com/webhooks/yeboverify",
  "webhookSecret": "your_webhook_secret"
}

Response:

json
{
  "success": true,
  "data": {
    "webhookUrl": "https://yourapp.com/webhooks/yeboverify",
    "message": "Webhook configuration updated"
  }
}

Get Branding

Get your hosted-flow branding. See White-Label Branding for the full picture.

GET /v1/settings/branding

Response:

json
{
  "success": true,
  "data": {
    "logoUrl": "https://acme.com/logo.svg",
    "companyName": "Acme Corp",
    "primaryColor": "#FF6B00",
    "darkMode": true
  }
}

Update Branding

Set (or clear, with null) your hosted-flow branding. A field outside logoUrl/companyName/primaryColor/darkMode is rejected with 400.

PUT /v1/settings/branding

Request Body:

json
{
  "logoUrl": "https://acme.com/logo.svg",
  "companyName": "Acme Corp",
  "primaryColor": "#FF6B00",
  "darkMode": true
}

File Requirements

Supported Formats

  • JPEG (.jpg, .jpeg)
  • PNG (.png)
  • WebP (.webp)

Size Limits

  • Maximum file size: 10MB per file
  • Recommended resolution: 640x480 to 1920x1080

Image Quality Tips

  • Ensure good lighting
  • Face should be clearly visible
  • ID documents should be flat and fully visible
  • Avoid blur, glare, or shadows

Identity Verification API for Africa