Bank Transactions
Bank transactions represent financial transactions that occur in bank accounts. They can be imported from bank statements or created manually, and are used to track money movement and reconcile with accounting records.
Endpoints
| Method | Endpoint | Description |
|---|---|---|
| GET | /bank-transactions | List bank transactions |
| GET | /bank-transactions/{id} | Get a specific bank transaction |
| POST | /bank-transactions | Create a bank transaction |
| GET | /bank-transactions/{id}/statements | List statements for a bank transaction |
| POST | /bank-transactions/{id}/statements | Create a statement for a bank transaction |
Query Parameters
The GET /bank-transactions endpoint supports the following query parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
| client_account_id | integer | No | Filter by client account ID. Must be one of the user’s eligible client accounts |
| bank_account_id | integer | No | Filter by bank account ID |
| from_date | date | No | Filter transactions from this booking date (inclusive) |
| to_date | date | No | Filter transactions to this booking date (inclusive) |
| include_externally_reconciled | boolean | No | Whether to include externally reconciled transactions |
| order_by | string | No | Sort order (default: booking_date asc, amount asc) |
| page | integer | No | Page number for pagination (default: 1) |
| per_page | integer | No | Number of items per page (default: 50) |
| with | string | No | Include related resources. Comma-separated list (supported: receivable_payments, questions, statements, reconciled_documents). details is always included |
Attributes
| Attribute | Type | Description |
|---|---|---|
| id | integer | The unique identifier of the transaction |
| client_account_id | integer | The ID of the client account |
| payee_name | string | The name of the payee |
| payee_bank_account_id | integer | The ID of the payee’s bank account |
| payor_name | string | The name of the payor |
| payor_bank_account_id | integer | The ID of the payor’s bank account |
| message_id | string | The message ID from the bank |
| payment_id | string | The payment ID from the bank |
| instruction_id | string | The instruction ID from the bank |
| end_to_end_id | string | The end-to-end ID for the transaction |
| booking_date | date | The date the transaction was booked |
| value_date | date | The value date of the transaction |
| memo | string | The transaction memo or description |
| instructed_amount | decimal | The originally instructed amount |
| instructed_currency_code | string | The currency code of the instructed amount |
| instructed_exchange_rate | decimal | The exchange rate for the instructed amount |
| amount | decimal | The transaction amount in account currency |
| currency_code | string | The currency code of the transaction |
| exchange_rate | decimal | The exchange rate used |
| bank_reference | string | The bank’s reference for the transaction |
| external_reconciled_amount | decimal | The amount that has been externally reconciled |
Transaction Details
Each bank transaction includes details that provide additional information about the transaction:
| Attribute | Type | Description |
|---|---|---|
| id | integer | The unique identifier of the detail record |
| transaction_type | string | The type of transaction |
| account_name | string | The name on the account |
| account_number | string | The account number |
| account_currency_code | string | The currency code of the account |
| archive_reference | string | Reference for archival purposes |
| structured_reference | string | Structured payment reference |
| bank_information | string | Additional information from the bank |
| amount | decimal | The transaction amount |
| currency_code | string | The currency code |
| description | string | Detailed description of the transaction |
| booking_date | date | The booking date |
| value_date | date | The value date |
| invoice_number | string | Related invoice number if applicable |
| sender_name | string | Name of the sender |
| sender_account | string | Account number of the sender |
| receiver_name | string | Name of the receiver |
| receiver_account | string | Account number of the receiver |
| transaction_uuid | string | Unique identifier from the bank |
| statement_uuid | string | Reference to the bank statement |
Transaction Statements
Bank transaction statements provide additional context and documentation for transactions:
| Attribute | Type | Description |
|---|---|---|
| id | integer | The unique identifier of the statement |
| created_at | datetime | When the statement was created |
| created_by_id | integer | The ID of the user who created the statement |
| client_account_id | integer | The ID of the client account |
| bank_transaction_id | integer | The ID of the associated bank transaction |
| category | string | The category of the statement |
| business_partner_id | integer | The ID of the associated business partner |
| voucher_id | integer | The ID of the associated voucher |
| comment | string | Additional comments about the statement |
Example Response
{
"id": 1,
"client_account_id": 1,
"payee_name": "John Doe",
"payee_bank_account_id": null,
"payor_name": "ACME Corp",
"payor_bank_account_id": null,
"message_id": "MSG123",
"payment_id": "PAY456",
"instruction_id": "INS789",
"end_to_end_id": "E2E123",
"booking_date": "2023-05-10",
"value_date": "2023-05-11",
"memo": "Invoice payment",
"instructed_amount": "1000.00",
"instructed_currency_code": "USD",
"instructed_exchange_rate": "1.0000",
"amount": "1000.00",
"currency_code": "USD",
"exchange_rate": "1.0000",
"bank_reference": "REF123",
"external_reconciled_amount": "0.00",
"details": [
{
"id": 1,
"transaction_type": "CREDIT",
"account_name": "ACME Corp",
"account_number": "12345678",
"account_currency_code": "USD",
"archive_reference": "AR123",
"structured_reference": "INV123",
"bank_information": "Payment for services",
"amount": "1000.00",
"currency_code": "USD",
"description": "Invoice payment INV123",
"booking_date": "2023-05-10",
"value_date": "2023-05-11",
"invoice_number": "INV123",
"sender_name": "ACME Corp",
"sender_account": "87654321",
"receiver_name": "John Doe",
"receiver_account": "12345678",
"transaction_uuid": "UUID123",
"statement_uuid": "STMT123"
}
],
"statements": [
{
"id": 1,
"created_at": "2023-05-10T12:00:00Z",
"created_by_id": 1,
"client_account_id": 1,
"bank_transaction_id": 1,
"category": "INVOICE",
"business_partner_id": 2,
"voucher_id": 3,
"comment": "Invoice payment received"
}
]
}
Get Single Transaction
GET /api/v2/bank-transactions/{id}
Retrieves a single bank transaction by ID. The details relation is included by default.
Path Parameters
| Parameter | Type | Description |
|---|---|---|
| id | integer | Bank transaction ID |
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| with | string | No | Comma-separated relations to include (see Relationships). details is already included by default |
Response
Returns the bank transaction object — same shape as the entries in the list response (see the Example Response above).
Error Responses
| Status | Description |
|---|---|
| 403 | No access to the bank transaction’s client account |
Create Transaction
POST /api/v2/bank-transactions
Creates a new bank transaction. Use this when importing transactions that are not produced by an automatic bank integration. The created transaction is not automatically attached to a bank statement — to bundle transactions with opening/closing balances, use POST /bank-statements instead and pass the transactions in the transactions array.
Amount Sign Convention
amount is signed and selects which of the two bank-account fields is required:
- Positive amount (incoming credit — money received):
payee_bank_account_idis required and must identify our bank account - Negative amount (outgoing debit — money paid out):
payor_bank_account_idis required and must identify our bank account
The counter-party name goes in the other *_name field — payor_name for incoming credits, payee_name for outgoing debits.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| client_account_id | integer | Yes | The client account ID. Must be one of the user’s eligible client accounts |
| amount | decimal | Yes | Signed transaction amount in currency_code. Positive = incoming, negative = outgoing |
| currency_code | string | Yes | ISO 4217 currency code of amount (e.g. NOK) |
| payee_bank_account_id | integer | Conditional | Required when amount > 0. Must be a Snapbooks bank account on the same client account |
| payor_bank_account_id | integer | Conditional | Required when amount < 0. Must be a Snapbooks bank account on the same client account |
| payee_name | string | No | Free-text payee name (counter-party for outgoing debits) |
| payor_name | string | No | Free-text payor name (counter-party for incoming credits) |
| booking_date | date | No | Date the transaction was booked by the bank |
| value_date | date | No | Value date of the transaction |
| memo | string | No | Transaction memo or description |
| instructed_amount | decimal | No | Originally instructed amount (before any FX conversion) |
| instructed_currency_code | string | No | Currency code of instructed_amount |
| instructed_exchange_rate | decimal | No | Exchange rate applied to the instructed amount |
| exchange_rate | decimal | No | Exchange rate from currency_code to the client’s accounting currency |
| message_id | string | No | Bank-provided message ID |
| payment_id | string | No | Bank-provided payment ID |
| instruction_id | string | No | Bank-provided instruction ID |
| end_to_end_id | string | No | End-to-end ID for the payment |
| bank_reference | string | No | Bank’s reference string for the transaction |
The id and external_reconciled_amount fields are read-only and ignored on input.
Example Request
{
"client_account_id": 7,
"payee_bank_account_id": 24,
"payor_name": "ACME Corp",
"booking_date": "2024-03-15",
"value_date": "2024-03-15",
"amount": "2500.00",
"currency_code": "NOK",
"memo": "Invoice 1042"
}
Response (201 Created)
Returns the created bank transaction object. The details relation is not included by default on the create response — fetch via GET /bank-transactions/{id} if you need it.
Error Responses
| Status | Description |
|---|---|
| 400 | client_account_id, amount, or currency_code is missing, or the required payee_bank_account_id / payor_bank_account_id is missing for the amount sign |
| 403 | No access to the specified client account |
Transaction Statement Endpoints
Bank transaction statements provide additional context and user-provided metadata for a bank transaction — such as the expense category, business partner, or a link to a voucher. Creating a statement automatically closes any open statement or upload questions for the bank transaction.
List Statements
GET /api/v2/bank-transactions/{id}/statements
Returns all statements for a specific bank transaction.
Path Parameters
| Parameter | Type | Description |
|---|---|---|
| id | integer | Bank transaction ID |
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| with | string | No | Include related resources (supported: bank_transaction, business_partner, voucher) |
Response
[
{
"id": 1,
"created_at": "2024-03-15T10:30:00Z",
"created_by_id": 7,
"client_account_id": 7,
"bank_transaction_id": 123,
"category": "INVOICE",
"business_partner_id": 56,
"voucher_id": 789,
"comment": "Invoice payment received"
}
]
Error Responses
| Status | Description |
|---|---|
| 403 | No access to the bank transaction’s client account |
Create Statement
POST /api/v2/bank-transactions/{id}/statements
Creates a new statement for a bank transaction. The client_account_id and bank_transaction_id are set automatically from the parent transaction. Creating a statement closes any open questions of type ATTACH_FILE or STATEMENT for the bank transaction.
Path Parameters
| Parameter | Type | Description |
|---|---|---|
| id | integer | Bank transaction ID |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| category | string | No | Statement category |
| business_partner_id | integer | No | Associated business partner ID |
| voucher_id | integer | No | Associated voucher/file ID |
| comment | string | No | Additional comment |
Example Request
{
"category": "INVOICE",
"business_partner_id": 56,
"voucher_id": 789,
"comment": "Invoice payment received"
}
Response (201 Created)
Returns the created statement object.
Error Responses
| Status | Description |
|---|---|
| 400 | No request body provided |
| 403 | No access to the bank transaction’s client account |
Relationships
The details relationship is included by default in the response. Other relationships can be included using the with query parameter (comma-separated values).
Available relationships:
| Relationship | Type | Description |
|---|---|---|
| details | [BankTransactionDetail] | Detailed information about the transaction (included by default) |
| receivable_payments | [ReceivablePayment] | Associated receivable payments |
| questions | [AccountingQuestion] | Questions related to the transaction |
| statements | [BankTransactionStatement] | Associated bank transaction statements |
| reconciled_documents | [Document] | Documents reconciled with this transaction |
Notes
- The client_account_id must be one of the eligible client accounts for the authenticated user
- All amounts are returned as string representations of decimal numbers
- Dates are returned in ISO 8601 format (YYYY-MM-DD)
- When creating a transaction or statement, the created_by_id is automatically set to the authenticated user’s ID