Accounting API
Celerp accounting REST API for the chart of accounts, journal entries, general ledger, bank reconciliation, financial statements, transfers, and fiscal period controls.
Generated from the Celerp 2.8.0 OpenAPI schema, 2 November 2026.
POST /accounting/accounts
Create Chart of Accounts Account
Create a chart of accounts account from the supplied request data.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
code | string | yes | Stable code identifying the record. |
name | string | yes | Human-readable chart of accounts name. |
account_type | string | yes | Accounting classification for the account, such as asset, liability, equity, revenue, or expense. |
parent_code | string, optional | -- | Code of the parent account when the chart of accounts uses a hierarchy. |
cash_flow_category | string, optional | -- | Cash flow statement category used to classify movements for reporting. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the created chart of accounts account or creation result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/accounts \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/accounts/import/batch
Import Chart of Accounts
Add accounts from a chart of accounts file. Existing codes are kept exactly as they are and listed as skipped, so running the same file again adds nothing. The whole chart is sent in one request so parents resolve across the file.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
records | array of object | yes | Chart of accounts rows to import. |
upsert | boolean | -- | Accepted so a client can state it. The import only adds accounts and never updates. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns how many accounts were created and skipped, the row errors, and the skipped codes. | ChartImportResult |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/accounts/import/batch \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/accounts/import/preview
Preview Chart of Accounts Import
Show what importing these chart of accounts rows would do now. Nothing is written. Each row is checked on its own, so one malformed row is reported instead of refusing the whole file. The import only adds accounts and never updates existing ones.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
records | array of object | yes | Chart of accounts rows to import. |
upsert | boolean | -- | Accepted so a client can state it. The import only adds accounts and never updates. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns how many accounts would be created and skipped, the row errors, and the skipped codes. | ChartImportResult |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/accounts/import/preview \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'PATCH /accounting/accounts/{code}
Update Chart of Accounts Account
Update chart of accounts account with the supplied fields.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
code | path | yes | string | Chart of accounts code identifying the account. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
name | string, optional | -- | Updated human-readable chart of accounts name. |
account_type | string, optional | -- | Accounting classification for the account, such as asset, liability, equity, revenue, or expense. |
parent_code | string, optional | -- | Code of the parent account when the chart of accounts uses a hierarchy. |
is_active | boolean, optional | -- | Whether the record or user is active. |
cash_flow_category | string, optional | -- | Cash flow statement category used to classify movements for reporting. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated chart of accounts account or update result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X PATCH http://localhost:8000/accounting/accounts/:code \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/balance-sheet
Get Balance Sheet
Return the company's balance sheet as of the requested date using posted accounting entries.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
as_of | query | -- | string, optional | Cutoff date for the balance sheet; later postings are excluded. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested balance sheet result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/balance-sheet \
-H "Authorization: Bearer $TOKEN"GET /accounting/bank-accounts
List Bank and Card Accounts
Return bank and card accounts matching the documented filters and pagination options.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
include_inactive | query | -- | boolean | Whether to include inactive records in the result. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested bank and card accounts. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/bank-accounts \
-H "Authorization: Bearer $TOKEN"POST /accounting/bank-accounts
Create Bank or Card Account
Create a bank or card account from the supplied request data.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
bank_name | string | yes | Name of the bank, card issuer, or financial institution. |
account_number | string | yes | Bank or card account number or display identifier. |
bank_type | string | yes | Type of financial account, such as bank or card when supported. |
currency | string | yes | Currency code used for amounts in this record. |
opening_balance | number | -- | Opening balance recorded for the bank or card account. |
rate | number, optional | -- | Rate |
account_code | string, optional | -- | Chart of accounts code associated with the transaction or bank account. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the created bank or card account or creation result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/bank-accounts \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/bank-accounts/{bank_id}
Get Bank or Card Account
Return bank or card account.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
bank_id | path | yes | string | Identifier of the bank or card account. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested bank or card account result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/bank-accounts/:bank_id \
-H "Authorization: Bearer $TOKEN"PATCH /accounting/bank-accounts/{bank_id}
Update Bank or Card Account
Update bank or card account with the supplied fields.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
bank_id | path | yes | string | Identifier of the bank or card account. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
bank_name | string, optional | -- | Name of the bank, card issuer, or financial institution. |
account_number | string, optional | -- | Bank or card account number or display identifier. |
bank_type | string, optional | -- | Type of financial account, such as bank or card when supported. |
currency | string, optional | -- | Currency code used for amounts in this record. |
is_active | boolean, optional | -- | Whether the record or user is active. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated bank or card account or update result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X PATCH http://localhost:8000/accounting/bank-accounts/:bank_id \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/bank-accounts/{bank_id}/reconciliations
List Bank Reconciliations
Every reconciliation of one bank account, newest statement date first.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
bank_id | path | yes | string | Identifier of the bank or card account. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/bank-accounts/:bank_id/reconciliations \
-H "Authorization: Bearer $TOKEN"GET /accounting/cash-flow
Get Cash Flow Statement
Return the company's cash flow statement for the requested period, including direct and indirect cash-flow views derived from posted accounting entries.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested cash flow statement result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/cash-flow \
-H "Authorization: Bearer $TOKEN"GET /accounting/chart
Get Chart of Accounts
Return the full chart of accounts ordered by account code.
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested chart of accounts result. | object |
Example
curl -X GET http://localhost:8000/accounting/chart \
-H "Authorization: Bearer $TOKEN"POST /accounting/chart/seed
Seed Default Chart of Accounts
Add any missing accounts from Celerp's default chart of accounts without replacing existing accounts.
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the account codes that were added and the ones that already existed. | object |
Example
curl -X POST http://localhost:8000/accounting/chart/seed \
-H "Authorization: Bearer $TOKEN"POST /accounting/close-year
Close Fiscal Year
Close the selected fiscal year by clearing revenue and expense balances and transferring net income to retained earnings.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
fiscal_year_end | string | yes | Date that closes the fiscal year being processed. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the closing journal entry ID, year-end date, net income, number of entries posted and the new lock date. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/close-year \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/extended-journal
Get Item-Expanded Journal
Return the general journal with item-level detail added where journal postings can be reliably tied to document lines.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
q | query | -- | string, optional | Search text used to filter matching records. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested item-expanded journal result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/extended-journal \
-H "Authorization: Bearer $TOKEN"GET /accounting/general-ledger
Get General Ledger
Return opening balance, period debits and credits, and closing balance for each account. Optionally narrow the report to a single contact and include ledger lines.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
include_lines | query | -- | boolean | Whether to include detailed ledger lines in the response. |
contact_id | query | -- | string, optional | Identifier of the customer, supplier, or other CRM contact. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested general ledger result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/general-ledger \
-H "Authorization: Bearer $TOKEN"POST /accounting/import/batch
Batch Import Accounting Records
Import multiple accounting records in one request.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
records | array of AccImportRecord | yes | List of records included in the batch request. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns how many records were created, skipped or failed, with the reason for each failure. | celerp_accounting__routes__BatchImportResult |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/import/batch \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/journal
Get General Journal
Return posted and voided journal entries with their lines, source-document references, and foreign-currency information. Date and search filters narrow the returned journal and its totals.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
q | query | -- | string, optional | Search text used to filter matching records. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested general journal result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/journal \
-H "Authorization: Bearer $TOKEN"POST /accounting/journal-entries
Create Manual Journal Entry
Create and post a balanced manual journal entry after validating the referenced accounts and accounting period.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
ts | string | yes | Date and time assigned to the journal entry. |
memo | string | -- | Memo or narrative recorded with the accounting entry. |
entries | array of ManualJELine | yes | Journal entry lines containing the accounts and debit or credit amounts. |
idempotency_token | string | yes | Client-supplied idempotency token identifying the manual journal operation. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the created manual journal entry or creation result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/journal-entries \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/journal-entries/bulk-void
Bulk Void Manual Journal Entries
Void multiple eligible manual journal entries.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
je_ids | array of string | yes | Identifiers of the journal entries to process. |
reason | string, optional | -- | Human-readable reason for the lifecycle change, cancellation, void, or other operation. |
reversal_date | string, optional | -- | Reversal Date |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the outcome for each selected entry and counts of voided and refused entries. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/journal-entries/bulk-void \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/journal-entries/from-accountant
Journals From Accountant
The journal entries the accountant posted in these books, newest first.
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
Example
curl -X GET http://localhost:8000/accounting/journal-entries/from-accountant \
-H "Authorization: Bearer $TOKEN"GET /accounting/journal-entries/{entity_id}/prefill
Prefill Journal
A new journal entry's fields copied from this one, dated on the first open day.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
entity_id | path | yes | string | Identifier of the journal entry from which to prefill a new entry. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/journal-entries/:entity_id/prefill \
-H "Authorization: Bearer $TOKEN"POST /accounting/journal-entries/{entity_id}/reverse
Reverse From Accountant
Reverse a journal entry the accountant posted, or undo that reversal.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
entity_id | path | yes | string | Identifier of the journal entry to reverse or whose reversal is to be undone. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/journal-entries/:entity_id/reverse \
-H "Authorization: Bearer $TOKEN"POST /accounting/journal-entries/{entity_id}/void
Void Manual Journal Entry
Void an eligible manual journal entry while retaining it in the accounting audit trail.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
entity_id | path | yes | string | Identifier of the requested Celerp record. |
Request body
ManualJEVoidPayload, optional
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the voided entry and the ID of its reversing entry. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/journal-entries/:entity_id/void \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/ledger/{account_code}
Get Account Ledger
Return the account ledger with opening balance, posted lines, running balance, closing balance, and source-document references. Optionally filter the ledger to one customer or supplier.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
account_code | path | yes | string | Chart of accounts code identifying the ledger account. |
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
contact_id | query | -- | string, optional | Identifier of the customer, supplier, or other CRM contact. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested account ledger result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/ledger/:account_code \
-H "Authorization: Bearer $TOKEN"GET /accounting/older-stock
List Older Stock
Return older stock placed automatically: a page each of its lots, placements, moves and corrections, a summary per inventory account, and the accounts the lots can be moved to. Each list pages from its own offset, with its total returned alongside.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
account | query | -- | string, optional | Code of the inventory account to show older stock for. Omit it to show every account. |
q | query | -- | string, optional | Text to find in the SKU or name of a lot. |
lots_offset | query | -- | integer | Number of lots to skip before the page starts. |
placements_offset | query | -- | integer | Number of placements to skip before the page starts. |
moves_offset | query | -- | integer | Number of moves to skip before the page starts. |
corrections_offset | query | -- | integer | Number of corrections to skip before the page starts. |
limit | query | -- | integer | Number of rows in each page, from 1 to 500. The default is 50. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the lots, placements, moves and corrections with their totals, the account summaries, and the move targets. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/older-stock \
-H "Authorization: Bearer $TOKEN"POST /accounting/older-stock/corrections
Correct Older Stock Placements
Correct how placements treated their difference. `recognize` books what a placement left unresolved against retained earnings. `unresolve` takes what a placement recognized back off the books and leaves it unresolved. All the placements are corrected or none. A placement with nothing to move is skipped, so a correction sent twice books once.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
placements | array of string | -- | Identifiers of the placements to correct. |
kind | string | -- | `recognize` to book the difference against retained earnings, or `unresolve` to leave it unresolved. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the refreshed older stock view and the number of placements corrected. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/older-stock/corrections \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/older-stock/move
Move Older Stock
Move the selected older lots onto another inventory account, with their value, in one entry dated today. `key` identifies the move, so a request sent twice moves once and returns the first result. A lot already on the account is skipped. Nothing is moved when any lot cannot move, for example because an unshipped invoice holds it or the period is locked.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
item_ids | array of string | -- | Identifiers of the older lots to move. |
code | string | -- | Code of the inventory account to move the lots to. |
key | string, optional | -- | Client-supplied key identifying this move so the same request can be retried safely. Required, at most 64 characters. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the refreshed older stock view and the `result`: the lots moved, their value, the account code and the move ID. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/older-stock/move \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/older-stock/move-all
Move All Matching Older Stock
Move every older lot that matches the `account` and `q` filters onto another inventory account as one move, across all pages. `selection` is the fingerprint of the lots the user confirmed. The request is refused when the matching lots have changed since.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
account | string, optional | -- | Code of the inventory account to filter lots by. |
q | string, optional | -- | Text to find in the SKU or name of a lot. |
selection | string | -- | Fingerprint of the matching lots the user confirmed, from the older stock view. |
code | string | -- | Code of the inventory account to move the lots to. |
key | string, optional | -- | Client-supplied key identifying this move so the same request can be retried safely. Required, at most 64 characters. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the refreshed older stock view and the `result` of the move. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/older-stock/move-all \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/older-stock/moves/{move_id}/undo
Undo Older Stock Move
Put the lots of one move back on the accounts they came from, with their value, in one entry dated today. A move can be undone once, and only while every lot is still where the move put it, no unshipped invoice holds it, and the period is open.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
move_id | path | yes | string | Identifier of the older stock move to undo. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the refreshed older stock view. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/older-stock/moves/:move_id/undo \
-H "Authorization: Bearer $TOKEN"POST /accounting/older-stock/retry
Retry Older Stock Placement
Try again to place the older stock that is still waiting for an account, after a failure.
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the refreshed older stock view and the number of lots placed. | object |
Example
curl -X POST http://localhost:8000/accounting/older-stock/retry \
-H "Authorization: Bearer $TOKEN"GET /accounting/opening-tie-out
Get Opening Balance Tie-Out
Compare the documents imported as already in the opening balances with what the ledger holds on the opening balance date. It is read only: a difference is shown, never corrected. With no opening balance date set there is nothing to compare, so `checks` is empty.
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the opening balance date, the base currency, and each check with its ledger amount, expected amount, difference and documents. | object |
Example
curl -X GET http://localhost:8000/accounting/opening-tie-out \
-H "Authorization: Bearer $TOKEN"POST /accounting/peer/added/{item_id}
Settle Peer Added
Keep an account sync added, archive it, or remove it while it is unused; each closes its notice. Remove also drops the link, so a later record adds it again.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
item_id | path | yes | string | Identifier of the added-account synchronization item to settle. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
action | string | yes | Action |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/peer/added/:item_id \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/peer/holds
Peer Holds
Records a connected company sent that wait for one of their accounts to be fixed, and the accounts sync added here, newest first; each added account says whether it can still be removed, or why it can only be archived.
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
Example
curl -X GET http://localhost:8000/accounting/peer/holds \
-H "Authorization: Bearer $TOKEN"POST /accounting/peer/holds/{item_id}/fix
Fix Peer Hold
Use another account for a held record's account, add it under a free code, or unarchive the account it posts to; the record posts on the next sync, and until then it shows as fixed (a sync that holds it again replaces its fix).
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
item_id | path | yes | string | Identifier of the held accounting synchronization item to resolve. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
action | string | yes | Action |
account | string, optional | -- | Account |
code | string, optional | -- | Code |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/peer/holds/:item_id/fix \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/peer/journals
Peer Journal Feed
This company's own journal entries, for the client its key belongs to; a connected company's key only.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
after | query | -- | string | Optional cursor identifying the point after which journal entries should be returned. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/peer/journals \
-H "Authorization: Bearer $TOKEN"POST /accounting/peer/journals
Peer Journal Receive
A client's journal entries and its answers to this company's; a connected company's key only.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
records | array of PeerJournalRecord | yes | Records |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/peer/journals \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/peer/lock
Peer Lock
This company's lock date, for the client its key belongs to.
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
Example
curl -X GET http://localhost:8000/accounting/peer/lock \
-H "Authorization: Bearer $TOKEN"GET /accounting/peer/review
Peer Review
Each client whose accounts wait for this company's review, with the accounts.
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
Example
curl -X GET http://localhost:8000/accounting/peer/review \
-H "Authorization: Bearer $TOKEN"POST /accounting/peer/review
Answer Peer Review
Link or add a client's reviewed accounts; ``finish`` ends the review.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
source_company_id | string | yes | Source Company Id |
finish | boolean | -- | Finish |
answers | array of PeerReviewAnswer | -- | Answers |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/peer/review \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/period-lock
Get Accounting Period Lock
Return the current accounting period lock date.
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested accounting period lock result. | object |
Example
curl -X GET http://localhost:8000/accounting/period-lock \
-H "Authorization: Bearer $TOKEN"POST /accounting/period-lock
Set Accounting Period Lock
Set the accounting period lock date used to prevent normal posting changes in closed periods.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
lock_date | string, optional | yes | Latest accounting date that should be locked against normal posting changes. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated accounting period lock or update result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/period-lock \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/pnl
Get Profit and Loss Statement
Return the profit and loss statement for the requested period, including revenue, cost of goods sold, expenses, and resulting profit.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested profit and loss statement result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/pnl \
-H "Authorization: Bearer $TOKEN"GET /accounting/posting-accounts
List Posting Accounts
Return each posting role's account and whether it can take new postings, with the older stock candidates for each inventory account.
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the posting roles and the older stock candidates. | object |
Example
curl -X GET http://localhost:8000/accounting/posting-accounts \
-H "Authorization: Bearer $TOKEN"PUT /accounting/posting-accounts/{role}
Set Posting Account
Point a role at another account for new postings. Balances already posted stay where they are; the earlier account stays with the role for them. Fixing Purchased inventory or Retained earnings places older stock that waited on it at once, and the notice of missing posting accounts follows what is still missing.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
role | path | yes | string | Accounting role the account is posted for. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
code | string | yes | Code |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X PUT http://localhost:8000/accounting/posting-accounts/:role \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/reconciliation/start
Start Bank Reconciliation
Start a bank or card reconciliation for the selected account, statement date, and ending statement balance.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
bank_account_id | string | yes | Identifier of the related bank account record. |
statement_date | string | yes | Statement ending date for the bank reconciliation. |
statement_balance | number | yes | Ending balance shown on the bank or card statement. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the new reconciliation session. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/start \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/reconciliation/{session_id}
Get Bank Reconciliation
Return the selected bank reconciliation session and its current reconciliation state.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested bank reconciliation result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/reconciliation/:session_id \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/auto-match
Auto-Match Bank Statement Lines
Compare unmatched statement lines with eligible book entries.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the result of the auto-match bank statement lines operation. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/auto-match \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/bulk-confirm
Confirm Suggested Reconciliation Matches
Confirm all currently suggested reconciliation matches.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Request body
BulkConfirmPayload, optional
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the number of matches confirmed. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/bulk-confirm \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/reconciliation/{session_id}/complete
Complete Bank Reconciliation
Complete the reconciliation after the remaining difference reaches zero.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the completed reconciliation session. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/complete \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/import-csv
Import Bank Statement CSV
Upload a bank statement CSV and add its lines to the reconciliation. Lines already imported are skipped.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns how many statement lines were added and how many were skipped as duplicates. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/import-csv \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/import-file
Import Bank Statement File
Import a supported CSV or XLSX bank statement file into the reconciliation using the supplied file and column mapping.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | Identifier of an uploaded file. |
column_map | object, optional | -- | Mapping from source-file columns to the fields required for statement import. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns how many statement lines were added and how many were skipped as duplicates. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/import-file \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'PATCH /accounting/reconciliation/{session_id}/lines/{line_id}
Update Bank Statement Line
Update the selected bank statement line's reconciliation status, such as marking a line that requires no book entry.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
line_id | path | yes | string | Identifier of the statement, document, or list line within the parent record. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
status | string, optional | -- | New reconciliation status for the bank statement line. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated bank statement line or update result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X PATCH http://localhost:8000/accounting/reconciliation/:session_id/lines/:line_id \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/reconciliation/{session_id}/lines/{line_id}/attach
Attach File to Bank Statement Line
Attach a supporting file to the selected bank statement line.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
line_id | path | yes | string | Identifier of the statement, document, or list line within the parent record. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the new attachment ID and file name. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/lines/:line_id/attach \
-H "Authorization: Bearer $TOKEN"DELETE /accounting/reconciliation/{session_id}/lines/{line_id}/attach/{att_id}
Remove Bank Statement Line Attachment
Remove the selected attachment from the bank statement line.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
line_id | path | yes | string | Identifier of the statement, document, or list line within the parent record. |
att_id | path | yes | string | Identifier of the attachment. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns `removed: true` once the attachment is detached. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X DELETE http://localhost:8000/accounting/reconciliation/:session_id/lines/:line_id/attach/:att_id \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/lines/{line_id}/create
Create Journal Entry from Statement Line
Create a journal entry from a bank statement line and match the new entry to that line.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
line_id | path | yes | string | Identifier of the statement, document, or list line within the parent record. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
account_code | string | yes | Chart of accounts code associated with the transaction or bank account. |
memo | string | -- | Memo or narrative recorded with the accounting entry. |
amount | number, optional | -- | Monetary amount for the transaction or operation. |
date | string, optional | -- | Business or accounting date for the operation. |
contact | string, optional | -- | Contact information or reference associated with the transaction. |
rate | number, optional | -- | Rate |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the created journal entry from statement line or creation result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/lines/:line_id/create \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/reconciliation/{session_id}/lines/{line_id}/match
Match Statement Line to Journal Entry
Match the selected bank statement line to an existing journal entry.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
line_id | path | yes | string | Identifier of the statement, document, or list line within the parent record. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
je_id | string | yes | Identifier of the journal entry to match. |
confidence | string | -- | Confidence value associated with a proposed or selected reconciliation match. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated statement line. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/lines/:line_id/match \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/reconciliation/{session_id}/lines/{line_id}/split
Split Bank Statement Line
Split one bank statement line across multiple accounting entries or accounts.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
line_id | path | yes | string | Identifier of the statement, document, or list line within the parent record. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
splits | array of object | yes | List of account allocations used to split the statement line. |
rate | number, optional | -- | Rate |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated statement line. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/lines/:line_id/split \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/reconciliation/{session_id}/lines/{line_id}/unmatch
Unmatch Bank Statement Line
Remove the current book-entry match from the selected statement line.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
line_id | path | yes | string | Identifier of the statement, document, or list line within the parent record. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated statement line. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/lines/:line_id/unmatch \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/match
Match Reconciliation Entries
Match the selected journal entries within the reconciliation.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
je_ids | array of string | yes | Identifiers of the journal entries to process. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated reconciliation session. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/match \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'POST /accounting/reconciliation/{session_id}/reopen
Put a completed reconciliation back in progress
Reopen a completed reconciliation so its matches can be changed. Its matches stay as they are and no journal entry is written; the reopening is recorded as an event. Reopening one that is already in progress changes nothing.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the reconciliation session. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/reopen \
-H "Authorization: Bearer $TOKEN"GET /accounting/reconciliation/{session_id}/statement-lines
List Bank Statement Lines
Return the bank statement lines imported into the selected reconciliation session.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested bank statement lines. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/reconciliation/:session_id/statement-lines \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/unmatch
Undo matching book entries that no statement line holds
The undo of ``match_reconciliation``. An entry a statement line holds is let go of by undoing that line, so the line and the session never disagree.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
je_ids | array of string | yes | Identifiers of the journal entries to process. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Successful Response | object |
422 | Validation Error | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/unmatch \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/reconciliation/{session_id}/workbench
Get Reconciliation Workbench
Return unresolved statement lines, unreconciled book entries, and the remaining reconciliation difference.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested reconciliation workbench result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/reconciliation/:session_id/workbench \
-H "Authorization: Bearer $TOKEN"POST /accounting/reconciliation/{session_id}/write-off
Write Off Reconciliation Difference
Create a small adjustment journal entry to clear an eligible remaining reconciliation difference.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
session_id | path | yes | string | Identifier of the bank reconciliation session. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
account_code | string, optional | -- | Chart of accounts code associated with the transaction or bank account. |
memo | string | -- | Memo or narrative recorded with the accounting entry. |
rate | number, optional | -- | Rate |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the adjustment journal entry ID and the amount written off. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/reconciliation/:session_id/write-off \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/rules
List Reconciliation Rules
Return bank reconciliation rules, optionally filtered to a specific bank or card account.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
bank_account_id | query | -- | string, optional | Identifier of the bank or card account. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested reconciliation rules. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/rules \
-H "Authorization: Bearer $TOKEN"POST /accounting/rules
Create Reconciliation Rule
Create a bank reconciliation rule that matches statement data and proposes the configured accounting treatment.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
bank_account_id | string | yes | Identifier of the bank or card account this reconciliation rule applies to. |
match_field | string | -- | Bank statement field evaluated by the reconciliation rule. |
match_pattern | string | yes | Text or pattern the selected statement field must match. |
match_type | string | -- | Matching method used to evaluate the rule pattern. |
target_account_code | string | yes | Chart of accounts code assigned when the reconciliation rule matches. |
default_memo | string, optional | -- | Default journal memo to use when the reconciliation rule supplies one. |
default_tax | string, optional | -- | Default tax treatment to apply when the reconciliation rule supplies one. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the created reconciliation rule or creation result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/rules \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'PATCH /accounting/rules/{rule_id}
Update Reconciliation Rule
Update the selected bank reconciliation rule.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
rule_id | path | yes | string | Identifier of the bank reconciliation rule. |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
match_field | string, optional | -- | Bank statement field evaluated by the reconciliation rule. |
match_pattern | string, optional | -- | Text or pattern the selected statement field must match. |
match_type | string, optional | -- | Matching method used to evaluate the rule pattern. |
target_account_code | string, optional | -- | Chart of accounts code assigned when the reconciliation rule matches. |
default_memo | string, optional | -- | Default journal memo to use when the reconciliation rule supplies one. |
default_tax | string, optional | -- | Default tax treatment to apply when the reconciliation rule supplies one. |
is_active | boolean, optional | -- | Whether the record or user is active. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the updated reconciliation rule or update result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X PATCH http://localhost:8000/accounting/rules/:rule_id \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'DELETE /accounting/rules/{rule_id}
Delete Reconciliation Rule
Delete the selected bank reconciliation rule.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
rule_id | path | yes | string | Identifier of the bank reconciliation rule. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns `deleted: true` once the rule is removed. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X DELETE http://localhost:8000/accounting/rules/:rule_id \
-H "Authorization: Bearer $TOKEN"GET /accounting/soa/{contact_id}
Get Customer or Supplier Statement of Account
Return a statement of account for one customer or supplier, including opening balance, dated activity, running balance, and closing balance in the company's base currency.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
contact_id | path | yes | string | Identifier of the customer, supplier, or other CRM contact. |
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested customer or supplier statement of account result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/soa/:contact_id \
-H "Authorization: Bearer $TOKEN"POST /accounting/transfers
Create Bank Transfer
Record a transfer between two bank or card accounts.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
from_bank_id | string | yes | Identifier of the source bank or card account. |
to_bank_id | string | yes | Identifier of the destination bank or card account. |
amount | number | yes | Monetary amount for the transaction or operation. |
date | string | yes | Business or accounting date for the operation. |
description | string | -- | Human-readable description of the bank transfer. |
reference | string | -- | External or human-readable reference for the transaction. |
rate | number, optional | -- | Rate |
to_amount | number, optional | -- | To Amount |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the created bank transfer or creation result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X POST http://localhost:8000/accounting/transfers \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'GET /accounting/trial-balance
Get Trial Balance
Return one trial-balance row per account with debit and credit totals for the requested period.
Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
date_from | query | -- | string, optional | Start date for the requested reporting or search period. |
date_to | query | -- | string, optional | End date for the requested reporting or search period. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Returns the requested trial balance result. | object |
422 | The request failed validation. The response lists each invalid field and why. | HTTPValidationError |
Example
curl -X GET http://localhost:8000/accounting/trial-balance \
-H "Authorization: Bearer $TOKEN"