Skip to main content
Glama

Undo End-User Merge

unmerge_end_users
Idempotent

Undo an incorrect end-user identity merge: re-point all linked records to the original users and un-tombstone folded-in sources. Reversible for 30 days using the merge event ID; retrying is safe.

Instructions

Undo a previous end-user merge: reads the merge ledger and re-points every FK row (events, insights, tasks, …) back to its original end-user, un-tombstoning the folded-in sources. Safe to retry — a second undo of the same merge changes nothing (it fails with already_reverted). Use to correct a wrong identity merge (merges stay reversible for 30 days). Find the event_id with list_identity_merges (pick an un-reverted merge); event_id is required.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
event_idYesId of the merge event to undo, from list_identity_merges.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.14

TDQS

A5/5.0
Behavior5/5

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

The description adds substantial behavioral context beyond the annotations: it reveals that the tool reads a merge ledger, re-points foreign keys, un-tombstones sources, and fails with 'already_reverted' on retry. This enriches the idempotentHint=true annotation without contradicting any annotation.

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?

The description is three sentences of tightly packed, relevant information with no fluff. The purpose is front-loaded, followed by behavioral details and usage instructions. Every sentence 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?

For a one-parameter, no-output-schema tool, the description is remarkably complete: it covers the operational mechanism, retry behavior, use case, and how to source the parameter. There are no obvious gaps that would leave an agent uncertain.

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

Parameters5/5

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

Although the schema already documents event_id with 100% coverage, the description adds practical sourcing instructions: find it via list_identity_merges and pick an un-reverted merge. This guidance goes beyond schema descriptions, turning a raw ID field into a fully actionable parameter.

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 opens with 'Undo a previous end-user merge,' which is a specific verb+resource statement. It further distinguishes the tool from its sibling merge_end_users by detailing the mechanics (re-pointing FK rows, un-tombstoning sources), making the purpose unmistakable.

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 states when to use it ('Use to correct a wrong identity merge') and adds a temporal constraint ('merges stay reversible for 30 days'). It also tells the user how to obtain the required event_id via list_identity_merges, providing clear invocation guidance.

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