Skip to main content
Glama

gws-mcp__gmail_update_draft

Destructive

Update an existing draft email in Gmail. This fully replaces the draft's message content (Gmail API does not support partial edits), attachments included: files the draft held, including any attached by a file reference, are dropped unless they are passed again in attachments. If thread_id is omitted, the tool preserves the existing thread automatically. The account's Gmail signature is added to the draft automatically, as Gmail's own Compose does, so do not write a sign-off or signature in the body yourself; pass signature: false to leave it out. The signature goes in the draft's HTML part, so a plain-text body is stored as multipart/alternative when the account has one. The response's signature field reports what happened.

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": {
      "draft_id": "<draft_id>",
      "to": "<to>",
      "subject": "<subject>"
    },
    "name": "gws-mcp__gmail_update_draft"
  }
}

Input Schema

NameRequiredDescriptionDefault
ccNoCC recipients, comma-separated
toYesRecipient email address(es), comma-separated
bccNoBCC recipients, comma-separated
bodyNoPlain-text email body. When html_body is also given, this becomes the text/plain alternative part shown by plain-text clients. One of body or html_body is required.
accountNoOptional email address of the connected account to use (e.g. 'user@gmail.com'). If omitted, the default account is used.
subjectYesEmail subject line
draft_idYesThe Gmail draft ID to update
html_bodyNoHTML email body. The message is sent as multipart/alternative with a text/plain fallback part (body if provided, otherwise text derived from the HTML), so plain-text clients still render something readable.
signatureNoSet false to write the draft without the account's Gmail signature, and to skip the lookup entirely. Defaults to true.
thread_idNoThread ID to preserve threading. If omitted, the existing draft's thread is preserved automatically.
attachmentsNoFiles to send with the message, at most 10, 25 MB in total. Each entry is a Drive file id as a string, or {"file_id": "<id>", "as": "<format>"} to send a Google Doc, Sheet or Slides deck as a file, or a file reference. Formats: Docs pdf, docx, txt, html, md, rtf, odt, epub; Sheets pdf, xlsx, csv, tsv, html, ods; Slides pdf, pptx, txt, odp. csv and tsv export one tab: add "tab": "<title>" to choose it, otherwise the first tab goes, and the response says which. A Sheet as html arrives as a .zip of pages, one per tab; Slides as txt is the slides' visible text only. Google Docs, Sheets and Slides passed by id alone are sent as links in the message, the way Gmail does, not as files. Other Drive files are attached as they are. A file reference is an object with a "type": {"type": "gmail_message", "message_id": "<id>"} attaches an email as its original .eml, {"type": "gmail_attachment", "message_id": "<id>", "part_id": "<part id>"} one attachment of an email, {"type": "drive_file", "file_id": "<id>"} a Drive file as stored, {"type": "drive_export", "file_id": "<id>", "format": "pdf"} a Google file exported, {"type": "content", "name": "<file name>", "base64": "<standard base64, one unbroken string>"} a file the caller already holds, at most 1 MB, and {"type": "upload", "upload_id": "<id>"} a file the user sent through file_upload_link. A reference may carry an "account" naming the connected Google account that holds the email or file. Several entries may be references. Two attachments may not share a filename. To show an image in the body rather than at the bottom, reference it in html_body as <img src="cid:FILENAME">, where FILENAME is its Drive filename with any character other than letters, digits, dot, dash and underscore replaced by an underscore. Sharing a Drive link is the sender's responsibility; nothing here changes who can open a file. The response's attachments field reports each file as attached, inline, linked or exported, with its size and the SHA-256 of the bytes that went into the message; a file sent as a link has neither.

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 only say readOnlyHint=false and destructiveHint=true; the description earns that flag by spelling out exactly what is destroyed (previously held attachments, including file-reference ones, are dropped unless re-passed) and what is silently injected (the account signature, suppressible via signature:false). It also covers thread preservation and the multipart/alternative restructuring of a plain-text body, which are non-obvious side effects an agent could not infer from the schema.

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 the most decision-relevant fact (full replacement, no partial edits) before the softer consequences. It is dense but not padded; the only waste is the restatement of thread_id and signature behavior that the schema already documents verbatim.

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?

For an 11-parameter destructive mutation with no output schema, the description covers the destructive mechanics, threading, signature, and where to look in the response for confirmation. Gaps remain around failure modes (invalid draft_id, account that does not own the draft) and the fact that to/subject must be re-supplied on every call, which the full-replace model implies but never states.

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, and much of the description's parameter talk (signature:false, thread_id omission) restates the schema text. It still adds genuinely new meaning for the attachments parameter, which the schema documents only structurally: the all-or-nothing re-supply rule is stated nowhere in the schema, and the response's signature field is called out as the way to confirm behavior.

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 ('Update an existing draft email in Gmail') and immediately qualifies it as a full replacement, which separates it from gmail_create_draft, gmail_send_draft and gmail_delete_draft without needing to name them. An agent can pick this tool over the draft siblings from the first sentence alone.

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 clear operating context an agent needs before calling: the edit is not partial, omitted attachments are dropped, thread is preserved when thread_id is omitted, and the signature is added automatically so no sign-off should be written. It stops short of an explicit 'use this instead of X when Y' routing statement against gmail_create_draft or gmail_send_draft, so it is strong context rather than full when/when-not guidance.

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.