Chart of Accounts
The Chart of Accounts represents the complete hierarchy of categories used to organize and classify financial transactions in the ledger. Each category has a type (Assets, Liabilities, Equity, Income, Expenses, etc.) and a subtype that provides additional classification detail.
Listing All Categories
Use the list categories endpoint to retrieve the full Chart of Accounts.
Request Example
GET https://connect.digits.com/v1/ledger/categories
Authorization: Bearer YOUR_ACCESS_TOKEN
Content-Type: application/jsonResponse
The response returns all categories in the Chart of Accounts:
{
"categories": [
{
"categoryId": "4765df8a-0f88-4838-8ba6-353285337995",
"name": "Bank Accounts",
"type": "Assets",
"subtype": "BankAccounts",
"parentCategoryId": "b5837139-426e-4625-804b-49da75a66382",
"chartOfAccountsDisplayNumber": "1100",
"active": true
},
{
"categoryId": "7b43b647-97e4-4ecb-9117-c988e1ed001f",
"name": "Accounts Payable",
"type": "Liabilities",
"subtype": "AccountsPayable",
"chartOfAccountsDisplayNumber": "2000",
"active": true
}
]
}Category Fields
- categoryId: Unique identifier for the category in Digits
- name: Human-readable name of the category
- type: High-level category type (Assets, Liabilities, Equity, Income, Expenses, CostOfGoodsSold, OtherIncome, OtherExpenses)
- subtype: Specific classification within the type (e.g., BankAccounts, AccountsPayable, SalesRevenue)
- parentCategoryId: ID of the parent category if this is a subcategory
- chartOfAccountsDisplayNumber: Account number used for traditional chart of accounts numbering
- active: Whether the category is currently active and available for use
Getting a Single Category
To retrieve details for a specific category, use the get category endpoint.
Request Example
GET https://connect.digits.com/v1/ledger/category/4765df8a-0f88-4838-8ba6-353285337995
Authorization: Bearer YOUR_ACCESS_TOKENResponse
{
"category": {
"categoryId": "4765df8a-0f88-4838-8ba6-353285337995",
"name": "Bank Accounts",
"type": "Assets",
"subtype": "BankAccounts",
"parentCategoryId": "b5837139-426e-4625-804b-49da75a66382",
"chartOfAccountsDisplayNumber": "1100",
"active": true
}
}Category Types
The Chart of Accounts uses these primary category types:
- Assets: Resources owned by the business (Bank Accounts, Inventory, Fixed Assets, etc.)
- Liabilities: Obligations owed by the business (Accounts Payable, Credit Cards, Loans, etc.)
- Equity: Owner's stake in the business (Common Stock, Retained Earnings, etc.)
- Income: Revenue generated by the business (Sales Revenue, Subscription Revenue, etc.)
- Expenses: Operating costs of the business (Payroll, Marketing, Facilities, etc.)
- CostOfGoodsSold: Direct costs of producing goods or services
- OtherIncome: Miscellaneous income not from primary operations
- OtherExpenses: Miscellaneous expenses not from primary operations
Category Hierarchy
Categories can have parent-child relationships, creating a hierarchical structure. Use the parentCategoryId field to identify subcategories and build the complete hierarchy for reporting and display purposes.
Using Categories in Transactions
When syncing transactions, you can reference categories by their ID or use category labels for a simplified approach:
{
"entries": [
{
"amount": {
"amount": 50000,
"code": "USD"
},
"type": "Debit",
"description": "Office supplies purchase",
"category": {
"ledgerId": {
"issuer": "digits.com",
"id": "c8ce7e10-32c0-4cec-8993-12276f219039"
}
}
}
]
}Best Practices
- Filter by active: Only display active categories in user interfaces
- Respect hierarchy: When displaying categories, use the
parentCategoryIdto show the proper parent-child relationships - Use category labels: For simpler integrations, use category labels instead of tracking specific category IDs
Updated 12 days ago
