

Gmail - All Email Actions
Connector
Available ActionsEach successful request consumes credits as outlined below.
send_message5crreply_message5crforward_message5crlist_messages5crget_message5crtrash_message5cruntrash_message5crmodify_labels5crlist_labels5crcreate_draft5crsend_draft5crget_draft5crdelete_draft5crget_profile5cr
Details
Gmail connection that enables agents to send, read, search, and manage email through Google OAuth integration. The tool provides comprehensive email functionality including composing and sending new messages with attachments, replying to emails while maintaining thread continuity, and forwarding messages to new recipients. Agents can search and filter emails using Gmail's powerful query syntax to find specific messages by sender, subject, date, labels, or attachment status. The tool supports full email lifecycle management including reading message content with parsed headers and body text, moving messages to trash or permanently deleting them, and modifying labels to organize emails or mark them as read. Draft functionality allows agents to create, retrieve, and send draft emails for workflows requiring human review before sending. Additional capabilities include listing all available labels for organization, retrieving user profile information such as email address and message counts, and sending from custom authenticated email addresses.
Use Cases
Automated email notifications and alerts, Customer inquiry response and follow-up, Email search and retrieval for information gathering, Inbox management and organization with labels, Draft creation for human-in-the-loop email workflows, Email forwarding and delegation workflows, Reading and summarizing email content, Marking messages as read or starring important emails, Sending reports and documents as attachments, Monitoring inbox for specific senders or keywords
Credentials
Google OAuth *
Connect your Google account.
Manage credentials in your dashboard.
Actions(14)
send_message5cr9 params(2 required)Send a new email. Supports plain text, HTML, attachments, CC/BCC, and custom from address (requires send-as alias).
send_message5cr9 params(2 required)Send a new email. Supports plain text, HTML, attachments, CC/BCC, and custom from address (requires send-as alias).
torequiredarrayRecipient email addresses
Array of: string
subjectrequiredstringEmail subject line
body_textstringPlain text email body. Required unless body_html is provided.
body_htmlstringHTML email body. Can be used instead of or in addition to body_text.
ccarrayCC recipients
Array of: string
bccarrayBCC recipients
Array of: string
from_emailstringFrom address to override the default sender. Only works if a send-as alias is configured in Gmail settings.
thread_idstringThread ID to add this message to an existing conversation thread
attachmentsarrayFile attachments. Provide public file URLs that will be fetched and attached.
Array of: object
reply_message5cr6 params(1 required)Reply to an existing email. The reply stays in the same thread and automatically uses the original subject and recipient.
reply_message5cr6 params(1 required)Reply to an existing email. The reply stays in the same thread and automatically uses the original subject and recipient.
message_idrequiredstringGmail message ID of the email to reply to
body_textstringPlain text reply body. Required unless body_html is provided.
body_htmlstringHTML reply body. Can be used instead of or in addition to body_text.
ccarrayCC recipients
Array of: string
bccarrayBCC recipients
Array of: string
attachmentsarrayFile attachments
Array of: object
forward_message5cr6 params(2 required)Forward an email to new recipients. The original message content is included automatically.
forward_message5cr6 params(2 required)Forward an email to new recipients. The original message content is included automatically.
message_idrequiredstringGmail message ID of the email to forward
torequiredarrayRecipient email addresses to forward to
Array of: string
body_textstringOptional text to add above the forwarded content
ccarrayCC recipients
Array of: string
bccarrayBCC recipients
Array of: string
attachmentsarrayAdditional file attachments
Array of: object
list_messages5cr4 paramsSearch and list emails. Returns message IDs and thread IDs. Use get_message to read full content.
list_messages5cr4 paramsSearch and list emails. Returns message IDs and thread IDs. Use get_message to read full content.
qstringGmail search query (e.g., 'is:unread', 'from:user@example.com', 'subject:meeting', 'has:attachment', 'newer_than:7d')
max_resultsintegerMaximum results to return (1-500)
Default:
20Range: 1 - 500
label_idsarrayFilter by these label IDs
Array of: string
page_tokenstringPagination token from a previous list_messages response
get_message5cr2 params(1 required)Read the full content of an email including headers, body text, HTML, and attachment metadata.
get_message5cr2 params(1 required)Read the full content of an email including headers, body text, HTML, and attachment metadata.
message_idrequiredstringGmail message ID
message_formatstringMessage format: full (headers + body, default), metadata (headers only), minimal (IDs only)
Values:
fullmetadataminimal
Default:
fulltrash_message5cr1 param(1 required)Move an email to the trash.
trash_message5cr1 param(1 required)Move an email to the trash.
message_idrequiredstringGmail message ID of the email to trash
untrash_message5cr1 param(1 required)Restore an email from the trash back to its original location.
untrash_message5cr1 param(1 required)Restore an email from the trash back to its original location.
message_idrequiredstringGmail message ID of the email to restore
modify_labels5cr3 params(1 required)Add or remove labels from an email. Common uses: mark as read (remove UNREAD), star (add STARRED), archive (remove INBOX).
modify_labels5cr3 params(1 required)Add or remove labels from an email. Common uses: mark as read (remove UNREAD), star (add STARRED), archive (remove INBOX).
message_idrequiredstringGmail message ID
add_label_idsarrayLabel IDs to add. Common: STARRED, IMPORTANT, UNREAD
Array of: string
remove_label_idsarrayLabel IDs to remove. Common: UNREAD (mark as read), INBOX (archive)
Array of: string
list_labels5cr0 paramsGet all available Gmail labels (both system and user-created).
list_labels5cr0 paramsGet all available Gmail labels (both system and user-created).
No parameters for this action.
create_draft5cr9 params(2 required)Create a draft email that can be edited or sent later.
create_draft5cr9 params(2 required)Create a draft email that can be edited or sent later.
torequiredarrayRecipient email addresses
Array of: string
subjectrequiredstringEmail subject line
body_textstringPlain text email body. Required unless body_html is provided.
body_htmlstringHTML email body. Can be used instead of or in addition to body_text.
ccarrayCC recipients
Array of: string
bccarrayBCC recipients
Array of: string
from_emailstringFrom address override (requires send-as alias)
thread_idstringThread ID to associate the draft with an existing conversation
attachmentsarrayFile attachments
Array of: object
send_draft5cr1 param(1 required)Send a previously created draft email.
send_draft5cr1 param(1 required)Send a previously created draft email.
draft_idrequiredstringGmail draft ID
get_draft5cr2 params(1 required)Retrieve the content of a draft email.
get_draft5cr2 params(1 required)Retrieve the content of a draft email.
draft_idrequiredstringGmail draft ID
message_formatstringMessage format: full (default), metadata, minimal
Values:
fullmetadataminimal
Default:
fulldelete_draft5cr1 param(1 required)Permanently delete a draft email.
delete_draft5cr1 param(1 required)Permanently delete a draft email.
draft_idrequiredstringGmail draft ID to delete
get_profile5cr0 paramsGet the authenticated user's Gmail profile including email address, total message count, and total thread count.
get_profile5cr0 paramsGet the authenticated user's Gmail profile including email address, total message count, and total thread count.
No parameters for this action.
Frequently Asked Questions
How do I connect this tool to an external agent?
You can install the local MCP server by opening a terminal and running:
Install commands
npm install -g @agentpmt/mcp-router
agentpmt-setupThis will connect you to local agents like Claude Code, Windsurf, Grok Build, Cursor, etc.
Alternatively you can connect to the hosted version with this config block, no installation required:
Hosted MCP config
{
"mcpServers": {
"agentpmt": {
"type": "streamable-http",
"url": "https://api.agentpmt.com/mcp",
"headers": {
"Authorization": "Bearer <AGENTPMT_BEARER_TOKEN>",
"x-instance-metadata": "{\"client\":\"generic-mcp\",\"platform\":\"remote\"}"
}
}
}
}View MCP Connection Instructions for more details.
How does an external agent use this tool?
After the external agent is connected to an Agent Group that can use this tool, paste this prompt into the agent:
Agent prompt
Call the AgentPMT-Tool-Search-and-Execution tool with action 'get_schema' and tool_id 69618e485d4cf4d4b6af40f0 ("Gmail - All Email Actions"). Then call the same tool with action 'call_tool', tool_id 69618e485d4cf4d4b6af40f0, and the parameters needed for my request.
The agent should fetch the tool schema first, collect the required parameters for your request, and then call the tool through AgentPMT.

















