Skip to main content
Glama
secure-telegram-mcp

secure-telegram-mcp

Delete message(s)

delete_message
Destructive

Delete one or more Telegram messages in an allowed chat, defaulting to removal for yourself; set revoke=true to remove them for everyone.

Instructions

Delete one or more messages in a single in-scope chat. Defaults to deleting only for yourself; set revoke=true to remove for everyone. Out-of-scope chats are rejected; the batch is capped per request.

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": {
      "peer": "<peer>",
      "messageIds": "<messageIds>"
    },
    "name": "delete_message"
  }
}

Input Schema

NameRequiredDescriptionDefault
peerYesChat reference: { kind:'id', value:'<decimal id>' } | { kind:'username', value:'@name' } | { kind:'me' }.
revokeNoWhen true, delete the message(s) for everyone (revoke). Default false deletes only for yourself.
messageIdsYesBetween 1 and 100 message ids.

Output Schema

NameRequiredDescriptionDefault
chat_idYesChat the messages were deleted from.
revokedYesWhether the delete revoked for everyone (false = self only).
deleted_message_idsYesThe message ids that were deleted (echo of the request batch).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already flag destructiveHint=true and idempotentHint=false, so the safety profile is known; the description adds the crucial distinction that default scope is self-only versus the wider blast radius of revoke=true. It also discloses two constraints not present in structured fields: out-of-scope chats are rejected outright and the batch is capped. It does not say how partial failures or already-deleted ids are handled.

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?

Three tight sentences, with the destructive default front-loaded before the revoke escalation. No filler or redundant restatement of the title.

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?

With an output schema present, return values need no explanation, and annotations cover the destructive profile, so the remaining description is largely sufficient for a delete tool. The one gap is failure semantics for a batch (partial success, missing ids), which matters because the operation is destructive and non-idempotent.

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?

Schema coverage is 100% and the schema already spells out the peer variants, the revoke default-to-false semantic, and the 1-100 id range, so most of what the description says about revoke is a restatement. The description adds only the framing of 'in-scope chat' and the per-request cap, which the schema's maxItems already encodes.

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 ('Delete one or more messages') plus the scope constraint of a single chat. An agent can instantly separate this from sibling tools like edit_message or forward_message without inspecting 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?

Gives concrete operating context: deletion defaults to self-only and requires revoke=true to remove for everyone, and out-of-scope chats are rejected. It never names an alternative tool or an explicit 'do not use when' condition, so it stops short of full routing guidance.

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