Get email stats
Opens, click-throughs, bounces and clicks per link for one email.
GET https://cotlet.dev/api/v1/mautic/emails/{email_id}/stats
read
Returns what the email Email overview and its Click Counts tab show. Opens come from a tracking pixel, which Mautic itself calls not very accurate. Clicks are not counted for the Send Example link, direct sends from a contact profile or form preview emails. Bounces show only when bounce detection is set up in Mautic.
Parameters
| Name | Type | Description |
|---|---|---|
| email_id integer required | integer | Email ID from list_emails. |
Request
curl https://cotlet.dev/api/v1/mautic/emails/58/stats \
-H "Authorization: Bearer $COTLET_API_KEY" result = client.call("mautic", "get_email_stats", {"email_id":58}) const result = await cotlet.call('mautic', 'get_email_stats', {"email_id":58}); cotlet call mautic get_email_stats --data '{"email_id":58}' Example response
{
"email_id": 58,
"name": "October newsletter",
"opens": 614,
"click_throughs": 87,
"bounces": 9,
"clicks_by_link": [
{
"url": "https://example.com/webinar",
"clicks": 52
},
{
"url": "https://example.com/pricing",
"clicks": 35
}
]
}