Skip to main content
Glama

Deactivate or reactivate a chart account

set_chart_account_active
Idempotent

Deactivates (active=false) or reactivates (active=true) a chart account. Deactivating hides it from new categorisation but never deletes it — existing transactions keep their account and still appear in the P&L. REFUSED for system accounts (required by the pipeline) and for any account that counterparty rules point at (repoint or remove those rules first — the error says how many). Audit-trailed. actor_id is optional — it defaults to the organisation entity, and if provided must belong to this org.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
activeYestrue to reactivate (un-hide), false to deactivate (hide from new selection).
org_idNoOptional. Defaults to the organisation the authenticated API key is bound to, so you normally omit it and never need to ask the user for their organisation UUID. If provided, it must match the key’s org or the request is rejected.0e91146d-511c-469f-bdee-5c867b26ae0d
reasonYesWhy the change. Stored verbatim in the audit trail.
actor_idNoOptional. Defaults to the organisation entity (correct for an org-scoped key). If provided, it must be an entity belonging to this organisation — arbitrary UUIDs are rejected, so the audit trail cannot be attributed to someone else.
account_idYesThe account id from list_chart_accounts.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
accountYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate a non-read-only, non-destructive, idempotent operation, and the description adds substantial behavioral detail beyond that: deactivation never deletes, existing transactions remain visible in the P&L, refusal conditions, audit-trailing, and actor_id attribution constraints. No contradiction with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three dense sentences carry all the essential information with no filler. The description is front-loaded with the primary action and effect, then covers constraints and parameter edge cases. Every clause earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the output schema exists, the description does not need to explain return values. It covers the tool's core behavior, non-destructive nature, refusal cases, audit trail, and the actor_id safeguard. Together with the schema and annotations, an agent has everything needed to decide when and how to invoke it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3. The description adds meaning beyond the schema by explaining the real-world effect of active=false, the refusal conditions tied to account_id, and the audit-trail implication of the reason parameter. This extra context pushes it above baseline.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb ('deactivates'/'reactivates') applied to a specific resource ('a chart account'), and immediately clarifies the operational meaning of deactivation. This distinguishes it clearly from sibling tools like rename_chart_account or add_chart_account.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives clear context on when this tool applies: to hide or unhide a chart account from new categorisation. It also states explicit refusal conditions for system accounts and accounts referenced by counterparty rules. However, it does not explicitly name alternative siblings or say 'use X instead when...', so it falls just short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources