Skip to main content
Glama
AgentX-ai

Mailchimp MCP Server

by AgentX-ai

get_campaign_report

Retrieve detailed analytics and performance data for a specific Mailchimp email campaign to track opens, clicks, and engagement metrics.

Instructions

Get detailed report for a specific campaign

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
campaign_idYesThe campaign ID

Implementation Reference

  • The tool handler logic within the handleToolCall function that invokes the Mailchimp service's getCampaignReport method, processes the result, and returns a formatted text response.
    case "get_campaign_report": const campaignReport = await service.getCampaignReport(args.campaign_id); return { content: [ { type: "text", text: JSON.stringify(campaignReport, null, 2), }, ], };
  • Input schema definition for the get_campaign_report tool, specifying an object with a required string campaign_id property.
    inputSchema: { type: "object", properties: { campaign_id: { type: "string", description: "The campaign ID", }, }, required: ["campaign_id"], },
  • Registration of the get_campaign_report tool in the getToolDefinitions array, including name, description, and input schema.
    { name: "get_campaign_report", description: "Get detailed report for a specific campaign", inputSchema: { type: "object", properties: { campaign_id: { type: "string", description: "The campaign ID", }, }, required: ["campaign_id"], }, },
  • Core helper method in MailchimpService that performs the API request to retrieve the campaign report from Mailchimp's /reports/{campaignId} endpoint.
    async getCampaignReport( campaignId: string ): Promise<MailchimpCampaignReport> { return await this.makeRequest(`/reports/${campaignId}`); }

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

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