List Cards
GET/api/accounts/:accountId/cards
Lists cards by account.
This API uses cursor-based pagination. Start by making a request without a cursor to get the first page. Use the nextCursor from the pageInfo in the response as the cursor for subsequent requests to retrieve further pages. Continue until nextCursor is undefined, indicating no more data.
Request
Path Parameters
AccountId linked to transactions
Query Parameters
Number of records to return
Cursor to retrieve the next page of records
Filter by expiry state
Possible values: [created
, active
, cancelled
, shipped
]
Filter by card status
Timestamp to filter out cards with an expiration date after the given time. Value should be an ISO 8601 string or RFC 2822 string. excludeExpired must be false
Responses
- 200
- 400
- 403
Successful operation
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
items
object[]
Card primary identifier
User account ID linked to card
Possible values: [virtual
]
Type of the card
Timestamp of card creation
Timestamp of card modification
Timestamp of card expiration
Whether the card is blocked
Possible values: [active
, cancelled
, created
, shipped
]
Status of the card
List of Funding Source IDs linked to the card
ID of card program linked to the card
An Alpha2 (ISO-3166-1) country code representing the country where the card is issued.
Expiry date of the card
First 6 digits of the card's PAN (Primary Account Number)
Last 4 digits of the card's PAN (Primary Account Number)
Deprecated field, use expiresAt
pageInfo
object
Page info for paginated results, undefined if no page info
Cursor for next page, undefined if no more pages
{
"items": [
{
"id": "91ad6fea3b52ca58d60d7fd310f789ec",
"accountId": "057aa15913a57f50577234c8426534c0",
"type": "virtual",
"createdAt": "2022-11-16T03:13:18.142Z",
"modifiedAt": "2022-11-16T03:13:18.142Z",
"expiresAt": "2029-02-28T23:59:59.999Z",
"isBlocked": true,
"status": "active",
"fundingSourceIds": [
null
],
"cardProgramId": "91ad6fea3b52ca58d60d7fd310f789ec",
"regionCode": "NZ",
"expiry": "202409",
"panFirst6": "123456",
"panLast4": "1920",
"immersveExpiration": "2022-11-16T03:18:23.431Z"
}
],
"pageInfo": {
"nextCursor": "dGhlIG5leHQgY3Vyc29yIGdvZXMgaGVyZQ=="
}
}
Request fields are invalid
- application/json
- Schema
- Example (from schema)
Schema
{
"statusCode": 400,
"statusName": "Bad Request",
"errorCode": "BAD_REQUEST",
"errors": [
"Expected string, received number"
]
}
No Authorization to access resource.
- application/json
- Schema
- Example (from schema)
Schema
{
"statusCode": 403,
"statusName": "Forbidden",
"errorCode": "FORBIDDEN",
"reason": "Unauthorized"
}