Skip to main content
Glama

get_send_as

Retrieve a specific send-as alias configuration from Gmail to verify or use alternative sender identities for email management.

Instructions

Gets the specified send-as alias

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sendAsEmailYesThe send-as alias to be retrieved

Implementation Reference

  • The handler function that executes the get_send_as tool logic. It uses handleTool to set up OAuth2 authentication and calls the Gmail API gmail.users.settings.sendAs.get to retrieve the specified send-as alias.
    async (params) => { return handleTool(config, async (gmail: gmail_v1.Gmail) => { const { data } = await gmail.users.settings.sendAs.get({ userId: 'me', sendAsEmail: params.sendAsEmail }) return formatResponse(data) }) } )
  • Input schema for the get_send_as tool, defining the required sendAsEmail parameter as a string.
    { sendAsEmail: z.string().describe("The send-as alias to be retrieved") },
  • src/index.ts:1144-1155 (registration)
    Registration of the get_send_as tool using server.tool(), including description, input schema, and handler function.
    server.tool("get_send_as", "Gets the specified send-as alias", { sendAsEmail: z.string().describe("The send-as alias to be retrieved") }, async (params) => { return handleTool(config, async (gmail: gmail_v1.Gmail) => { const { data } = await gmail.users.settings.sendAs.get({ userId: 'me', sendAsEmail: params.sendAsEmail }) return formatResponse(data) }) } )

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nk900600/gmail-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server