Skip to main content
Glama

edit_chat_message

DestructiveIdempotent

AccountHub chat: fix the text of ONE of your own messages (one-to-one or group chat; a group chat is a shared project), within 15 minutes of sending it — NOT Slack, Gmail or Chatwork. Before calling, show the user the new text and get their OK. Everyone in the chat then sees the new text marked as edited (read_chat returns edited_at); the old text is shown to nobody. Notifications already delivered and what other AIs already read do not change, and nobody is notified again. Refused (nothing changed) with chat_edit_expired after 15 minutes — send the corrected text as a new message with send_chat_message instead — chat_edit_withdrawn if it was unsent, and chat_edit_not_allowed for someone else's message, a decision / question / to-do, a system line, a forwarded copy or a photo-only message. Attachments cannot be added or removed. Trial users only.

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": {
      "item_id": "<item_id>",
      "text": "<text>"
    },
    "name": "edit_chat_message"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesThe whole corrected text (replaces the old text; the first line becomes the preview). Cannot be empty — to remove a message, it must be unsent in the app instead. Attachments stay as they are.
item_idYesitem_id of YOUR OWN message to fix (from read_chat, is_you: true).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior5/5

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

Annotations only say idempotentHint=true and destructiveHint=true; the description goes far past that by disclosing the 15-minute window, that the old text is visible to nobody, that everyone sees an 'edited' marker via read_chat's edited_at, that already-delivered notifications and prior AI reads are unaffected, that attachments cannot change, and the trial-user restriction. It also names three distinct refusal codes, which is exactly the behavioral detail annotations cannot carry.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The operation and its central constraint are front-loaded in the first clause, and the dense single paragraph is high-information rather than padded. Minor waste exists: 'Attachments cannot be added or removed' is repeated from the text parameter schema, and 'Trial users only' is appended as a trailing fragment.

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 destructive two-parameter mutation with no output schema, the description covers everything an agent needs: preconditions, time limit, user-visible side effects, downstream effects on notifications and prior reads, immutability of attachments, and the specific failure modes. Nothing material is left to inference.

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 description coverage is 100%, so text (whole corrected text, first line becomes preview, cannot be empty, attachments stay) and item_id (from read_chat, is_you: true) are already fully documented in structured fields. The description adds the useful framing that it must be your own message, but largely restates schema content, so baseline 3 applies.

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 ('fix the text of ONE of your own messages') and scopes it to one-to-one or group chat. It explicitly names the sibling platforms it is NOT ('NOT Slack, Gmail or Chatwork'), which lets an agent separate it from update_slack_message and similar tools without opening a schema.

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?

Gives an explicit precondition ('show the user the new text and get their OK') and an explicit alternative when the window has closed ('send the corrected text as a new message with send_chat_message instead'). It also enumerates the exclusion cases that route away from this tool: someone else's message, decisions/questions/to-dos, system lines, forwarded copies, photo-only messages.

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.

Resources