Get email analytics
get_analyticsEmail analytics for the workspace: sent, delivered, bounced, complained, opened, clicked, unsubscribed, conversions and revenue_cents as a zero filled time series (day buckets, hour buckets for ranges of two days or less), totals, rates (null when there is nothing to divide by) and a breakdown table. Counts are unique per recipient, bots ignored, counted when the event happened. Filter by range (7d, 30d, 90d, custom), type, source_id, step_id, provider and subscriber; group rows with by. availability says which sources exist: campaigns, sequences, conversions and segments are false until those features are set up, and their numbers are then zero. Errors: invalid_range, invalid_type, invalid_provider, invalid_subscriber, invalid_breakdown, segment_unavailable, insufficient_scope. Next: list_domains if sent is 0 and nothing has been sent yet.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_analytics"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| by | No | How to group the table: "source" (default), "type" or "provider". | |
| to | No | Last day for range=custom, YYYY-MM-DD (UTC, inclusive). At most 366 days in total. | |
| from | No | First day for range=custom, YYYY-MM-DD (UTC, inclusive). | |
| type | No | Send type: "transactional", "campaign" or "sequence". | |
| range | No | Date range: "7d", "30d" (default), "90d" or "custom" (then from and to are required). | |
| step_id | No | A sequence step or campaign email id, together with source_id. | |
| provider | No | Outbound provider: "ses", "kumo" or "unknown". | |
| source_id | No | A campaign or sequence id, to look at one send. | |
| subscriber | No | One subscriber's email address, or a segment id (seg_...). |