A Model Context Protocol (MCP) server acts as a proxy between an external service that provides context, data, or capabilities to a Large Language Model (LLM) or AI application. MCP servers connect AI applications to external systems such as databases and web services, translating their responses into a format that the AI application can understand.
MCP Tools
An MCP tool is a function or executable capability that an MCP server exposes to a LLM or AI application to perform an action in the real world.
The gmailmcp.googleapis.com MCP server has the following tools:
| MCP Tools | |
|---|---|
| create_draft | Creates a new draft email in the authenticated user's Gmail account. This tool takes recipient addresses, a subject, and body content as inputs. It returns the ID of the created Gmail draft. |
| list_drafts | Lists draft emails from the authenticated user's Gmail account. This tool can filter drafts based on a query string and supports pagination. It returns a list of drafts, including their IDs and subjects. |
| get_thread | Retrieves a specific email thread from the authenticated user's Gmail account, including a list of its messages. |
| search_threads | Lists email threads from the authenticated user's Gmail account. This tool can filter threads based on a query string and supports pagination. It returns a list of threads, including their IDs and related messages. Each related message contains details like a snippet of the message body, the subject, the sender, the recipients etc. Note that the full message bodies are not returned by this tool; use the 'get_thread' tool with a thread ID to fetch the full message body if needed. |
| label_thread | Adds labels to an entire thread in the authenticated user's Gmail account. This operation affects all messages currently in the thread and any future messages added to it. If unsure of the thread ID, use the If unsure of a user label's ID, use the |
| unlabel_thread | Removes labels from an entire thread in the authenticated user's Gmail account. If unsure of the thread ID, use the search_threads
tool first. If unsure of a user label's ID, use the list_labels
tool first. |
| list_labels | Lists all user-defined labels available in the authenticated user's Gmail account. Use this tool to discover the id
of a user label before calling label_thread
, unlabel_thread
, label_message
, or unlabel_message
. System labels are not returned by this tool but can be used with their well-known IDs: 'INBOX', 'TRASH', 'SPAM', 'STARRED', 'UNREAD', 'IMPORTANT', 'CHAT', 'DRAFT', 'SENT'. |
| create_label | Creates a new label in the authenticated user's Gmail account. |
Get MCP tool specifications
To get the MCP tool specifications for all tools in an MCP server, use the tools/list
method. The following example demonstrates how to use curl
to list all tools and their specifications currently available within the MCP server.
| Curl Request |
|---|
curl --location 'https://gmailmcp.googleapis.com/mcp' \ --header 'content-type: application/json' \ --header 'accept: application/json, text/event-stream' \ --data '{ "method": "tools/list", "jsonrpc": "2.0", "id": 1 }' |

