Get Card Transactions for the Department
This endpoint returns card transaction activity for a specific department, identified by its departmentId. The request body accepts date range filters, amount filters, a text search string, and transaction type filters, enabling precise retrieval of departmental spending history. Results are paginated and include full financial event detail for each transaction.
Endpoint
POST /api/teams/departments/{departmentId}/transactions
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 you need to audit or report on card spending for a specific department inside a business customer's team structure. It is suitable for expense management dashboards, departmental budget reconciliation, or compliance reporting where transactions must be filtered by date range, amount, and transaction type.
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| departmentId | integer (int32) | Yes | The unique identifier of the department whose card transactions are being retrieved. |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| dateFrom | string (date-time) | Yes | Start of the date range for transaction filtering (ISO 8601 format). |
| dateTo | string (date-time) | Yes | End of the date range for transaction filtering (ISO 8601 format). |
| searchString | string | No | Optional free-text search string to match against transaction details. |
| filter | object | No | Transaction type filter. Contains nested filter items: all, deposit, withdraw, pos, transactionStatus. Each filter item has displayName (string), value (boolean), and optional nested items array. |
| amountFilter | object | No | Amount range filter with minValue (integer, cents) and maxValue (integer, cents) fields. |
filter object (paymentcardtransactionfilter):
| Field | Type | Required | Description |
|---|---|---|---|
| all | filteritem | No | Filter item for all transaction types. |
| deposit | filteritem | No | Filter item for deposit transactions. |
| withdraw | filteritem | No | Filter item for withdrawal transactions. |
| pos | filteritem | No | Filter item for point-of-sale transactions. |
| transactionStatus | filteritem | No | Filter item for transaction status. |
filteritem object:
| Field | Type | Required | Description |
|---|---|---|---|
| displayName | string | No | Human-readable label for the filter. |
| value | boolean | No | Whether this filter is active (true) or inactive (false). |
| items | array of filteritem | No | Nested sub-filter items. |
amountFilter object:
| Field | Type | Required | Description |
|---|---|---|---|
| minValue | integer (int64) | No | Minimum transaction amount in cents. |
| maxValue | integer (int64) | No | Maximum transaction amount in cents. |
{
"dateFrom": "2026-05-01T00:00:00Z",
"dateTo": "2026-05-31T23:59:59Z",
"searchString": "office supplies",
"filter": {
"all": {
"displayName": "All",
"value": false
},
"pos": {
"displayName": "Point of Sale",
"value": true
},
"transactionStatus": {
"displayName": "Completed",
"value": true
}
},
"amountFilter": {
"minValue": 500,
"maxValue": 50000
}
}Response
200 OK
| Field | Type | Description |
|---|---|---|
| data | array | Array of financial activity records matching the filter criteria. |
| filter | object | Echo of the applied paymentcardtransactionfilter. |
| paginationSettings | object | Pagination metadata containing totalItems (integer). |
data item (financialactivityresponsemodel):
| Field | Type | Description |
|---|---|---|
| id | string | Unique transaction identifier. |
| financialAccountId | string | ID of the financial account associated with the transaction. |
| date | string (date-time) | Transaction date. |
| sortDate | string (date-time) | Date used for sorting results. |
| balance | object | Account balance at time of transaction (value in cents, currencyCode). |
| status | string | Transaction status. One of: OTHER, PENDING, COMPLETED, FAILED. |
| riskHold | boolean | Indicates whether the transaction is on a risk hold. |
| settlementDate | string (date-time) | Settlement date of the transaction, if applicable. |
| purpose | string | Business purpose of the transaction, if applicable. |
| statusReasonCode | string | Reason code for the transaction status, if applicable. |
| amount | object | Transaction amount with value (cents), currencyCode, and symbol. |
| clearAmount | object | Cleared amount with value (cents), currencyCode, and symbol. |
| pendingAmount | object | Pending amount with value (cents) and currencyCode. |
| name | string | Display name for the transaction (e.g., merchant name). |
| last4 | object | Last 4 digits identifier with type (CARD or ACCOUNT) and value. |
| type | string | Transaction type label (read-only). |
| authorizedUser | string | Name or ID of the authorized user who initiated the transaction. |
| merchantCategory | string | Merchant category description. |
| transactionSource | object | Source transaction details including typename, id, and transactionEvents array. |
| rewardPoints | integer (int64) | Reward points earned on this transaction, if applicable. |
| activityInfo | object | Profile and history information including fromProfile, toProfile, and historyRecords. |
| financialEvent | object | Detailed financial event data including merchant details, amounts, status, and card info. |
{
"data": [
{
"id": "txn_abc123def456",
"financialAccountId": "fa_7890xyz",
"date": "2026-05-15T14:23:10Z",
"sortDate": "2026-05-15T14:23:10Z",
"balance": {
"value": 245000,
"currencyCode": "USD"
},
"status": "COMPLETED",
"riskHold": false,
"settlementDate": "2026-05-17T00:00:00Z",
"purpose": null,
"statusReasonCode": null,
"amount": {
"value": 4799,
"currencyCode": "USD",
"symbol": "$"
},
"clearAmount": {
"value": 4799,
"currencyCode": "USD",
"symbol": "$"
},
"pendingAmount": {
"value": 0,
"currencyCode": "USD"
},
"name": "Office Depot",
"last4": {
"type": "CARD",
"value": "4242"
},
"type": "CARD_TRANSACTION",
"authorizedUser": "Jane Smith",
"merchantCategory": "Office Supplies",
"transactionSource": {
"typename": "CardTransaction",
"id": "src_112233",
"transactionEvents": [
{
"typename": "CardAuthorization",
"id": "evt_aabbcc",
"merchantDetails": {
"category": "Office Supplies",
"categoryCode": "5112",
"countryCodeAlpha3": "USA",
"description": "Office supply store",
"name": "Office Depot",
"merchantId": "MID_9988776"
},
"pointOfServiceDetails": {
"panEntryMode": "CHIP",
"pinEntryMode": "NOT_APPLICABLE"
},
"responseCode": "00",
"responseDescription": "Approved",
"approvedAmount": {
"value": 4799,
"currencyCode": "USD"
},
"requestedAmount": {
"value": 4799,
"currencyCode": "USD"
},
"paymentCard": {
"id": "card_xyz789",
"bin": "411111",
"last4": "4242"
},
"createdAt": "2026-05-15T14:23:10Z",
"authorizationExpiration": "2026-05-22T14:23:10Z",
"processingType": "STANDARD",
"rewardPoints": 47,
"accountingDirection": "DEBIT"
}
]
},
"rewardPoints": 47,
"activityInfo": {
"fromProfile": {
"id": 1001,
"name": "Marketing Department",
"agentId": 55
},
"toProfile": null,
"historyRecords": [
{
"date": "2026-05-15T14:23:10Z",
"status": "COMPLETED"
}
]
},
"financialEvent": {
"id": "fe_998877",
"accountingDirection": "DEBIT",
"processingType": "STANDARD",
"typename": "CardTransaction",
"merchantDetails": {
"category": "Office Supplies",
"categoryCode": "5112",
"countryCodeAlpha3": "USA",
"description": "Office supply store",
"name": "Office Depot",
"merchantId": "MID_9988776"
},
"paymentCard": {
"id": "card_xyz789",
"bin": "411111",
"last4": "4242"
},
"amount": {
"value": 4799,
"currencyCode": "USD"
},
"status": "COMPLETED",
"statusReason": null,
"memo": null,
"purpose": null,
"createdAt": "2026-05-15T14:23:10Z",
"updatedAt": "2026-05-17T00:00:00Z",
"settlementDate": "2026-05-17T00:00:00Z",
"partial": false,
"responseCode": "00",
"avsResponseCode": null,
"cvvResponseCode": null,
"postalCodeResponseCode": null
}
}
],
"filter": {
"pos": {
"displayName": "Point of Sale",
"value": true
},
"transactionStatus": {
"displayName": "Completed",
"value": true
}
},
"paginationSettings": {
"totalItems": 1
}
}Error Codes
| Code | When it happens |
|---|---|
| 400 | Missing required fields (dateFrom or dateTo) or invalid date format |
| 401 | Token missing, expired, or invalid |
| 403 | Insufficient permissions to access this department's transactions |
| 404 | Department with the specified departmentId not found |
| 500 | Internal server error |
Common Mistakes
- Omitting
dateFromordateTo— both are required fields; the request will fail with a 400 error if either is missing. - Passing amount values in dollars instead of cents —
minValueandmaxValueinamountFiltermust be in the smallest currency unit (cents). For example, $10.00 should be sent as1000. - Using an invalid or expired Bearer token — tokens expire after 10 minutes; call
POST /api/auth/refreshto obtain a new one before the expiry. - Sending a
departmentIdfor a department that does not belong to the authenticated partner's business customer, which will result in a 403 or 404 response. - Setting all filter
valuefields tofalse— this may return no results or behave unexpectedly; ensure at least one relevant filter is enabled or omit thefilterobject to retrieve all transaction types.
Related Endpoints
POST /api/teams/departments/{departmentId}/transactions— this endpointGET /api/teams/departments— list all departments for the business teamGET /api/teams/departments/{departmentId}— retrieve details for a specific departmentPOST /api/financialaccounts/{financialAccountId}/transactions— retrieve transactions for a specific financial account
Example
curl -X POST https://api.banking.netevia.dev/api/teams/departments/42/transactions \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"dateFrom": "2026-05-01T00:00:00Z",
"dateTo": "2026-05-31T23:59:59Z",
"searchString": "office supplies",
"filter": {
"pos": {
"displayName": "Point of Sale",
"value": true
},
"transactionStatus": {
"displayName": "Completed",
"value": true
}
},
"amountFilter": {
"minValue": 500,
"maxValue": 50000
}
}'