Skip to main content
Glama

Delete segment

delete_segment
DestructiveIdempotent

Permanently delete a saved segment (the saved filter only; the contacts in it are not touched). Built-in quick filters cannot be deleted. Returns {deleted: true}. Errors: not_found, builtin_segment_readonly. Next: list_segments.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "segment_id": "<segment_id>"
    },
    "name": "delete_segment"
  }
}

Input Schema

NameRequiredDescriptionDefault
segment_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true and idempotentHint=true, so the bar is lower, yet the description still adds substance: the deletion is permanent, the blast radius is explicitly bounded to the filter, the return payload is given, and the two failure modes (not_found, builtin_segment_readonly) are enumerated. That is materially more than the annotations convey.

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?

Four short sentences, each doing distinct work: action and scope, the exclusion, the return value, then errors and next step. Nothing is repeated from the title and nothing is padded.

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?

There is no output schema, so the description carries the return contract itself ('{deleted: true}') plus the error codes, and it covers the destructive semantics. For a single-parameter delete tool this is everything an agent needs to invoke it and interpret the result.

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

Parameters3/5

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

There is a single required parameter with 0% schema description coverage, so the schema supplies no meaning for segment_id. The description never states whether it takes an ID or a name, or where to obtain it, though 'Next: list_segments' implicitly points at the source of valid values.

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 ('Permanently delete a saved segment') and immediately scopes it: only the saved filter is removed, the contacts inside are untouched. That scope clause distinguishes it from any contact-removal operation, and the built-in quick-filter exclusion further narrows what this tool can target.

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?

Provides an explicit when-not ('Built-in quick filters cannot be deleted') and a follow-up route ('Next: list_segments'), which is real routing guidance. It stops short of naming an alternative for removing contacts from a segment, so the agent must infer that this tool is not the way to do that.

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.