Skip to main content
Glama

delete_filter

Remove unwanted Gmail filters by specifying their ID to clean up your email organization rules.

Instructions

Deletes a filter

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe ID of the filter to be deleted

Implementation Reference

  • Handler function executes the deletion of a Gmail filter by ID using the Gmail API.
    async (params) => { return handleTool(config, async (gmail: gmail_v1.Gmail) => { const { data } = await gmail.users.settings.filters.delete({ userId: 'me', id: params.id }) return formatResponse(data) }) }
  • Zod schema defining the input parameter 'id' for the filter to delete.
    { id: z.string().describe("The ID of the filter to be deleted") },
  • src/index.ts:1026-1037 (registration)
    Tool registration for 'delete_filter' with description, schema, and handler.
    server.tool("delete_filter", "Deletes a filter", { id: z.string().describe("The ID of the filter to be deleted") }, async (params) => { return handleTool(config, async (gmail: gmail_v1.Gmail) => { const { data } = await gmail.users.settings.filters.delete({ userId: 'me', id: params.id }) 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