Skip to content

Guide · Agent skill

How to use the Gmail Reply Sender agent skill

Updated · written with AI from the project's own documentation and checked against our catalogue data

The Gmail Reply Sender skill (gws-gmail-reply) lets an AI agent reply to a specific Gmail message using the gws command-line tool. It is aimed at people who already have a Gmail conversation they want answered and developers who automate routine replies. After this guide you will know what the skill does, how to install it, how to ask for a reply in plain language, and which safety points to check before anything is sent.

Gmail Reply Sendergoogleworkspace/cli · Apache-2.0

Quick start

  1. 1Install the gws tool. Install the gws command-line tool (the googleworkspace CLI) so the agent can run gws.
  2. 2Configure authentication. Set up Google Workspace authentication through gws, following the gws-shared skill. If that skill is missing, run gws generate-skills.
  3. 3Install the skill. Download the ZIP from this page and unzip it into ~/.claude/skills/ or a project's .claude/skills/, or upload it under Settings → Capabilities → Skills in the Claude apps.
  4. 4Find the message ID. Get the Gmail message ID of the message you want to reply to.
  5. 5Ask for a draft first. Request a reply and ask for it to be saved as a draft so you can review it in Gmail.
  6. 6Review and send. Check the draft or run with --dry-run. Only then send the reply, because sent replies cannot be recalled.

What is an agent skill, and what does this one do?

An agent skill is a folder containing a SKILL.md file that teaches an AI agent how to perform a specific task with a tool. This skill covers one task: replying to a Gmail message. The agent supplies a message ID and the reply text, and the skill sends the reply through the gws command-line tool.

The reply is threaded correctly under the original conversation, and the original message is quoted in the reply body. The skill only handles replies. Sending a brand-new email requires the general gmail skill.

  • Replies stay in the same Gmail thread.
  • The original message is quoted in the reply.
  • Extra recipients (To, CC, BCC) can be added.
  • Files can be attached, and HTML formatting can be used.
  • A reply can be saved as a draft instead of being sent.

How do you install the gws-gmail-reply skill?

There are two ways to install the skill. For Claude Code, download the ZIP from this page and unzip it into ~/.claude/skills/ to make it available for all your projects. To limit it to one project, unzip it into the .claude/skills/ folder inside that project.

In the Claude apps, you can instead upload the ZIP under Settings → Capabilities → Skills.

  • Personal install: ~/.claude/skills/
  • Project install: .claude/skills/ inside your project folder
  • Claude apps: Settings → Capabilities → Skills, then upload the ZIP

What do you need before the skill works?

The skill needs three things: the gws command-line tool (the googleworkspace CLI), Google Workspace authentication configured through gws, and the Gmail message ID of the message you want to reply to. The skill's SKILL.md points to a gws-shared skill for authentication, global flags and security rules. If that file is missing, the source says to run gws generate-skills to create it.

  • The gws command-line tool must be installed and available as gws.
  • Authentication must be configured via gws (see the gws-shared skill).
  • You need the Gmail message ID of the message to reply to.
gws generate-skills

How do you trigger the skill with a natural request?

You do not need to type the command yourself. Ask the agent in plain language and include the message ID and the reply text. The agent uses the skill to build the command. Because a reply goes to real people, ask the agent to save it as a draft if you want to review it first.

The underlying command takes the message ID and the body. Other flags are optional.

  • "Reply to Gmail message 18f1a2b3c4d saying thanks, got it."
  • "Reply to message 18f1a2b3c4d with 'Updated version attached' and attach updated.docx."
  • "Save a draft reply to message 18f1a2b3c4d that says 'Draft reply' so I can check it."
gws gmail +reply --message-id <ID> --body <TEXT>

What flags can the agent use?

The skill documents these flags. Only --message-id and --body are required. --dry-run shows the request that would be sent without executing it, which is useful for checking before anything goes out.

