Accounts Function
BKPER_ACCOUNTS
Fetch the Chart of Accounts from your Bkper Book into Google Sheets. The function returns a complete listing of accounts with their types, group memberships, and custom properties.
Syntax
=BKPER_ACCOUNTS(bookId, cache, group)
Parameters
bookId - The universal Book Id
cache - Increase this number to clear cache and fetch fresh data
group - (Optional) Filter accounts by a specific group name or group id
Sample usage
Fetch all accounts:
=BKPER_ACCOUNTS("agtzfmJrcGVyLWhyZHITCxIGTGVkZ2VyGICAgKD_4bMLDA", 1)
Fetch only accounts in the "Expenses" group:
=BKPER_ACCOUNTS("agtzfmJrcGVyLWhyZHITCxIGTGVkZ2VyGICAgKD_4bMLDA", 1, "Expenses")
Output Columns
The function returns the following columns:
Column | Description |
Account Id | Unique identifier for each account |
Name | Account name |
Type | Account type: ASSET, LIABILITY, INCOMING, or OUTGOING |
Group columns | One column per group in your book, showing group membership |
Custom properties | Any custom properties defined on the accounts |
Filtering by Group
The optional group parameter lets you fetch only accounts belonging to a specific group. This is useful when you want to work with a subset of your Chart of Accounts.
You can pass either the group name or the group id:
=BKPER_ACCOUNTS(bookId, 1, "Operating Expenses")
If the group has child groups, accounts from all child groups are also included in the result.
Sorting
Accounts are sorted first by type (Asset, Liability, Incoming, Outgoing), then alphabetically by name within each type.
