Get List of Payment Cards
The GET /api/paymentCards endpoint retrieves all payment cards linked to the authenticated customer's account. The response includes masked card numbers, card type, expiration details, network, status, and the financial accounts each card is associated with. This endpoint supports both personal and business customers and returns paginated results via a cursor-based connection structure.
Endpoint
GET /api/paymentCards
Authentication
Bearer token required. Obtain via:
POST https://api.banking.netevia.dev/api/auth/v2
Include in header: Authorization: Bearer {token} Token lifetime: 10 minutes. Refresh via POST /api/auth/refresh.
When to use
Use this endpoint to display a customer's card portfolio in a dashboard or card management screen. It is the primary way to enumerate all physical, virtual, and burner cards for a given account holder, including cards assigned to authorized users (subProfiles) on business accounts. Call this endpoint before performing card-specific operations (e.g., freeze, update spending limits) to obtain the card id required by those endpoints.
Response
200 OK
The response is wrapped in a GraphQL-style edge/node connection. The top-level node is an accountholder object containing account holder identity and a nested paymentCards connection.
Top-level response — edge_accountholder
| Field | Type | Description |
|---|---|---|
cursor | string | Pagination cursor for this edge |
node | object | Account holder object containing identity and card data |
node — accountholder
| Field | Type | Description |
|---|---|---|
typename | string | Discriminator indicating the account holder type (e.g., "PersonAccountHolder", "BusinessAccountHolder") |
name | object | Personal name of the account holder (see person.name below) |
businessProfile | object | Business name details; present only for business customers |
primaryAuthorizedPerson | object | Name of the primary authorized person on a business account |
paymentCards | object | Paginated connection containing all payment cards (see connection_paymentcardresponse below) |
name — person.name
| Field | Type | Description |
|---|---|---|
givenName | string | First name |
familyName | string | Last name |
title | string | Name title (e.g., "Mr.", "Dr.") |
suffix | string | Name suffix (e.g., "Jr.", "III") |
middleName | string | Middle name |
businessProfile.name — business.businessname
| Field | Type | Description |
|---|---|---|
legalBusinessName | string | Registered legal name of the business |
doingBusinessAsName | string | DBA (trade) name, if applicable |
paymentCards — connection_paymentcardresponse
| Field | Type | Description |
|---|---|---|
pageInfo | object | Pagination metadata (see pageinfo below) |
edges | array | Array of edge objects, each containing a cursor and a paymentcardresponse node |
pageInfo — pageinfo
| Field | Type | Description |
|---|---|---|
startCursor | string | Cursor of the first item in the current page |
endCursor | string | Cursor of the last item in the current page; pass as after in next request to fetch the next page |
hasNextPage | boolean | true if more pages exist after the current page |
hasPreviousPage | boolean | true if more pages exist before the current page |
edges[].node — paymentcardresponse
| Field | Type | Description |
|---|---|---|
id | string | Unique identifier of the payment card |
bin | string | Bank Identification Number (first 6 digits of the card number) |
last4 | string | Last 4 digits of the card number |
status | string | Current card status (e.g., "ACTIVE", "SUSPENDED", "CLOSED") |
formFactor | string | Physical form of the card (e.g., "PHYSICAL", "VIRTUAL") |
expirationDate | string | Full expiration date (format: MM/YY) |
expirationMonth | string | Expiration month (two-digit, e.g., "09") |
expirationYear | string | Expiration year (two- or four-digit, e.g., "2027") |
network | string | Card network (e.g., "VISA", "MASTERCARD") |
cardType | integer | Card type enum: 0 = Unknown, 1 = Physical, 2 = Virtual, 3 = Burner, 4 = Other |
cardholder | string | Name printed on the card |
financialAccounts | array | Financial accounts linked to this card (see financialaccountshort below) |
subProfile | string | Identifier of the authorized user (subProfile) this card is assigned to, if applicable |
department | string | Department label associated with the card (business accounts) |
financialAccounts[] — financialaccountshort
| Field | Type | Description |
|---|---|---|
id | string | Unique identifier of the linked financial account |
name | string | Display name of the linked financial account |
{
"cursor": "Y3Vyc29yOnYyOpK5MjAyNC0wMS0xNVQxMjowMDowMCswMDowMM4A",
"node": {
"typename": "BusinessAccountHolder",
"name": {
"givenName": "Jane",
"familyName": "Smith",
"title": null,
"suffix": null,
"middleName": null
},
"businessProfile": {
"name": {
"legalBusinessName": "Acme Corporation LLC",
"doingBusinessAsName": "Acme Corp"
}
},
"primaryAuthorizedPerson": {
"name": {
"givenName": "Jane",
"familyName": "Smith",
"title": null,
"suffix": null,
"middleName": null
}
},
"paymentCards": {
"pageInfo": {
"startCursor": "Y3Vyc29yOnYyOpHOAA==",
"endCursor": "Y3Vyc29yOnYyOpHOBB==",
"hasNextPage": false,
"hasPreviousPage": false
},
"edges": [
{
"cursor": "Y3Vyc29yOnYyOpHOAA==",
"node": {
"id": "pcd_01HQ8K3MNPZ2VWXY4567890ABC",
"bin": "411111",
"last4": "4242",
"status": "ACTIVE",
"formFactor": "PHYSICAL",
"expirationDate": "09/27",
"expirationMonth": "09",
"expirationYear": "2027",
"network": "VISA",
"cardType": 1,
"cardholder": "JANE SMITH",
"financialAccounts": [
{
"id": "fac_01HQ8K3MNPZ2VWXY1234567DEF",
"name": "Business Checking"
}
],
"subProfile": null,
"department": "Operations"
}
},
{
"cursor": "Y3Vyc29yOnYyOpHOBB==",
"node": {
"id": "pcd_01HQ8K3MNPZ2VWXY9876543XYZ",
"bin": "411111",
"last4": "8888",
"status": "ACTIVE",
"formFactor": "VIRTUAL",
"expirationDate": "02/26",
"expirationMonth": "02",
"expirationYear": "2026",
"network": "VISA",
"cardType": 2,
"cardholder": "JOHN DOE",
"financialAccounts": [
{
"id": "fac_01HQ8K3MNPZ2VWXY1234567DEF",
"name": "Business Checking"
}
],
"subProfile": "sub_01HQ8K3MNPZ2VWXY1111111SUB",
"department": "Marketing"
}
}
]
}
}
}Error Codes
| Code | When it happens |
|---|---|
| 401 | Token missing, expired, or invalid |
| 403 | Insufficient permissions to view payment cards |
| 500 | Internal server error |
Common Mistakes
- Forgetting that card numbers are never returned in full — use
bin+last4to identify a card in UI display; do not attempt to reconstruct the full PAN. - Ignoring pagination: if
pageInfo.hasNextPageistrue, you must make additional requests using theendCursorvalue to retrieve all cards. - Treating
cardTypeas a string — the schema defines it as an integer enum (0–4); map to labels (Physical, Virtual, Burner) in your client code. - Assuming
subProfileis always present — it isnullfor cards owned directly by the main account holder and only populated for authorized user (subProfile) cards on business accounts. - Confusing
formFactor(the physical/digital form) withcardType(the product type) — both may be needed to fully categorize a card.
Related Endpoints
POST /api/paymentCards— Issue a new payment card (physical, virtual, or burner)GET /api/paymentCards/{cardId}— Retrieve details for a specific payment card by IDPUT /api/paymentCards/{cardId}/status— Update the status of a payment card (freeze, unfreeze, close)GET /api/financialAccounts— List financial accounts that can be linked to payment cardsGET /api/subProfiles— List authorized users (subProfiles) for a business account
Example
curl -X GET https://api.banking.netevia.dev/api/paymentCards \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json"