Skip to main content
Glama

prepare_batch_write

Validate and preview up to 10 record write actions atomically against a consistent snapshot; execution applies them in order with version checks, and any failure cancels the entire batch.

Instructions

Preview 1–10 existing-record writes atomically; returns one action_id. Each item uses the argument shape documented by prepare_write, its review_ids, decision_reason and optional actual clarification. All reviews are validated against the same initial snapshot. Items then execute in order with version checks; repeated writes to one record must use successive expected_version values. Nothing is changed. Creation and collection changes use the existing single-write discovery workflow. Any failing operation rejects the entire batch with a zero-based item_index.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
actionsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and does so well: it discloses atomicity, same-initial-snapshot validation, ordered execution with version checks, no side effects ('Nothing is changed'), and whole-batch rejection with a zero-based item_index.

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?

Front-loaded purpose and dense with useful information; every sentence contributes. Minor clarity issues like 'actual clarification' and the vague 'existing single-write discovery workflow' keep it from being fully polished.

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

Completeness4/5

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

Covers nearly all critical behavior for a prepare endpoint: validation snapshot, ordering, version checks, no persistence, failure behavior, and the action_id result. The main gap is not explicitly stating that the returned action_id should be passed to commit_batch_write to apply the batch.

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 description coverage is 0%, but the description compensates by referencing prepare_write's argument shape and naming review_ids, decision_reason, and optional clarification. It also adds batch-level semantics like the 1–10 limit and successive expected_version requirement, though it does not enumerate operation/arguments fields explicitly.

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?

States a specific verb ('Preview'), resource ('existing-record writes'), scope ('1–10'), and outcome ('returns one action_id'). The atomicity and batch nature clearly distinguish it from single-write prepare_write and commit_batch_write.

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?

Gives clear context: use for 1–10 existing-record writes, and explicitly excludes creation/collection changes by directing them to the single-write discovery workflow. However, it does not explicitly name commit_batch_write as the follow-up step or state when single prepare_write should be preferred.

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