Skip to main content

1. Get Your API Key

Sign in to the DeepXL Dashboard and create an API key from the API Keys section.

2. Detect Document Fraud

Upload a file to the Document Model to check for manipulation:
curl -X POST https://api.deepxl.ai/v1/detection \
  -H "x-api-key: YOUR_API_KEY" \
  -F "model=document" \
  -F "file=@bank_statement.pdf" \
  -F 'tags={"customerId":"9999","documentId":"DOC-001"}'
You will receive a response with a fraud likelihood score (0–100%), severity level (low, medium, high), quality classification (verified, unverified, rejected), and detailed reasoning:
{
  "result": {
    "detectionId": 42,
    "mediaType": "document",
    "fileType": "pdf",
    "fileName": "bank_statement.pdf",
    "fileSize": 245678,
    "timestamp": 1725795600,
    "timestampISO": "2024-09-08T10:00:00.000000",
    "model": "document",
    "modelVersion": "1.1.0",
    "likelihood": 15.5,
    "fraudSeverity": "low",
    "classification": "verified",
    "reasoning": [
      "Document structure appears authentic",
      "No manipulation detected"
    ],
    "modelResults": {
      "technicalChecks": [
        { "type": "DOCUMENT_CLASSIFIER", "status": "PASS", "details": "Classified as bank statement", "likelihood": 0.0 },
        { "type": "SEMANTIC_QUALITY", "status": "PASS", "details": "Image quality is acceptable", "likelihood": 0.0 },
        { "type": "SEMANTIC_FRAUD", "status": "PASS", "details": "No tampering indicators found", "likelihood": 0.0 }
      ]
    },
    "files": [
      {
        "category": "original_file",
        "fileName": "fd_42_bank_statement.pdf",
        "url": "https://api.deepxl.ai/v1/files/fd_42_bank_statement.pdf"
      }
    ]
  }
}

3. Extract Data from a Document

Use the Parsing Model to extract structured data from an ID:
curl -X POST https://api.deepxl.ai/v1/parse \
  -H "x-api-key: YOUR_API_KEY" \
  -F "model=light" \
  -F "file=@drivers_license.jpg"
{
  "result": {
    "parseId": 117,
    "mediaType": "image",
    "fileType": "jpeg",
    "fileName": "drivers_license.jpg",
    "fileSize": 231433,
    "timestamp": 1725795600,
    "timestampISO": "2024-09-08T10:00:00.000000",
    "model": "light",
    "modelVersion": "1.2.0",
    "likelihood": 100.0,
    "documentType": "usa_driver_license",
    "parsedData": {
      "firstName": "JOHN",
      "lastName": "DOE",
      "dateOfBirth": "1990-05-15",
      "licenseNumber": "D1234567",
      "expirationDate": "2028-05-15",
      "address": "123 MAIN ST ANYTOWN, CA 90210"
    },
    "files": [
      {
        "category": "original_file",
        "fileName": "drivers_license.jpg",
        "url": "https://api.deepxl.ai/v1/files/parse_117_drivers_license.jpg"
      }
    ]
  }
}

4. Verify Identity

Use the ID-Selfie Model to match a person’s ID against their selfie:
curl -X POST https://api.deepxl.ai/v1/verification \
  -H "x-api-key: YOUR_API_KEY" \
  -F "idFile=@passport.jpg" \
  -F "selfieFile=@selfie.jpg"
{
  "result": {
    "verificationId": 457,
    "idFileName": "passport.jpg",
    "selfieFileName": "selfie.jpg",
    "timestamp": 1725795600,
    "timestampISO": "2024-09-08T10:00:00.000000",
    "model": "verification",
    "modelVersion": "1.0.0",
    "verified": true,
    "modelResults": {
      "technicalChecks": [
        {
          "checkType": "face_detection",
          "likelihood": 99.85,
          "faceCount": { "id": 1, "selfie": 1 },
          "idFaces": [
            { "faceId": "face_1", "detectionConfidence": 0.9992 }
          ],
          "selfieFaces": [
            { "faceId": "face_1", "detectionConfidence": 0.9985 }
          ]
        }
      ]
    },
    "files": [
      {
        "category": "id",
        "fileName": "passport.jpg",
        "url": "https://api.deepxl.ai/v1/files/v_id_457_passport.jpg"
      },
      {
        "category": "face",
        "fileName": "selfie.jpg",
        "url": "https://api.deepxl.ai/v1/files/v_face_457_selfie.jpg"
      }
    ]
  }
}

What’s Next?