Document Verification
Upload identity documents for automated verification. Supports ID cards, passports, driver's licenses, and residence permits. Images are analyzed using OCR and fraud detection algorithms.
POST
/verifications/documentSubmit a document for verification. Upload front (required) and back (optional) images via multipart form data.
Max file size: 10MB per image. Accepted formats: JPEG, PNG, WebP, HEIC.
Form Fields
| Parameter | Type | Description |
|---|---|---|
userIdrequired | string | User ID to associate this document with |
documentTyperequired | enum | ID_CARD, PASSPORT, DRIVER_LICENSE, or RESIDENCE_PERMIT |
documentCountryrequired | string | ISO 3166-1 alpha-2 country code (e.g., NG, US, GB) |
frontImagerequired | file | Front of the document (binary) |
backImage | file | Back of the document (optional for passports) |
Code Examples
curl -X POST https://api.verifyhq.wejoona.com/verifications/document \
-H "X-API-Key: your_api_key" \
-F "userId=user_123" \
-F "documentType=ID_CARD" \
-F "documentCountry=NG" \
-F "frontImage=@id_front.jpg" \
-F "backImage=@id_back.jpg"Response
201 Createdjson
{
"id": "doc_xyz789",
"userId": "user_123",
"documentType": "ID_CARD",
"documentCountry": "NG",
"frontImageUrl": "/uploads/id_front.jpg",
"backImageUrl": "/uploads/id_back.jpg",
"status": "PENDING",
"createdAt": "2026-05-25T10:31:00Z",
"updatedAt": "2026-05-25T10:31:00Z"
}GET
/verifications/document/:idRetrieve a document verification by ID.
200 OK — Verifiedjson
{
"id": "doc_xyz789",
"userId": "user_123",
"documentType": "ID_CARD",
"documentCountry": "NG",
"frontImageUrl": "/uploads/id_front.jpg",
"backImageUrl": "/uploads/id_back.jpg",
"status": "VERIFIED",
"extractedData": {
"fullName": "Adebayo Ogunlesi",
"dateOfBirth": "1990-05-15",
"documentNumber": "A12345678",
"expiryDate": "2030-12-31",
"nationality": "Nigerian"
},
"confidence": 0.97,
"verifiedAt": "2026-05-25T10:31:45Z",
"createdAt": "2026-05-25T10:31:00Z",
"updatedAt": "2026-05-25T10:31:45Z"
}GET
/verifications/document/user/:userIdList all document verifications for a user.
Query Parameters
| Parameter | Type | Description |
|---|---|---|
page | number | Page number (default: 1) |
limit | number | Items per page (default: 20, max: 100) |
200 OKjson
{
"data": [
{
"id": "doc_xyz789",
"userId": "user_123",
"documentType": "ID_CARD",
"documentCountry": "NG",
"frontImageUrl": "/uploads/id_front.jpg",
"status": "PENDING",
"createdAt": "2026-05-25T10:31:00Z",
"updatedAt": "2026-05-25T10:31:00Z"
}
],
"total": 1,
"page": 1,
"limit": 20
}Supported Document Types
| Parameter | Type | Description |
|---|---|---|
ID_CARD | type | National identity card (front + back required) |
PASSPORT | type | International passport (front only, back optional) |
DRIVER_LICENSE | type | Driver's license (front + back required) |
RESIDENCE_PERMIT | type | Residence permit / work permit (front + back required) |
Document Country
Provide the issuing country with the documentCountry field using an ISO 3166-1 alpha-2 code. Supported-country coverage should be treated as a provider configuration concern until the API publishes a generated country list.