Skip to main content
POST
/
v1
/
id-verification
ID Verification API
curl --request POST \
  --url https://identity.contra.id/v1/id-verification

Request

curl -X POST https://identity.contra.id/v1/id-verification \
  -H "x-api-key: $CONTRA_KEY" -H "Content-Type: application/json" \
  -d '{
    "country":   "GB",
    "id_type":   "PASSPORT",
    "image_front": "data:image/jpeg;base64,/9j/4AAQ…",
    "image_back":  null,
    "metadata": { "vendor_user_id": "user-123" }
  }'
BodyTypeRequiredDescription
countryISO-2yesIssuing country code.
id_typeenumyesPASSPORT · DRIVERS_LICENSE · NATIONAL_ID · RESIDENCE_PERMIT · …
image_frontstringyesBase64-encoded JPEG of the front.
image_backstringconditionalRequired for 2-sided documents.
enable_nfcbooleannoRead NFC chip if available (mobile ePassports).
metadataobjectnoEchoed back on the response.

Response · 200

{
  "verification_id": "ver_b3f1c2a4",
  "status":          "passed",
  "result_code":     "0811",
  "checks": {
    "document_authentic":   "passed",
    "mrz_match":            "passed",
    "expiry_check":         "passed",
    "nfc_signature":        "skipped"
  },
  "issuing_country": "GB",
  "document_type":   "PASSPORT"
}

Coverage

4,000+ document types · 226 countries. Combine with Face Match for selfie-to-document verification.