get_click_report
Analyze campaign click performance by retrieving which URLs were clicked and total click counts for each link.
Instructions
Get click details for a campaign — which URLs were clicked and how many times.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| campaign_id | Yes | ||
| count | No |
Implementation Reference
- mcp_mailchimp/server.py:327-344 (handler)The `get_click_report` tool handler retrieves click details for a specified Mailchimp campaign, including URL-specific click stats, and formats the result.
@mcp.tool() async def get_click_report(campaign_id: str, count: int = 20) -> str: """Get click details for a campaign — which URLs were clicked and how many times.""" mc = get_client() data = await mc.get( f"/reports/{campaign_id}/click-details", params={"count": min(count, 100)}, ) urls = [] for u in data.get("urls_clicked", []): urls.append({ "url": u.get("url", ""), "total_clicks": u.get("total_clicks", 0), "unique_clicks": u.get("unique_clicks", 0), "click_percentage": u.get("click_percentage", 0), "last_click": u.get("last_click", ""), }) return _fmt({"campaign_id": campaign_id, "total_urls": len(urls), "urls": urls})