Skip to main content
Glama
deyikong

SendGrid MCP Server

by deyikong

delete_sender

Remove a verified sender identity from your SendGrid account to manage authorized email senders and maintain sender reputation.

Instructions

Delete a verified sender identity

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sender_idYesID of the sender identity to delete

Implementation Reference

  • The handler function for the 'delete_sender' tool. It checks read-only mode, then sends a DELETE request to SendGrid's verified_senders endpoint to delete the specified sender identity.
    handler: async ({ sender_id }: { sender_id: string }): Promise<ToolResult> => { const readOnlyCheck = checkReadOnlyMode(); if (readOnlyCheck.blocked) { return { content: [{ type: "text", text: readOnlyCheck.message! }] }; } const result = await makeRequest(`https://api.sendgrid.com/v3/verified_senders/${sender_id}`, { method: "DELETE", }); return { content: [{ type: "text", text: `Sender identity ${sender_id} deleted successfully.` }] }; },
  • The tool's configuration, including title, description, and input schema defining the 'sender_id' parameter with Zod validation.
    config: { title: "Delete Sender Identity", description: "Delete a verified sender identity", inputSchema: { sender_id: z.string().describe("ID of the sender identity to delete"), }, },
  • The 'delete_sender' tool definition object, exported as part of contactTools, which is included in allTools and registered via MCP server.registerTool in src/index.ts.
    delete_sender: { config: { title: "Delete Sender Identity", description: "Delete a verified sender identity", inputSchema: { sender_id: z.string().describe("ID of the sender identity to delete"), }, }, handler: async ({ sender_id }: { sender_id: string }): Promise<ToolResult> => { const readOnlyCheck = checkReadOnlyMode(); if (readOnlyCheck.blocked) { return { content: [{ type: "text", text: readOnlyCheck.message! }] }; } const result = await makeRequest(`https://api.sendgrid.com/v3/verified_senders/${sender_id}`, { method: "DELETE", }); return { content: [{ type: "text", text: `Sender identity ${sender_id} deleted successfully.` }] }; }, },

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/deyikong/sendgrid-mcp'

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