Get Sub Users Payment Cards
Returns payment cards associated with authorized users (subProfiles) on a business customer account. Results can be filtered by card last four digits or the cardholder's name, and are returned in paginated form. This endpoint is only applicable to business customers who have created subProfiles.
Endpoint
GET /api/subProfiles/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 when a business account owner or administrator needs to view all payment cards issued to authorized users under their account. It is useful for auditing card access, reviewing card assignments, or locating a specific subProfile's card by partial card number or name.
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| take | integer (int32) | No | Number of records to return. Default: 20. |
| skip | integer (int32) | No | Number of records to skip for pagination. Default: 0. |
| last4 | string | No | Filter results by the last four digits of the card number. |
| firstName | string | No | Filter results by the cardholder's first name. |
| lastName | string | No | Filter results by the cardholder's last name. |
Response
200 OK
A successful response returns a list of payment cards belonging to authorized users. Each card record typically includes card identification details, the associated subProfile, card status, and card type.
{
"data": [
{
"cardId": "card_abc123",
"last4": "4321",
"cardType": "Virtual",
"status": "Active",
"subProfileId": "sub_xyz789",
"firstName": "Jane",
"lastName": "Smith",
"expirationDate": "12/27"
},
{
"cardId": "card_def456",
"last4": "8765",
"cardType": "Physical",
"status": "Active",
"subProfileId": "sub_uvw321",
"firstName": "John",
"lastName": "Doe",
"expirationDate": "09/26"
}
],
"total": 2,
"take": 20,
"skip": 0
}Error Codes
| Code | When it happens |
|---|---|
| 400 | Invalid query parameter format (e.g., non-integer value for take or skip) |
| 401 | Token missing, expired, or invalid |
| 403 | Caller does not have permission to access subProfile payment card data |
| 404 | No subProfiles or payment cards found for the account |
| 500 | Internal server error |
Common Mistakes
- Calling this endpoint with a personal customer token — subProfiles and their cards only exist under business accounts.
- Passing a full card number instead of just the last four digits in the
last4filter; only the last four digits are accepted. - Omitting pagination parameters and assuming all records are returned — the default page size is 20; use
skipto iterate through additional pages. - Using incorrect data types for
takeorskip(must be integers); passing strings will result in a 400 error.
Related Endpoints
GET /api/subProfiles— List all authorized users (subProfiles) under the business accountPOST /api/subProfiles— Create a new authorized user (subProfile)GET /api/subProfiles/{subProfileId}— Retrieve details for a specific subProfilePOST /api/subProfiles/paymentCards— Issue a new payment card to an authorized user
Example
curl -X GET "https://api.banking.netevia.dev/api/subProfiles/paymentCards?take=20&skip=0&lastName=Smith" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json"