Skip to main content
Glama

schedule-iii

Undo an automatic sync

restore_replacement
Destructive

Undo one automatic sync: destroy what is currently held for that period and put back the records the sync replaced, recorded as authorised by the member you name. THIS DESTROYS DATA. Everything currently held in that period goes — including anything uploaded or synced since — and is replaced by what was there before. Datavrn keeps a record of what this destroys, but it is NOT offered back on this surface; recovering from an undo is a support operation. Call preview_replacement_restore first, read both of its numbers to your user, get their explicit go-ahead, and send back the confirm_token it gave you with the EXACT destroy_count it returned as expected_destroy_count. Datavrn refuses and changes nothing if: the period’s data moved after you were shown those numbers, the period is locked by a finalised statement or a sealed run, someone already undid this sync, the 30-day window has closed, or the replacement was one a person previewed and confirmed themselves. On success it reports how many records were destroyed, how many were put back, and — under soft_reference_relink — how many links to the restored documents could not be re-established; tell your user that residual number rather than presenting the undo as complete.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
event_idYesThe replacement’s id — the same one you previewed.
client_idYesThe entity (client) id — from list_clients.
on_behalf_ofNoThe email address your user signs in to Datavrn with. This records who authorised the change alongside the connection that made it. REQUIRED on an API-key connection — ask your user for it, do not guess. On an OAuth connection leave it out: the change is recorded as authorised by the member who connected; if you do supply it, it must be that member.
confirm_tokenYesThe approval from preview_replacement_restore. Call it first and present both of its numbers to your user.
connection_idYesThe connected data source’s id — the same one you previewed with.
expected_destroy_countYesThe destroy_count preview_replacement_restore returned and you showed your user. Send it back unchanged — a different number is refused, because the approval covers the act your user actually saw.

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the destructiveHint=true annotation, the description discloses concrete behavioral implications: it destroys all data held in the period (including uploads/syncs after the replacement), is not recoverable on this surface, and notes that recovering is a support operation. It also clarifies that the tool reports a residual number for failed link re-establishment, adding depth beyond the annotation.

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

Conciseness4/5

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

The description is verbose (approximately 150 words) but every sentence adds critical information for a high-stakes destructive operation. It is front-loaded with the destructive warning and includes structured sections for workflow, failure conditions, and post-action reporting. While not terse, the length is justified by the operational risk and complexity, so it earns a 4 rather than a 5.

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 that there is no output schema and no annotations beyond the destructive flag, the description fully compensates: it explains what the tool does, the prerequisite workflow, all rejection conditions, what success reports (destroy count, restored count, residual link count), and that the residual number must be conveyed to the user. Nothing an agent needs to call this correctly is missing.

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

Parameters3/5

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

The input schema has 100% description coverage, with each parameter already thoroughly documented (e.g., on_behalf_of's API-key vs OAuth behavior, expected_destroy_count's exactness requirement). The description does not add new parametric information beyond what the schema already provides; it only reinforces the workflow. Baseline 3 is appropriate since the schema carries the semantic burden.

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 ('Undo'), a clear resource ('one automatic sync'), and precisely describes the action: destroy current data for the period and restore the replaced records. It distinguishes itself from sibling preview_replacement_restore by naming it as the prerequisite preview step, leaving no ambiguity about what this tool does.

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

Usage Guidelines5/5

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

The description explicitly instructs the agent on the exact workflow: call preview_replacement_restore first, read both numbers to the user, obtain explicit go-ahead, and pass back the confirm_token and destroy_count. It also lists multiple refusal conditions (data moved, locked period, already undone, 30-day window closed, human-confirmed replacement) providing clear when-not-to-use guidance and reinforcing the safe invocation pattern.

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.

TDQS

A4.1/5.0
Disambiguation5/5

Each tool targets a distinct resource or action — get_* reads, save_* writes, confirm_* approves, preview_* shows consequences before approval. Even the management-data trio (budgets, allocations, variance) is cleanly separated by surface. Two-step flows like preview_chart_rebaseline → confirm_complete_chart are clearly sequenced, so an agent won't confuse the stages.

Naming Consistency5/5

Tool names follow a highly consistent verb_noun pattern: get_* for reads, list_* for discovery, save_* for section writes, confirm_* for approvals, create_* for new entities/centres, preview_* for pre-approval checks. The few one-offs (ingest_upload, upload_trial_balance, set_header_row) still fit the verb-first convention. No camelCase or style mixing.

Tool Count2/5

At 67 tools this is well past the 'too many' threshold. While the Schedule III domain genuinely is broad — statutorily mandated sections, two-phase approval flows, readiness checks, and a separate management-data area — the surface is heavy; an agent will spend real effort just surveying the tool list. Some consolidation of the save_reserves/provisions/assets movements or merging preview+confirm pairs is possible.

Completeness4/5

The surface covers the full lifecycle: upload → mapping/costing → grouping → capture (all statutory sections) → declarations → readiness → generate → finalise → download, plus entity setup and consolidated statements. Minor gaps: no tool directly exposes historical version diffing beyond list_snapshots, and the management-data section (budgets, allocations, variance) feels bolted on rather than integral to the core flow.

Resources