Skip to main content
Glama

Merge two coffees

merge_beans
Destructive

Fold one coffee into another when the same coffee was registered twice. Every bag, shot, recipe and recommendation of from_bean_id moves to into_bean_id; the active coffee follows if it was the one merged away; origins move only if the target has none. Where both hold a locked recipe for the same grinder, machine, program and drink, the newer lock wins and the older is deleted. The source coffee is archived, never deleted. Irreversible — confirm both numbers with the user first (list_beans shows them).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
reasonNoOptional note, recorded on the surviving coffee's notes with the merge
from_bean_idYesThe duplicate: the coffee number that will be emptied and archived
into_bean_idYesThe coffee number that keeps everything

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
movedYes
statusYes
messageYes
into_bean_idYes
active_followedYes
replaced_recipesYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already mark this destructive and non-idempotent, but the description goes far beyond them: it enumerates what migrates (bags, shots, recipes, recommendations), the special-case rules for the active coffee, origins moving only when the target has none, and the lock conflict resolution ('the newer lock wins and the older is deleted'). It also clarifies that the source is archived and never deleted, and warns the operation is irreversible.

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?

Two dense sentences, front-loaded with the action and the condition, followed by the behavioral rules. Given the destructive and conflict-sensitive nature of the operation, every clause carries useful information and none is filler.

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?

For a destructive merge with an output schema already covering the return value, the description supplies everything an agent needs: trigger condition, data migration rules, conflict resolution, archive-not-delete reassurance, irreversibility warning, and a verification path via list_beans.

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 all three parameters are already documented, giving a baseline of 3. The description nevertheless adds meaning beyond the schema by stating the direction of data flow ('of from_bean_id moves to into_bean_id') and clarifying the archive semantics of the emptied coffee.

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 ('Fold one coffee into another') plus the exact situation that triggers it ('the same coffee was registered twice'). An agent can immediately distinguish this from siblings like update_bean or register_coffee without opening any schema.

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?

The triggering condition is explicit ('when the same coffee was registered twice') and it names list_beans as the way to obtain and verify the two IDs, plus a prerequisite to confirm with the user. It does not, however, state when NOT to use it or contrast it against a plausible alternative such as update_bean.

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