Skip to main content
Glama

cleanup_migration

Remove records created during a migration from staging and target tables. Use to clean up after test runs or roll back failed migrations.

Instructions

Remove records that were created during a migration — both from the staging table and from the target table (e.g. incidents).

Use this if: - The test migration created records you want to delete before the real run - A migration went wrong and you want to start fresh - The client asked you to roll back

IMPORTANT: Always ask the user for explicit permission before calling this tool. Show them exactly how many records will be deleted and from which tables. Only proceed after they confirm with "Yes, delete them" or similar.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
staging_tableYes
target_tableYesServiceNow target table to clean up (same table that was used in build_artifacts)
project_keysNoProject / object keys to scope the cleanup (e.g. ["EMAL","KAN"])
project_fieldNoStaging table column that holds the project key (e.g. u_jira_project). Used to scope deletion. Leave blank to delete all staging records.
confirmedYesMust be true — user has explicitly confirmed the deletion
Behavior4/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It clearly states the tool deletes records from both tables and requires user confirmation. It instructs the user to display the number of records to be deleted. While it could mention whether the deletion is reversible or what happens to associated data, it sufficiently covers the destructive nature and safety requirements.

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 concise, about 8 lines, with a clear main sentence followed by bullet points for usage guidelines. It is front-loaded with the core action and efficiently adds important behavior instructions without redundancy.

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?

Given the tool's complexity (5 parameters, no output schema or annotations), the description provides substantial coverage of purpose, usage, and behavior. It does not explain the return value, but that is acceptable. It could mention a bit more about how the tool identifies 'records created during a migration,' but overall it is sufficiently complete.

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 80%, so most parameters are already described. The tool description adds value by contextualizing the parameters: it explains that 'staging_table' and 'target_table' are used together, that 'project_keys' and 'project_field' scope the deletion, and that 'confirmed' must be true after explicit user confirmation. This adds meaningful semantic context beyond the schema.

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 clearly states the tool removes records created during a migration from both staging and target tables. The verb 'Remove' and the specific resource distinction (staging and target tables) make the purpose unambiguous. It also distinguishes from siblings like 'cleanup_artifacts' by focusing on migration-created records.

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 provides three bullet points of when to use this tool (test migration cleanup, recovery from a failed migration, client-requested rollback). It also gives crucial usage guidance: always ask for explicit permission, show the user exactly how many records will be deleted, and only proceed after confirmed. This is exemplary guidance.

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

Install Server

Other Tools

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/pinnintisagarSB/ServiceNow-Dev-MCP'

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