remove_delegate
Remove a delegate from your Gmail account to revoke their access to manage your emails and settings.
Instructions
Removes the specified delegate
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| delegateEmail | Yes | Email address of delegate to remove |
Implementation Reference
- src/index.ts:947-952 (handler)Handler function that executes the tool logic by calling the Gmail API to delete the specified delegate using the provided delegateEmail.async (params) => { return handleTool(config, async (gmail: gmail_v1.Gmail) => { const { data } = await gmail.users.settings.delegates.delete({ userId: 'me', delegateEmail: params.delegateEmail }) return formatResponse(data) }) }
- src/index.ts:944-946 (schema)Input schema for the remove_delegate tool, validating the delegateEmail parameter.{ delegateEmail: z.string().describe("Email address of delegate to remove") },
- src/index.ts:942-953 (registration)Registration of the 'remove_delegate' tool on the MCP server, including description, schema, and handler.server.tool("remove_delegate", "Removes the specified delegate", { delegateEmail: z.string().describe("Email address of delegate to remove") }, async (params) => { return handleTool(config, async (gmail: gmail_v1.Gmail) => { const { data } = await gmail.users.settings.delegates.delete({ userId: 'me', delegateEmail: params.delegateEmail }) return formatResponse(data) }) } )