Skip to main content
Glama

Batch operations (transactional)

batch

Execute multiple record operations atomically in one request. All operations succeed together or roll back, ensuring data consistency for create, update, delete, and upsert actions.

Instructions

Execute multiple record operations in a single transactional request. All operations succeed or all are rolled back. Each operation has an action ('create' | 'update' | 'delete' | 'upsert'), a target collection, and depending on the action a data object and/or record id. For 'upsert', include the record 'id' inside data (creates if missing, updates if present). Note: the Batch API must be enabled in PocketBase settings (Settings > Batch API).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
operationsYesList of operations to run atomically.

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv1.0.0

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations provided, the description carries the full behavioral burden and does well: it discloses atomicity/rollback semantics, the upsert edge case (id inside data, creates-if-missing/updates-if-present), and the operational prerequisite (Batch API must be enabled in Settings). It omits auth requirements and error reporting, but the critical behavioral traits for safe invocation are present.

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?

Four sentences with every sentence earning its place: purpose, atomicity guarantee, operation envelope, upsert nuance, and settings prerequisite. The core purpose is front-loaded and the prerequisite is properly relegated to the end. Slightly dense, but well-organized and free of repetition.

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?

For a nested-array tool with full schema coverage and no output schema, the description covers what an agent needs: the action vocabulary, per-action parameter requirements, the transactional behavior, and the enablement prerequisite. The only notable absence is guidance on failure response format, which is partially mitigated by the rollback guarantee.

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 genuine value beyond the schema: it clarifies that id is required for update/delete, data is for create/update/upsert, and specifically resolves the ambiguous upsert case (id goes inside data, not as a top-level field). This compensates for the schema's terse per-field notes.

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 and resource ('Execute multiple record operations in a single transactional request'), and the transactional qualifier clearly distinguishes it from single-operation siblings like create_record, update_record, and delete_record. The action enum ('create' | 'update' | 'delete' | 'upsert') reinforces the scope without ambiguity.

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

Usage Guidelines3/5

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

The transactional promise ('All operations succeed or all are rolled back') implies the use case: atomic multi-record operations where partial success is unacceptable. However, it never explicitly names alternatives (e.g., 'use create_record/update_record/delete_record for single operations') or states when not to use it, leaving the routing decision largely to inference.

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nestebe/pocketbase-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server