SuperBooksDevelopers
API reference

Categories

Categories tools exposed over the SuperBooks MCP API.

The categories domain exposes 4 tools, 1 of which is destructive.

Destructive tools are hidden from tools/list unless the credential holds apis.all and the team has enabled destructive AI tools. See Authentication.

Tools

categories_create

Scope tier: write

Create a new transaction category for the current team. Name is required; all other fields are optional. The slug is derived from the name (lowercase, non-alphanumeric -> underscore, capped at 64 chars). Slugs must be unique per team — creating a category with a name that slugifies to an existing slug will throw a unique-constraint error. To nest under a parent, pass parent_id (the UUID id of an existing category). Returns the created row.

ParameterTypeRequiredDescription
namestringyesHuman-readable category name (e.g., 'Office Supplies'). The slug is auto-generated from this — pick something stable.
colorstring (nullable)noOptional hex color for UI display (e.g., '#FF0000'). Pass null or omit if not needed.
descriptionstring (nullable)noOptional free-text description of what this category covers (helps the LLM auto-classify transactions).
parent_idstring (uuid, nullable)noOptional UUID id of a parent category to nest under. Pass null or omit for a top-level category. Use categories_list to find existing category ids.
tax_ratenumber (nullable)noOptional tax rate as a percentage (e.g., 7.5 for 7.5%). Stored with 2-decimal precision.
tax_typestring (nullable)noOptional tax type code (e.g., 'GST', 'VAT', 'sales_tax').
tax_reporting_codestring (nullable)noOptional reporting/jurisdiction code for the tax authority's tax line.
excludedbooleannoIf true, transactions in this category are excluded from financial reports (e.g., transfers between own accounts). Defaults to false.

categories_delete

Scope tier: destructive · Destructive — requires the two-gate check

Permanently delete a transaction category. DESTRUCTIVE. REFUSES if the category is a system category (system: true). REFUSES if any transactions still reference the category (by slug) — re-categorize or delete those transactions first, then retry. Side-effects on success: any saved enrichment rules that reference this category are also deleted. Child categories are NOT auto-deleted and will keep pointing at the removed parent — re-nest or delete the children first if that matters. Returns deleted: false if the category was not found OR was refused; an error is thrown for refusals so the caller can distinguish. Confirm with the user before calling.

ParameterTypeRequiredDescription
idstring (uuid)yesCategory id (UUID) to delete. This action is permanent.

categories_list

Scope tier: read

List all transaction categories for the current team. Returns a FLAT array (not hierarchical) — each row includes parent_id so the caller can reconstruct the parent/child tree if needed. System categories (system: true) are included; they cannot be updated or deleted. Ordered by system DESC, name ASC. No pagination — the full category catalog is typically small.

No parameters.

categories_update

Scope tier: write

Update one transaction category. Only the fields you pass are modified; omit a field to leave it untouched. REFUSES to update a system category (system: true). REFUSES to change parent_id on a category that has children — re-nest the children first. The slug is NOT updatable (it is part of the composite primary key); to rename, create a new category and migrate transactions. Returns updated: true on success.

ParameterTypeRequiredDescription
idstring (uuid)yesCategory id (UUID) to update. Use categories_list to find it.
namestringnoNew human-readable name. The slug does NOT change when name changes.
colorstring (nullable)noHex color for UI display. Pass null to clear.
descriptionstring (nullable)noFree-text description. Pass null to clear.
parent_idstring (uuid, nullable)noParent category UUID id. Pass null to make top-level. Refused if this category already has children.
tax_ratenumber (nullable)noTax rate percentage (e.g., 7.5 for 7.5%). Pass null to clear.
tax_typestring (nullable)noTax type code (e.g., 'GST', 'VAT'). Pass null to clear.
tax_reporting_codestring (nullable)noReporting/jurisdiction code. Pass null to clear.
excludedboolean (nullable)noIf true, this category is excluded from financial reports. Pass null to revert to default (false).

On this page