Skip to main content
Glama
deyikong

SendGrid MCP Server

by deyikong

Create Sender

create_sender

Create a new sender identity in SendGrid by specifying email addresses, names, and physical address details for email authentication.

Instructions

Create a new sender identity

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nicknameYesNickname for the sender
fromYes
reply_toYes
addressYesStreet address
cityYesCity
stateYesState
zipYesZIP code
countryYesCountry

Implementation Reference

  • The main handler function for the 'create_sender' tool. It checks read-only mode, then makes a POST request to SendGrid API to create a new sender identity, and returns a success message with verification note.
    handler: async (senderData: any): Promise<ToolResult> => {
      const readOnlyCheck = checkReadOnlyMode();
      if (readOnlyCheck.blocked) {
        return { content: [{ type: "text", text: readOnlyCheck.message! }] };
      }
      
      const result = await makeRequest("https://api.sendgrid.com/v3/marketing/senders", {
        method: "POST",
        body: JSON.stringify(senderData),
      });
      return {
        content: [
          {
            type: "text",
            text: `Sender created successfully. ${JSON.stringify(result, null, 2)}\n\nIMPORTANT: Please verify the sender email address if the email's domain is not in the Sender Authentication settings.`,
          },
        ],
      };
    },
  • Zod schema defining the input parameters for the create_sender tool, including sender details like nickname, from/reply_to emails, and address information.
      inputSchema: {
        nickname: z.string().describe("Nickname for the sender"),
        from: z.object({
          email: z.string().describe("From email address"),
          name: z.string().describe("From name"),
        }),
        reply_to: z.object({
          email: z.string().describe("Reply-to email address"),
          name: z.string().describe("Reply-to name"),
        }),
        address: z.string().describe("Street address"),
        city: z.string().describe("City"),
        state: z.string().describe("State"),
        zip: z.string().describe("ZIP code"),
        country: z.string().describe("Country"),
      },
    },
  • src/index.ts:21-23 (registration)
    Generic registration loop that registers the 'create_sender' tool (from allTools) with the MCP server using its config and handler.
    for (const [name, tool] of Object.entries(allTools)) {
      server.registerTool(name, tool.config as any, tool.handler as any);
    }
  • Combines contactTools (containing create_sender) into allTools, which is then imported and registered in src/index.ts.
    export const allTools = {
      ...automationTools,
      ...campaignTools,
      ...contactTools,
      ...mailTools,
      ...miscTools,
      ...statsTools,
      ...templateTools,
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden for behavioral disclosure. 'Create a new sender identity' implies a write operation but provides no information about permissions required, whether this operation is idempotent, what happens on duplicate creation, rate limits, or what the response contains. This is inadequate for a mutation tool with zero annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is extremely concise at just 4 words, front-loading the essential information with zero wasted words. Every word earns its place by specifying the action and target resource.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with 8 required parameters, no annotations, and no output schema, the description is insufficient. It doesn't explain what a 'sender identity' is, why it's needed, what happens after creation, or provide any context about the operation's behavior. The agent would struggle to use this tool effectively.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds no parameter information beyond what's in the schema. With 75% schema description coverage, the schema already documents most parameters well. The description doesn't explain why certain fields are required or provide context about parameter relationships, so it meets the baseline for decent schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('Create') and resource ('sender identity'), making the purpose immediately understandable. It doesn't differentiate from siblings like 'create_contact' or 'create_email_list', but it's specific enough to identify what type of entity is being created.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. With many sibling tools for creating different entities (contacts, templates, lists, etc.), there's no indication of what a 'sender identity' is used for or when it's appropriate to create one instead of other entities.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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