Malaysian ID Extraction
Extracts ID number, name, sex, date of birth and address from a Malaysian ID card (MyKad).
Content-Type: application/json
Headers
| Header | Type | Required | Description |
|---|---|---|---|
key | string | Yes | API key issued for authentication. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
recordId | string | Yes | Unique ID you assign to correlate the request with the response. |
image | string | Yes | Base64 string / data URI of the Malaysian ID image. |
Example
POST/pcs/MalaysianId
curl --location 'https://sandbox/pcs/MalaysianId' \
--header 'key: <your-api-key>' \
--header 'Content-Type: application/json' \
--data '{
"recordId": "1",
"image": "data:image/png;base64,<BASE64_STRING>"
}'200
{
"status": "success",
"recordId": "1",
"data": {
"idNumber": "123456",
"name": "name-string",
"sex": "sex-string",
"dob": "dob-string",
"address": "address-string"
},
"utc_time_stamp": "07/11/2024, 07:35:09"
}Response
| Field | Type | Description |
|---|---|---|
status | string | success when data was extracted. |
recordId | string | Echoes the recordId sent in the request. |
data.idNumber | string | MyKad identification number. |
data.name | string | Holder's name. |
data.sex | string | Holder's sex. |
data.dob | string | Date of birth. |
data.address | string | Full address as printed on the card. |
utc_time_stamp | string | UTC timestamp of the response, DD/MM/YYYY, HH:mm:ss. |
Error handling
200 on success, 422 on a validation error — see
Error handling for the common error shape.