Appearance
Account
Introduction
Accounts form the backbone of the accounting system, implementing a Swiss KMU (Small and Medium Enterprises) chart of accounts structure. Each account has a unique number that determines its type and classification within the financial statements.
Account Types
Type | Number Range | Description |
---|---|---|
Active (Assets) | 1000-1999 | Company assets (cash, receivables, inventory, fixed assets) |
Passive (Liabilities) | 2000-2999 | Company liabilities and equity (payables, loans, capital) |
Revenue | 3000-3999 | Income and revenue streams |
Expense | 4000-8999 | Costs and expenditures |
Balance Sheet Helper | 9100-9199 | Balance sheet adjustments |
Income Statement Helper | 9200-9299 | Income statement adjustments |
Account Classification
Accounts are automatically classified into groups and subgroups based on their number ranges:
Group | Number Range | Description |
---|---|---|
Asset Groups | ||
Current Assets | 1000-1399 | Cash, securities, receivables, inventory, prepaid expenses |
Fixed Assets | 1400-1999 | Financial assets, participations, tangible and intangible assets |
Liability Groups | ||
Current Liabilities | 2000-2399 | Accounts payable, short-term debt, accrued expenses |
Long-term Liabilities | 2400-2799 | Long-term debt and obligations |
Equity | 2800-2999 | Share capital, reserves, retained earnings |
Allowed query parameters
Filters
Filter | Type | Description |
---|---|---|
search | String | Full-text search across number and name |
type | String | Filter by account type:active , passive , revenue , expense , income_statement , balance_sheet |
Sorting
number
, name
, type
Includes
bankAccount
, expensePaymentMethods
, journalEntries.account
, journalEntries.transaction.document
, journalEntriesCount
, clearedToAccount
, clearingAccounts
, vatRate
Appends
balance
- Current account balance (requires MANAGE_ACCOUNTING
permission)
Create an account
post
/account
Attribute (\* required) | Type | Description |
---|---|---|
number \* | Integer | Account number (1-9999, must be unique per organization) |
name \* | String | Account name (max 100 chars) |
type | String? | Account type (auto-detected from number if not provided) |
cleared_to_account_id | String? | ID of main account if this is a clearing account |
vat_rate_id | String? | Associated VAT Rate ID |
Account Type Auto-Detection
If no type
is provided, it will be automatically determined based on the account number:
- 1000-1999:
active
(Assets) - 2000-2999:
passive
(Liabilities) - 3000-3999:
revenue
(Revenue) - 4000-8999:
expense
(Expense) - 9100-9199:
balance_sheet
(Balance Sheet Helper) - 9200-9299:
income_statement
(Income Statement Helper)
Example response
json
// HTTP 201 Created
{
"id": "v7rnRjBn9o",
"number": "1020",
"name": "Postcheck-Konto",
"description": null,
"type": "active",
"class": "Umlaufvermögen",
"section": "Flüssige Mittel und kurzfristige Geldanlagen",
"group": "Kasse, Bank, Post",
"vat_rate_id": null,
"vat_rate": null,
"account_group": "assets.current",
"account_subgroup": "assets.current.cash",
"normal_balance_type": "debit_normal",
"is_active": true,
"is_locked": false,
"is_tax_account": false,
"created_at": "2024-01-15T10:30:00.000000Z",
"balance": 0,
"bank_account": null,
"expense_payment_methods": [],
"is_clearing_account": false,
"cleared_to_account_id": null,
"cleared_to_account": null,
"clearing_accounts": []
}
Update an account
put
/account/{id}
Attribute | Type | Description |
---|---|---|
number | Integer | Account number (1-9999, must be unique per organization) |
name | String | Account name (max 100 chars) |
type | String | Account type |
cleared_to_account_id | String? | ID of main account if this is a clearing account |
vat_rate_id | String? | Associated VAT Rate ID |
Locked Accounts
Locked accounts (system accounts) cannot be modified or deleted to maintain data integrity.
Example response
json
// HTTP 200 OK
{
// account object
}
Retrieve an account
get
/account/{id}
Example response
json
// HTTP 200 OK
{
"id": "v7rnRjBn9o",
"number": "1000",
"name": "Kasse",
"description": "Bargeld und Münzen",
"type": "active",
"class": "Umlaufvermögen",
"section": "Flüssige Mittel und kurzfristige Geldanlagen",
"group": "Kasse, Bank, Post",
"vat_rate_id": null,
"vat_rate": null,
"account_group": "assets.current",
"account_subgroup": "assets.current.cash",
"normal_balance_type": "debit_normal",
"is_active": true,
"is_locked": false,
"is_tax_account": false,
"created_at": "2024-01-15T10:30:00.000000Z",
"balance": 2750.50,
"journal_entries": [],
"journal_entries_count": 15,
"bank_account": null,
"expense_payment_methods": [],
"is_clearing_account": false,
"cleared_to_account_id": null,
"cleared_to_account": null,
"clearing_accounts": []
}
Delete an account
delete
/account/{id}
Account Deletion Restrictions
- Accounts with journal entries cannot be deleted
- Locked accounts (system accounts) cannot be deleted
- Consider deactivating accounts instead of deleting them
Example response
json
// HTTP 204 No Content
List accounts
get
/account
The list endpoint accepts the same parameters as in Retrieve an account and returns a paginated array of the same account object in the data
property.
Read more about Pagination, Filtering, Sorting and Includes on the Introduction page.