Skip to main content
Glama

WA MCP

edit_message

DestructiveIdempotent

Edits the text of one of the user's own WhatsApp text messages for everyone in the chat (like "Edit" on the phone), in a 1:1 chat or a group. Paid plan only: on the free plan the call is refused with a note on how to subscribe. Pass the message's id from read_chat_history or search_messages and the full new text; the chat is looked up automatically. Only text messages the user sent (from "Me") can be edited, not captions of photos, videos or documents. If you are writing the text yourself rather than sending words the user gave you, call get_writing_style for this chat first and write it the way the user writes; skip that for dictated text. Everyone in the chat sees the new text marked as edited, so confirm the wording with the user first unless they gave it. Returns { message_id, status (edited or failed), chat, text, warning?, error? }: chat is the conversation, with the contact fields (name; name_source: address_book, push_name, group_subject, business, phone or unresolved; canonical_jid: the JID to pass to send_message and read_chat_history; phone_jid and lid_jid: the chat's phone-number and LID forms, null when unknown or for groups; phone_display: the number as +). warning is set when the message is more than about 15 minutes old: WhatsApp may not apply the edit; tell the user.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesThe complete new text of the message (it replaces the old text entirely).
message_idYesThe `id` of the user's own text message, from read_chat_history or search_messages.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations declare destructive/idempotent/openWorld, and the description adds substantial context on top: paid-plan gating and refusal behavior, that edits are visible to everyone and marked as edited, and the ~15-minute window where WhatsApp may silently not apply the edit. That age-based warning is behavioural knowledge not derivable from any structured field.

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?

Front-loaded with purpose and constraints, and nearly every sentence carries operational meaning. The return-value sentence is long and dense, but it substitutes for an absent output schema, so it is not waste.

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?

With no output schema and a destructive mutation, the description fully covers return shape ({message_id, status, chat, text, warning?, error?}), the meaning of warning, and the identity fields. An agent has everything needed to call it and interpret the result.

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 coverage is 100%, so the baseline is 3; the description still adds provenance for `message_id` (must be the user's own text message, sourced from read_chat_history or search_messages) and clarifies that the chat is resolved automatically, so no chat parameter is needed.

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?

Specific verb + resource ('Edits the text of one of the user's own WhatsApp text messages for everyone in the chat'), with a plain-language analogy and explicit scope (1:1 or group). It is clearly separable from send_message, delete_message and react_to_message.

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 positive conditions (own text messages, id from read_chat_history/search_messages), exclusions (not captions of photos/videos/documents), a prerequisite (paid plan), and a distinct alternative path (call get_writing_style first unless text is dictated). It also states a confirmation norm before mutating shared chat state.

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