Skip to main content
Glama
deyikong

SendGrid MCP Server

by deyikong

List Single Send Campaigns

list_single_sends

Retrieve and manage all single send email campaigns from SendGrid to review, analyze, or organize your marketing communications.

Instructions

List all single send campaigns

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
page_sizeNoNumber of results to return

Implementation Reference

  • The handler function that executes the list_single_sends tool logic by querying the SendGrid API for single send campaigns.
    handler: async ({ page_size }: { page_size: number }): Promise<ToolResult> => {
      const result = await makeRequest(`https://api.sendgrid.com/v3/marketing/singlesends/search?page_size=${page_size}`);
      return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
    },
  • The tool configuration including input schema using Zod for validation.
    config: {
      title: "List Single Send Campaigns",
      description: "List all single send campaigns",
      inputSchema: {
        page_size: z.number().optional().default(50).describe("Number of results to return"),
      },
    },
  • src/index.ts:21-23 (registration)
    Registration of all tools, including 'list_single_sends', via loop over allTools object.
    for (const [name, tool] of Object.entries(allTools)) {
      server.registerTool(name, tool.config as any, tool.handler as any);
    }
  • Import and inclusion of campaignTools (containing list_single_sends) into the allTools export.
    import { campaignTools } from "./campaigns.js";
    import { contactTools } from "./contacts.js";
    import { mailTools } from "./mail.js";
    import { miscTools } from "./misc.js";
    import { statsTools } from "./stats.js";
    import { templateTools } from "./templates.js";
    
    export const allTools = {
      ...automationTools,
      ...campaignTools,
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. While 'List' implies a read-only operation, the description doesn't mention pagination behavior (despite the page_size parameter), rate limits, authentication requirements, or what format the results will be in. For a tool with no annotation coverage, this leaves significant behavioral gaps.

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 perfectly concise - a single sentence that states exactly what the tool does with zero wasted words. It's front-loaded with the core functionality and doesn't include any unnecessary information.

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

Completeness3/5

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

For a simple listing tool with one optional parameter and no output schema, the description is minimally adequate. However, without annotations or output schema, it should ideally mention something about the return format or pagination behavior. The description covers the basic purpose but leaves operational details unspecified.

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 schema description coverage is 100%, with the single parameter (page_size) fully documented in the schema. The description doesn't add any parameter information beyond what's already in the schema, which is acceptable given the high schema coverage. The baseline score of 3 reflects adequate but not enhanced parameter documentation.

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 ('List') and resource ('all single send campaigns'), making the purpose immediately understandable. However, it doesn't distinguish this tool from other list tools on the server (like list_automations, list_contacts, etc.), which would require mentioning what makes single send campaigns unique.

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 sibling tools like list_automations, list_templates, and open_single_send_stats available, there's no indication of when this specific listing tool is appropriate versus other listing or viewing tools.

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