Document Types

Dokai supports ASEAN identity documents across multiple countries. Each document brand has specific extracted fields tailored to its format. If you omit the type and brand parameters, Dokai auto-detects the document.

Document categories

The document_type parameter specifies the broad category. Most documents are auto-detected.

TypeLabelDescription
identity_cardIdentity CardNational identity cards (MyKad, KTP, NRIC)
passportPassportInternational travel passports with MRZ
driving_licenseDriving LicenseGovernment-issued driving licenses
work_permitWork PermitEmployment and work authorization documents
birth_certificateBirth CertificateOfficial birth registration documents
otherOtherAny document not matching the above categories

Regional brands

The document_brand parameter specifies the exact regional variant. Each brand maps to a parent document type and defines which fields are extracted.

MyKad

Malaysiamykad

Malaysian national identity card for citizens aged 12+

Parent type: identity_card

Extracted fields

FieldDescription
full_nameFull name as printed on the card
id_number12-digit IC number (e.g. 880503-14-5234)
date_of_birthDate of birth (YYYY-MM-DD)
genderM or F
nationalityWARGANEGARA (citizen)
addressFull residential address

Extra fields

Returned in the extra object when available.

religionrace

Derived fields

Computed automatically from the extracted data.

state_of_birth (from IC prefix)age (calculated)

MyPR

Malaysiamypr

Malaysian permanent resident identity card

Parent type: identity_card

Extracted fields

FieldDescription
full_nameFull name
id_number12-digit IC number
date_of_birthDate of birth (YYYY-MM-DD)
genderM or F
nationalityPEMASTAUTIN TETAP (permanent resident)
addressFull residential address

Extra fields

Returned in the extra object when available.

country_of_origin

MyKAS

Malaysiamykas

Malaysian temporary resident identity card

Parent type: identity_card

Extracted fields

FieldDescription
full_nameFull name
id_number12-digit IC number
date_of_birthDate of birth (YYYY-MM-DD)
genderM or F
nationalityCountry of origin
addressResidential address in Malaysia

KTP

Indonesiaktp

Kartu Tanda Penduduk — Indonesian national identity card

Parent type: identity_card

Extracted fields

FieldDescription
full_nameFull name (Nama)
id_number16-digit NIK number
date_of_birthDate of birth (Tanggal Lahir)
place_of_birthPlace of birth (Tempat Lahir)
genderLAKI-LAKI or PEREMPUAN
addressFull address (Alamat)
blood_typeBlood type (Gol. Darah)

Extra fields

Returned in the extra object when available.

religionmarital_statusoccupationrt_rwkelurahankecamatan

Derived fields

Computed automatically from the extracted data.

province (from NIK prefix)

NRIC

Singaporenric

National Registration Identity Card — Singapore identity card

Parent type: identity_card

Extracted fields

FieldDescription
full_nameFull name
id_numberNRIC number (e.g. S8805034Z)
date_of_birthDate of birth (YYYY-MM-DD)
genderM or F
raceRace/ethnicity
addressRegistered address

Extra fields

Returned in the extra object when available.

country_of_birth

Thai ID

Thailandthai_id

Thai national identity card (Bat Prachachon)

Parent type: identity_card

Extracted fields

FieldDescription
full_nameFull name (Thai and English)
id_number13-digit citizen ID
date_of_birthDate of birth
genderM or F
addressAddress

Extra fields

Returned in the extra object when available.

issue_dateexpiry_date

Thai DL

Thailandthai_dl

Thai driving license

Parent type: driving_license

Extracted fields

FieldDescription
full_nameFull name
id_numberLicense number
date_of_birthDate of birth
license_classVehicle class
issue_dateIssue date
expiry_dateExpiration date

Passports

passport

International passports from any country. Dokai reads both the visual inspection zone (VIZ) and the machine readable zone (MRZ), cross-validating fields and checksums.

Extracted fields

FieldDescription
full_nameFull name (surname + given names)
passport_numberPassport number
nationalityNationality (3-letter country code)
date_of_birthDate of birth (YYYY-MM-DD)
genderM or F
date_of_issueIssue date
date_of_expiryExpiration date
place_of_birthPlace of birth
issuing_authorityIssuing authority or country
mrz_line_1First MRZ line (raw)
mrz_line_2Second MRZ line (raw)

Derived fields

mrz_valid (checksum verification)days_until_expiry (calculated)

Auto-detection

When you omit document_type and document_brand, Dokai analyzes the document image and automatically determines the type and brand. The detected values are returned in the response.

For best accuracy, provide the type and brand if you know them. Auto-detection adds minimal latency (<100ms) but may occasionally misidentify heavily damaged or unusual documents.

Plan restrictions

Free plan: Limited to identity_card and passport document types only (MyKad and Passport brands).

Starter plan: All document types and brands.

Pro & Business: All document types and brands, plus deep scan and batch processing.

Next steps