Ledger accounts
List all ledger accounts of an administration
Returns a list of all the ledger accounts in the administration.
Pagination is not supported for this endpoint.
Example: returns a list of ledger accounts
Request
Response
Returns information about a ledger account
Example: returns a ledger account
Request
Response
Example: returns 404 when requesting unexisting ledger account
Request
Response
Creates a new ledger account
The account_type
determines the kind of ledger account, this can be any of the following values:
non_current_assets
, current_assets
, equity
, provisions
, non_current_liabilities
, current_liabilities
, revenue
, direct_costs
, expenses
, other_income_expenses
By providing the parent_id
, it is possible to create a tree of ledger accounts. Make sure the account_types
of the parent and child equal.
Parameters
Parameter | Type | Description |
---|---|---|
ledger_account[name] |
String |
Required Should be unique for this combination of administration and account type. |
ledger_account[account_type] |
String |
Required Can be |
ledger_account[account_id] |
String |
Optional field, also known as general ledger code. Should be unique. |
ledger_account[parent_id] |
Integer |
Id of the parent ledger account. Should be a valid ledger account id. |
ledger_account[allowed_document_types] |
Array |
Can be |
ledger_account[description] |
String |
|
rgs_code |
String |
Required Existing RGS version 3.5 code, e.g. ‘WMfoBelMfo’ |
Example: creates a new ledger account
Request
Response
Example: creates a new ledger account with taxonomy item by providing an existing RGS code
Request
Response
Example: returns error when provided RGS code does not belong to a taxonomy item of version 3.5
Request
Response
Example: returns an error when name is not provided
Request
Response
Example: returns an error when an empty name is provided
Request
Response
Updates a ledger account
Parameters
Parameter | Type | Description |
---|---|---|
ledger_account[name] |
String |
Should be unique for this combination of administration and account type. |
ledger_account[account_id] |
String |
Optional field, also known as general ledger code. Should be unique. |
ledger_account[account_type] |
String |
Can be |
ledger_account[parent_id] |
Integer |
Id of the parent ledger account. Should be a valid ledger account id. |
ledger_account[allowed_document_types] |
Array |
Can be |
ledger_account[description] |
String |
|
rgs_code |
String |
Existing RGS version 3.5 code, e.g. ‘WMfoBelMfo’ |