Get Warmup Analytics
Fetch current warmup analytics and auto-apply status transitions for every warming/warmed/active inbox.
Overview
Separated fromGET /api/email/accounts so the UI can render the account list immediately and lazy-load the slower warmup data without blocking the page. Two things happen in one pass:
- Analytics fetch. For every account with
warmup_status ∈ {warming, warmed, active}and a setemail_address, we pulltotal_sent,total_received,health_score,warmup_reputation(0–100), anddaily_datafrom the warmup provider. Fetches are serialised to avoid provider rate limits. - Auto-transitions. Two transitions are applied inline and reflected in the
transitionsmap:- Ban / suspend: if the provider warmup status is
-1(banned),-2(spam unknown), or-3(suspended), we set ourwarmup_statustobanned/suspendedandstatustoerror. - Graduate: if a
warmingaccount haswarmup_reputation ≥ 90ANDtotal_sent ≥ 200, we flip bothwarmup_statusandstatustoactive.
- Ban / suspend: if the provider warmup status is
AI agent notes
warmup_reputation climbs slowly and the daily counts update incrementally. Expect graduation (warming → active) in roughly 2–3 weeks for a new inbox, not hours. Polling this endpoint more than once every few minutes is wasteful.Reading the response:analyticsis keyed byaccounts.id— not by email address.- Accounts that failed their warmup analytics fetch are silently omitted from
analytics. Check the account list for which IDs you expected. transitionsis a diff, not a snapshot. It only contains entries for rows that changed status on this call — empty object{}means nothing flipped.
status: "active", not warmup_status. An active account is send-eligible; a warming account blocks campaign emails.When an account turns banned: alert the user. There is no retry path — the user must create a new email address on the same domain (or a new domain).Chains with: retryAccountWarmup for stalled pending accounts, launchCampaign once all senders are active.Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Response
Per-account warmup analytics plus any status transitions applied on this call.
Map of accounts.id → analytics payload. Only accounts with warmup_status ∈ {warming, warmed, active} and a set email_address are included. Accounts that failed to fetch because of a warmup-provider error are silently omitted.
Map of accounts.id → the status change applied during this call. Present only when a graduation or ban/suspend actually flipped the row — empty object {} if nothing changed. Use this to refresh UI state without re-reading accounts.