Skip to content
All tools

telegram_delete_message

Telegram · macOS · Windows

Effect: delete (strongest supported action). Status: gated.

Gated means the tool requires an installed app, a connected account, permission, or runtime availability. Check those requirements on the listed platform before using it.

macOS

Purpose

Deletes ONE message you sent in a Telegram private chat or basic group, for everyone, only after the receiver acknowledged it: the receiver must have replied to that exact message with the text ACK (a human in the Telegram app, or an agent with telegram_send_message reply_to_message_id). DESTRUCTIVE, with a preview: confirm=false (the default) checks the ACK and deletes NOTHING; show the preview to the user and call again with confirm=true and the same account only after they approve. The confirm checks everything again. Reading the chat, unread=0 or any text never count as an ACK. The ACK proves that another Telegram account replied, not that it is another person; an account linked in this LMCP is never accepted as the receiver, so each computer with agents needs its own Telegram account. In a basic group the ACK proves that the user you named as receiver replied, not that the message was meant for them: the receiver is whoever you name. Supergroups and channels are not supported. state deleted means the message no longer exists in this account (requested for everyone); unknown means it may have been deleted, so call again and the answer will be deleted or not_found.

Required inputs

Permissions and confirmation

Explicit confirmation parameter: inspect the schema and tool description before any real call. The documentation example keeps confirm false. Obtain user authorization before performing the action.

Full input schema — macOS
{
  "properties": {
    "account": {
      "description": "Which linked Telegram account to use: its label or id from telegram_list_accounts. Leave it out to use the default account.",
      "type": "string"
    },
    "ack_message_id": {
      "description": "Id of the receiver's reply ACK to that message (from telegram_read_messages).",
      "type": "integer"
    },
    "chat_id": {
      "description": "Chat id from telegram_list_chats: user:… (private) or chat:… (basic group).",
      "type": "string"
    },
    "confirm": {
      "description": "Must be true to delete. Without it, returns a preview and deletes nothing.",
      "type": "boolean"
    },
    "message_id": {
      "description": "Id of your own message to delete (from telegram_read_messages).",
      "type": "integer"
    },
    "receiver": {
      "description": "The receiver's user:<id>:<hash> id from telegram_list_chats. Only this user's ACK counts.",
      "type": "string"
    }
  },
  "required": [
    "chat_id",
    "message_id",
    "ack_message_id",
    "receiver"
  ],
  "type": "object"
}

Documentation example

Do not execute this example. These concrete inputs refer to a fictional demonstration dataset. Resolve real handles and obtain user authorization before any real call.

{
  "ack_message_id": 4022,
  "chat_id": "user:5550100123",
  "confirm": false,
  "message_id": 4021,
  "receiver": "user:5550100123:9f8e7d6c5b4a"
}

Windows

Purpose

Deletes ONE message you sent in a Telegram private chat or basic group, for everyone, only after the receiver acknowledged it: the receiver must have replied to that exact message with the text ACK (a human in the Telegram app, or an agent with telegram_send_message reply_to_message_id). DESTRUCTIVE, with a preview: confirm=false (the default) checks the ACK and deletes NOTHING; show the preview to the user and call again with confirm=true and the same account only after they approve. The confirm checks everything again. Reading the chat, unread=0 or any text never count as an ACK. The ACK proves that another Telegram account replied, not that it is another person; an account linked in this LMCP is never accepted as the receiver, so each computer with agents needs its own Telegram account. In a basic group the ACK proves that the user you named as receiver replied, not that the message was meant for them: the receiver is whoever you name. Supergroups and channels are not supported. state deleted means the message no longer exists in this account (requested for everyone); unknown means it may have been deleted, so call again and the answer will be deleted or not_found.

Required inputs

Permissions and confirmation

Explicit confirmation parameter: inspect the schema and tool description before any real call. The documentation example keeps confirm false. Obtain user authorization before performing the action.

Full input schema — Windows
{
  "properties": {
    "account": {
      "description": "Which linked Telegram account to use: its label or id from telegram_list_accounts. Leave it out to use the default account.",
      "type": "string"
    },
    "ack_message_id": {
      "description": "Id of the receiver's reply ACK to that message (from telegram_read_messages).",
      "type": "integer"
    },
    "chat_id": {
      "description": "Chat id from telegram_list_chats: user:… (private) or chat:… (basic group).",
      "type": "string"
    },
    "confirm": {
      "description": "Must be true to delete. Without it, returns a preview and deletes nothing.",
      "type": "boolean"
    },
    "message_id": {
      "description": "Id of your own message to delete (from telegram_read_messages).",
      "type": "integer"
    },
    "receiver": {
      "description": "The receiver's user:<id>:<hash> id from telegram_list_chats. Only this user's ACK counts.",
      "type": "string"
    }
  },
  "required": [
    "chat_id",
    "message_id",
    "ack_message_id",
    "receiver"
  ],
  "type": "object"
}

Documentation example

Do not execute this example. These concrete inputs refer to a fictional demonstration dataset. Resolve real handles and obtain user authorization before any real call.

{
  "ack_message_id": 4022,
  "chat_id": "user:5550100123",
  "confirm": false,
  "message_id": 4021,
  "receiver": "user:5550100123:9f8e7d6c5b4a"
}