--from sets the sender address for send-as or alias accounts. Leave it out to use the account default. --to adds extra To recipients, --cc and --bcc add copies, and --attach (or -a) adds a file and can be repeated. --html treats the body as HTML instead of plain text. --draft saves the reply instead of sending it.

  • --message-id (required): Gmail message ID to reply to
  • --body (required): reply text, plain or HTML with --html
  • --from: sender address for send-as/alias
  • --to, --cc, --bcc: comma-separated addresses
  • --attach / -a: file attachment, can be repeated
  • --html: treat --body as HTML
  • --dry-run: show the request without executing it
  • --draft: save as draft instead of sending
gws gmail +reply --message-id 18f1a2b3c4d --body 'Draft reply' --draft

What do the examples look like?

The skill includes these examples. Each uses the same message ID so you can see how the optional flags change the result.

  • Simple reply: gws gmail +reply --message-id 18f1a2b3c4d --body 'Thanks, got it!'
  • Add a CC: --cc carol@example.com
  • Add a To recipient: --to dave@example.com
  • HTML reply: --body '<b>Bold reply</b>' --html
  • Attachment: -a updated.docx
  • Save as draft: --draft
gws gmail +reply --message-id 18f1a2b3c4d --body 'Looping in Carol' --cc carol@example.com gws gmail +reply --message-id 18f1a2b3c4d --body '<b>Bold reply</b>' --html gws gmail +reply --message-id 18f1a2b3c4d --body 'Updated version' -a updated.docx

What safety points should you know?

This skill runs scripts and uses the network. It sends mail through your Google account, so it can act on your behalf. Replies go to real people and cannot be recalled once sent. Review the request first with --dry-run or save the reply with --draft, especially for unattended runs.

The skill is not meant for replying to all recipients automatically. For that, the source points to a separate +reply-all command. The skill also does not reply-all by itself.

  • It runs scripts and uses the network.
  • Replies cannot be recalled once sent.
  • Use --dry-run to inspect the request, or --draft to review in Gmail.
  • Do not use it for unattended sending without review.
  • Use +reply-all for reply-all.
gws gmail +reply --message-id 18f1a2b3c4d --body 'Draft reply' --draft

What tips help you get better results?

The skill sets the In-Reply-To, References and threadId headers for you, so you do not need to manage threading. When you use --html, the quoted block keeps Gmail's gmail_quote styling and inline images in the quoted message are preserved. Use fragment tags such as <p>, <b> and <a>. A full <html> or <body> wrapper is not needed.

  • Threading headers are set automatically.
  • Use fragment tags (<p>, <b>, <a>) with --html; no <html>/<body> wrapper is needed.
  • Inline images in the quoted message are kept when using --html.
  • Use --draft while you are learning the skill.

What people use it for

  • Answering a question in an open Gmail thread with a short reply.
  • Adding a colleague to a thread with --cc or --to while replying.
  • Sending a reply with a file attached, such as an updated document.
  • Drafting routine replies for review before they go out.
  • Sending formatted HTML replies that keep inline images from the quoted message.

Frequently asked questions

How do I install the gws-gmail-reply skill?

Download the ZIP from this page and unzip it into ~/.claude/skills/ for all projects, or into a project's .claude/skills/ folder for one project. In the Claude apps, upload the ZIP under Settings → Capabilities → Skills.

What do I need to use the Gmail reply skill?

You need the gws command-line tool, Google Workspace authentication configured through gws, and the Gmail message ID of the message you want to reply to. The skill's source points to the gws-shared skill for authentication details.

Is the gws-gmail-reply skill free?

The skill is licensed under Apache-2.0. This page does not state any pricing, so check the upstream repository for licence terms and any costs of the Google services it uses.

Can the agent reply to all recipients automatically?

No. This skill only handles replies to the sender. For reply-all, the source says to use the separate +reply-all command.

Can I send a new email with this skill?

No. The skill only handles replies. For new emails that are not replies, use the general gmail skill.

How do I avoid sending a reply by mistake?

Ask the agent to save the reply as a draft with --draft, or run the request with --dry-run to see what would be sent. Sent replies cannot be recalled, so review first.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

This skill suits people who want an agent to answer Gmail threads they already have open, and developers who automate routine replies through gws. Use it with drafts or dry runs so you review replies before they reach real people. If you need brand-new emails or reply-all by default, pick the general gmail skill or the +reply-all command instead.

Download the skill