-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Description
Problem
All Gmail tools that accept file attachments (GMAIL_SEND_EMAIL, GMAIL_CREATE_EMAIL_DRAFT, GMAIL_REPLY_TO_THREAD) define the attachment parameter as a single object:
"attachment": {
"type": "object",
"properties": {
"name": { "type": "string" },
"mimetype": { "type": "string" },
"s3key": { "type": "string" }
}
}This means users can only attach one file per email. There is no way to send an email with multiple attachments — a very common real-world need.
The Gmail API itself has zero limitation here — RFC 2822 MIME multipart/mixed supports unlimited attachment parts (up to the 25MB total size limit).
Requested Change
Add an attachments field (array of file objects) to all Gmail tools that accept files:
"attachments": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": { "type": "string" },
"mimetype": { "type": "string" },
"s3key": { "type": "string" }
}
}
}Affected tools:
GMAIL_SEND_EMAILGMAIL_CREATE_EMAIL_DRAFTGMAIL_REPLY_TO_THREAD
Also missing:
GMAIL_UPDATE_DRAFT— there is no tool to update an existing draft. This would be useful for incrementally building emails with multiple attachments, or editing drafts before sending.
Context
- This was previously reported in Discussion Support sending multiple attachements for `GMAIL_SEND_EMAIL` #1970 (Sep 2025) with no resolution
- Issue Can't send attachments with GMAIL_SEND_EMAIL #1905 confirmed single-attachment is the current intended behavior
- We're building an AI agent platform (open source) that uses Composio's
composio-clientREST API for Gmail/Drive/etc integrations. Multiple attachments is a frequently requested user need that we currently cannot fulfill.
Workaround Attempted
We considered creating a draft with attachment A, then updating with attachment B — but drafts.update in Gmail API is a full PUT (replaces entire message), so previous attachments are lost. And the singular attachment field means we can't pass [A, B] anyway.
The only current workaround is using the proxy tool to construct raw MIME messages, which defeats the purpose of having high-level tool abstractions.