Skip to main content
Glama
getplatform

GetMailer MCP Server

by getplatform

list_emails

Retrieve sent emails with delivery status and pagination support for monitoring transactional email performance.

Instructions

List sent emails with status information

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoNumber of emails to return (default: 20)
cursorNoPagination cursor for next page

Implementation Reference

  • Handler for the 'list_emails' tool that constructs query parameters from input arguments (limit and cursor), makes an API request to '/api/emails', and returns the result as formatted JSON text.
    case 'list_emails': {
      const params = new URLSearchParams();
      if (args?.limit) params.set('limit', String(args.limit));
      if (args?.cursor) params.set('cursor', String(args.cursor));
      const result = await apiRequest(`/api/emails?${params}`);
      return {
        content: [{ type: 'text' as const, text: JSON.stringify(result, null, 2) }],
      };
    }
  • Input schema defining optional parameters 'limit' (number) and 'cursor' (string) for the list_emails tool.
    inputSchema: {
      type: 'object' as const,
      properties: {
        limit: {
          type: 'number',
          description: 'Number of emails to return (default: 20)',
        },
        cursor: {
          type: 'string',
          description: 'Pagination cursor for next page',
        },
      },
    },
  • src/index.ts:119-135 (registration)
    Registration of the 'list_emails' tool in the tools list provided by the ListToolsRequestSchema handler, including name, description, and input schema.
    {
      name: 'list_emails',
      description: 'List sent emails with status information',
      inputSchema: {
        type: 'object' as const,
        properties: {
          limit: {
            type: 'number',
            description: 'Number of emails to return (default: 20)',
          },
          cursor: {
            type: 'string',
            description: 'Pagination cursor for next page',
          },
        },
      },
    },
Behavior2/5

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

No annotations are provided, so the description carries full burden. It mentions 'status information' but doesn't disclose behavioral traits like pagination behavior (implied by cursor parameter), rate limits, authentication needs, or what specific statuses are returned. For a list operation with no annotation coverage, this leaves significant gaps in understanding how the tool behaves.

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 a single, efficient sentence with zero waste. It's front-loaded with the core purpose and includes a clarifying detail ('with status information'). Every word earns its place, making it easy to parse quickly.

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?

Given the tool's moderate complexity (list operation with pagination), no annotations, and no output schema, the description is minimally adequate. It covers the basic purpose but lacks details on behavior, output format, or usage context. It meets the minimum viable threshold but has clear gaps in completeness for effective tool selection.

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?

Schema description coverage is 100%, so the schema already documents both parameters (limit and cursor) fully. The description doesn't add any parameter-specific meaning beyond what the schema provides, such as default behavior or usage examples. Baseline 3 is appropriate when the schema does the heavy lifting.

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 ('sent emails'), specifying scope with 'with status information'. It distinguishes from siblings like 'get_email' (singular) and 'send_email' (action), but doesn't explicitly differentiate from other list tools like 'list_batches' or 'list_templates'.

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?

No guidance on when to use this tool versus alternatives is provided. It doesn't mention prerequisites, context for listing sent emails specifically, or compare with siblings like 'get_email' for single emails or 'list_batches' for batch operations. The description only states what it does, not when to choose it.

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/getplatform/getmailer-mcp'

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