App Logo
mail.google.com

Download Gmail attachments

Automatically download Gmail attachments on mail.google.com. Download every attachment of a Gmail thread, given its thread id as returned by search_emails, and save the files to your computer under their real names. Returns the thread id, how many files were saved, and each file's name and path. Attachments from every message in the thread are included, and inline images count as attachments.

Input

threadId required

Hex legacy thread id.

account optional

Google account email to act as (authuser=). Without it Gmail picks u/0, nondeterministic in a multi-account browser jar.

Output

n required
files required
threadId required

FAQ

Download every attachment of a Gmail thread, given its thread id as returned by search_emails, and save the files to your computer under their real names. Returns the thread id, how many files were saved, and each file's name and path. Attachments from every message in the thread are included, and inline images count as attachments.
Ask an AI agent connected to Reduck to run reduck/mail.google.com/download_attachment, or run it from a terminal with the Reduck CLI: npx @reduck-ai/cli@latest run --script reduck/mail.google.com/download_attachment
You do not need one. "Download Gmail attachments" drives the real mail.google.com pages in a browser, so it works whether or not mail.google.com offers an API for this.
Required: threadId. Optional: account.
It returns n, files, threadId.
Yes. It acts as you on mail.google.com: on your own Chrome it reuses your session, and on a Reduck-hosted browser it loads the mail.google.com cookies saved by the Reduck extension.
It only reads. It looks things up on mail.google.com and changes nothing there.
Ask an AI agent connected to Reduck to run reduck/mail.google.com/download_attachment, or run it from a terminal with the Reduck CLI: npx @reduck-ai/cli@latest run --script reduck/mail.google.com/download_attachment
It is part of Reduck's official curated catalogue.

Start building not clicking