Accounts and tax types
List tax types with group names
/a/Accounts_getCategories
List all tenant tax types with their rates, group IDs, and optional group names.
When to use this endpoint
Use Accounts_getCategories for finance setup, integration mapping, and invoice/quote editors that need the complete tax-type catalogue.
Authentication and permissions
The request must authenticate with signed API-key fields or a logged-in CRM session. The handler calls the normal login guard but performs no additional Finance-page, client-admin, role, create, edit, or delete permission check.
All reads and writes use the authenticated tenant. CRM1 and CRM2 decide whether to show finance controls, but these handlers do not repeat those client-side checks.
Parameters
This endpoint has no operation-specific parameters.
Example request
$categories = FM_api('Accounts_getCategories');
Example response
[
{"id":"271006","name":"Standard VAT","tax_rate":"20","category_group_id":"151003","groupname":"Income"}
]
Errors and unusual responses
| Response | Condition |
|---|---|
{"error":"not logged in"} | No authenticated tenant context is available. Invalid signed credentials can be rejected by the dispatcher before the handler runs. |
[] | No categories exist. |
Legacy application errors may be returned with HTTP 200. Check the decoded response for error, not only the HTTP status.
Behaviour and edge cases
- There is no filtering or pagination. Rows are ordered by numeric
category_group_id; order within one group is unspecified. - The group uses a left join, so a category with group ID
0or a missing group remains present withgroupname:null. - All stored category rows are included because this table has no deleted flag.
See it in Fieldmotion
CRM1
CRM1 uses this list in Settings → Finance, DataSync mappings, Job Invoices, stock, Schedule of Rates, and other tax selectors.
CRM2
CRM2 uses it in Settings → Finance/DataSync, invoice and quote rows, Credit Notes, Schedule of Rates, history/export helpers, and Microsoft Business Central mappings.
Related endpoints
AccountCategories_listis a smaller fixed-shape category list without group data.AccountCategory_getRequestedDetailsselects mapped fields and exact filters.