Documentation
  • Introduction
  • ⚡Quick Guide
  • APIs
    • 🇦🇪UAE Resident ID OCR
    • 🔑OAuth Token
    • 🆔National ID OCR
      • 🔁API Response
    • 🧑‍💼Face Match
      • Face Match (Two Images)
      • Face Match (Image & Transaction ID)
    • ✈️Passport
    • ✈️Libyan passport
    • 🚗Egyptian Car License
    • 🇲🇦Moroccan Documents OCR
      • 🆔Moroccan National ID (MRZ & Barcode)
      • ✈️Moroccan Passport
      • 🗂️Moroccan Residency Card
      • 🚗Moroccan Driving License
    • ↔️Transliteration
      • National ID Transliteration
      • Commercial Register Translation
      • Names Transliteration
    • 🏫Know Your Business (eKYB)
      • 📖Data Extraction & Verifications
        • Egyptian Commercial Register ID OCR
          • ✅With Verification
        • Egyptian Tax Card OCR
    • 📄Valify Sanction Shield
      • Sanction Shield v2.1.0
    • Sanction Shield v2.0.0
    • 🛡️Supported lists
    • ❓Transaction Inquiry
    • 📷Fetch Images
    • 🔒OTP
      • 📲Send Phone OTP
      • ✅Verify Phone OTP
      • 📥Send Email OTP
      • ✅Verfiy Email OTP
    • Response Data Validation
  • Error Codes
    • Valify Error Codes
    • HTTP Codes
  • References
Powered by GitBook
On this page
  1. APIs
  2. Moroccan Documents OCR

Moroccan Passport

This API provides Data Extraction for Moroccan Travel Passport documents.

Moroccan Passport OCR

POST https://valifystage.com/api/v1/ocr/

Headers

Name
Type
Description

Content-Type

string

application/json

Authentication

string

bearer <access-token>

Request Body

Name
Type
Description
Notes

document_type

string

mar_passport

data

object

Object containing the parameters below: { img: <base64 str> #optional default is "", bundle_key: <str>, lang: <str> optional default is "" }

Please note thatimg cannot be empty (i.e., missing or an empty string "").

{
    "result": {
        "first_name": {
            "arabic": <string>,
            "latin": <string>
        },
        "family_name": {
            "arabic": <string>,
            "latin": <string>
        },
        "nationality": {
            "arabic": <string>,
            "latin": <string>
        },
        "sex": <string>,
        "place_of_birth": <string>,
        "date_of_issue": <string>,
        "date_of_expiry": <string>,
        "authority": <string>,
        "residence": <string>,
        "date_of_birth": <string>,
        "type": <string>,
        "code": <string>,
        "passport_no": <string>,
        "id_card_no": <string>
    },
    "transaction_id": <string>,
    "trials_remaining": <int>
}
{
    "message": "Bad Request – invalid request received (e.g. missing Bundle key, required parameters or invalid json) | Make sure all the required parameters are included"
}
{
    "message": "Unauthorized – your Bundle key is invalid"
}
{
    "message": "Forbidden – specified access_token could not be found"
}
{
    "message": "Not Found"
}
{
    "message": "Unsupported Media Type"
}
{
    "message": "<error-description>",
    "error_code": <valify-error-code>
}
{
    "message": "Internal Server Error"
}
PreviousMoroccan National ID (MRZ & Barcode)NextMoroccan Residency Card

Last updated 6 days ago

🇲🇦
✈️