Skip to main content
Glama

list_campaigns

Retrieve email campaigns from Mailchimp, filtered by status or audience list ID, to review campaign details and performance data.

Instructions

List email campaigns. Filter by status (save, paused, schedule, sending, sent) or audience list_id.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
statusNo
list_idNo
countNo
offsetNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The list_campaigns tool handler — an async function decorated with @mcp.tool() that calls the Mailchimp API GET /campaigns, formats campaign results, and returns them as indented JSON. Accepts optional filters: status, list_id, count, offset.
    @mcp.tool()
    async def list_campaigns(
        status: str = "",
        list_id: str = "",
        count: int = 20,
        offset: int = 0,
    ) -> str:
        """List email campaigns. Filter by status (save, paused, schedule, sending, sent) or audience list_id."""
        mc = get_client()
        params: dict[str, Any] = {"count": min(count, 100), "offset": offset}
        if status:
            params["status"] = status
        if list_id:
            params["list_id"] = list_id
        data = await mc.get("/campaigns", params=params)
        campaigns = []
        for c in data.get("campaigns", []):
            s = c.get("settings", {})
            campaigns.append({
                "id": c["id"],
                "title": s.get("title", ""),
                "subject_line": s.get("subject_line", ""),
                "status": c.get("status", ""),
                "type": c.get("type", ""),
                "send_time": c.get("send_time"),
                "emails_sent": c.get("emails_sent", 0),
            })
        return _fmt({"total_items": data.get("total_items", 0), "campaigns": campaigns})
  • Registration using the @mcp.tool() decorator on the list_campaigns function, which registers it with the FastMCP server instance.
    @mcp.tool()
Behavior2/5

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

No annotations provided, so description must disclose behavioral traits. Only mentions filtering, but omits pagination behavior (count/offset), rate limits, or whether results are ordered. Lacks transparency for a list endpoint.

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

Conciseness4/5

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

Single sentence is concise and front-loaded with the main action. However, it could be structured with separate sections for clarity and to include missing info.

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?

Despite having an output schema, the description lacks details on pagination, default ordering, maximum results, and status enum completeness. Minimal for a complex list tool with many sibling tools.

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 coverage is 0%, so description adds value by explaining status (with example values) and list_id. However, it ignores count and offset parameters entirely, leaving 2 parameters undocumented. Only partial compensation.

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

Purpose5/5

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

Clearly states 'List email campaigns' with specific verb and resource. Differentiates from siblings like get_campaign (single) and by mentioning filtering by status or list_id.

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 vs. alternatives like get_campaign, search_members, or create_campaign. Does not specify prerequisites or exclusions.

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/AlexlaGuardia/mcp-mailchimp'

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