Get Card
Use this route to return an object with data from a previously created card. Only the card_id passed in the endpoint PATH is required.
GETv3/cards/:card_id
Request Variable Path
| Attribute | Type | Description |
|---|---|---|
| card_id | string | ID of the previously saved card. |
Response Object
| Property | Type | Description |
|---|---|---|
| card_id | string | Card identifier hash. |
| date_created | dateTime | Card creation date in ISODateTime format. |
| date_updated | dateTime | Card update date in ISODateTime format. |
| card_holder_name | string | Cardholder name. |
| card_brand | string | Card brand. Possible values: visa, mastercard, amex, hipercard and elo. |
| card_first_digits | string | First 6 digits of the card. |
| card_last_digits | string | Last 4 digits of the card. |
| card_expiration_date | string | Card expiration date. Numbers only in MMYY format. |
| valid | boolean | Property to verify card validity, that is, if true, the card can be charged under normal conditions, if false, it cannot be used. |
Response Example
{
"card_id": "card_princess12leia45organa678",
"date_created": "2025-01-01T00:00:00.000Z",
"date_updated": "2025-01-01T00:00:00.000Z",
"card_holder_name": "Leia S O Solo",
"card_brand": "mastercard",
"card_first_digits": "444455",
"card_last_digits": "3333",
"card_expiration_date": "0504",
"valid": true
}
Error Object
| Attribute | Type | Description |
|---|---|---|
| api_reference | string | URL for documentation. |
| errors | array | Array with all errors found when processing the request. |
| errors[][type] | string | Type of error that occurred. |
| errors[][message] | string | Detailed error message. |
Error Example
{
"api_reference": "https://docs.api.marlim.co/cards/read",
"errors": [
{
"type": "parameter",
"message": "The parameter [ card_cvv ] is missing."
}
]
}
Examples
- Card Found
- Card Not Found
curl -X GET -G "https://api.marlim.co/v3/cards/card_princess12leia45organa678" \
-H "Content-Type: application/json" \
-H "api_key: api_key_value" \
{
"card_id": "card_princess12leia45organa678",
"date_created": "2025-07-29T11:38:57.596Z",
"date_updated": "2025-07-29T11:38:57.596Z",
"card_holder_name": "Leia S O Solo",
"card_brand": "mastercard",
"card_first_digits": "444455",
"card_last_digits": "3333",
"card_expiration_date": "0504",
"valid": true
}
curl -X GET -G "https://api.marlim.co/v3/cards/card_wookiee123chewbacca456789" \
-H "Content-Type: application/json" \
-H "api_key: api_key_value" \
{
"api_reference": "https://docs.api.marlim.co/cards/read",
"errors": [
{
"type": "not_found",
"message": "Card with ID 'card_wookiee123chewbacca456789' was not found."
}
]
}