Skip to main content

Sequence Stats

These tools surface email performance data at two scopes: a specific ai-email step within one sequence (get_sequence_stats, get_sequence_events), or all sequences in a funnel rolled up together (get_funnel_stats, get_funnel_events). Use the stats tools for aggregate KPIs (delivery rates, open rates) and the event tools for per-contact event records with cursor-based pagination.

Step IDs (messageId) come from get_sequence — use the id field on an ai-email step.

Tools

ToolPurposeKey inputsReturns
get_sequence_statsAggregated email KPIs for a specific ai-email stepfunnelId, sequenceId, messageIdStat buckets: scheduled, sent, delivered, opened, failed, canceled
get_sequence_eventsPaginated event log for one event type on a specific stepfunnelId, sequenceId, messageId, eventTypeEvent records + cursor pagination meta
get_funnel_statsAggregated email KPIs across all sequences in a funnelfunnelIdStat buckets: sent, delivered, opened, failed
get_funnel_eventsPaginated event log for one event type across all funnel sequencesfunnelId, eventTypeEvent records + cursor pagination meta

get_sequence_stats inputs

NameTypeRequiredDescription
funnelIdstringYesFunnel ID — 24-character hex string
sequenceIdstringYesSequence ID
messageIdstringYesai-email step ID from get_sequence
searchstringNoOptional search filter
dateFromstringNoISO 8601 timestamp (e.g. 2026-04-01T00:00:00Z)
dateTostringNoISO 8601 timestamp

get_sequence_events inputs

NameTypeRequiredDescription
funnelIdstringYesFunnel ID
sequenceIdstringYesSequence ID
messageIdstringYesai-email step ID
eventTypestring (enum)YesOne of: scheduled, sent, delivered, opened, failed, canceled
cursorstringNoPagination cursor from the previous response
limitnumberNoResults per page, 1–100; default 50
searchstringNoOptional search filter
dateFromstringNoISO 8601 timestamp
dateTostringNoISO 8601 timestamp

get_funnel_stats inputs

NameTypeRequiredDescription
funnelIdstringYesFunnel ID — 24-character hex string
messageIdstringNoOptional ai-email step ID to scope to a single message
searchstringNoOptional search filter
dateFromstringNoISO 8601 timestamp
dateTostringNoISO 8601 timestamp

get_funnel_events inputs

NameTypeRequiredDescription
funnelIdstringYesFunnel ID — 24-character hex string
eventTypestring (enum)YesOne of: scheduled, sent, delivered, opened, failed, canceled
messageIdstringNoOptional ai-email step ID to scope
cursorstringNoPagination cursor from the previous response
limitnumberNoResults per page, 1–100; default 50
searchstringNoOptional search filter
dateFromstringNoISO 8601 timestamp
dateTostringNoISO 8601 timestamp

Stat bucket shapes:

  • count bucket (scheduled, sent): { count: number }
  • rate bucket (delivered, opened, failed, canceled): { count: number, rate: number }rate is a fraction of sent (0..1).

Event records contain: id, status, email, date, sequenceId, messageId.

Cursor pagination: pass meta.nextCursor back as cursor on the next call. meta.hasMore is false on the last page.