Pular para o conteúdo
Won.dev
DocumentaçãoReferência da API
API de cold mail

Listar eventos

O que aconteceu desde a última vez que você perguntou: respostas, bounces, descadastros, campanhas começando e terminando. Grátis.

O que aconteceu desde a última vez que você perguntou, do mais antigo para o mais recente: chegou uma resposta, um e-mail deu bounce, uma campanha terminou. É assim que você acompanha tudo sem webhook: chame com o next_cursor da chamada anterior como cursor e receba exatamente o que é novo, cada evento uma vez. Diferente de outras listas, next_cursor vem também na última página, e não expira enquanto o evento estiver guardado. Um data vazio significa que nada aconteceu; pergunte de novo em alguns minutos. Os eventos ficam guardados por 30 dias. Tipos: sender.approved, sender.rejected, sender.suspended, domain.ready, domain.failed, domain.renewal_upcoming, domain.renewal_failed, domain.released, campaign.started, campaign.paused, campaign.resumed, campaign.completed, campaign.canceled, email.sent, email.opened, email.clicked, email.bounced, reply.received, recipient.unsubscribed, task.completed. Grátis.

  • Cobrança: Grátis.

Uma chave de teste (won_test_...) roda isto no sandbox: nada é enviado e nada é cobrado.

GET
/events

Autenticação

apiKey
headerAuthorizationBearer <chave de API>

Authorization: Bearer won_live_..., a key from the console.

Parâmetros de consulta

cursor?string

Only events after the previous call: its next_cursor, passed back unchanged.

Tamanholength <= 40
since?string

Only events after this ISO 8601 time, such as 2026-11-20T13:41:02Z. For the first call, when there is no cursor yet.

Tamanholength <= 40
types?array<>

Only these types, such as reply.received,email.bounced. Default: all.

Itensitems <= 20
Padrão[]
campaign_id?string

Only events of this campaign.

Tamanholength <= 40
sender_id?string

Only events of this sender: of its campaigns and their emails, and of the sender and its domains.

Tamanholength <= 40
limit?integer

How many to return, 1 to 100.

Intervalo1 <= value <= 100
Padrão50

Corpo da resposta

The result.

application/json
  1. response
data*array<>

The events, oldest first.

has_more*boolean

Whether more are waiting. Call again with next_cursor to get them.

next_cursor*|

Pass it as cursor in the next call, now or later. When data is empty it is the cursor you sent, so it can always be passed on. Null only when the call had no cursor and found no events: call again with since.

notice*|

A plain sentence when there is something to know about this answer. Null otherwise.

usage*

Nothing is charged here. The balance, for reference.

Requisição de exemplo
curl -X GET 'https://api.won.dev/v1/events?types=reply.received&limit=1'
Resposta de exemplo
{  "data": [    {      "id": "evt_5r4k2m9x7p1q8w3e",      "type": "reply.received",      "created_at": "2026-11-20T13:44:10.000Z",      "campaign_id": "cmp_7p1q8w3e5r4k2m9x",      "sender_id": "snd_4k2m9x7p1q8w3e5r",      "test": false,      "metadata": {        "customer_id": "c_812",        "crm_id": "lead_4471"      },      "data": {        "reply_id": "rpl_1q8w3e5r4k2m9x7p",        "recipient_id": "rcp_9x7p1q8w3e5r4k2m",        "email": "dana.whitfield@harborline-imports.example",        "from_email": "dana.whitfield@harborline-imports.example",        "subject": "Re: Office chairs for Harborline Imports",        "text": "Hi, yes, please send the price list. We are reviewing suppliers for next quarter.",        "intent": "interested",        "confidence": 0.7,        "automated": false,        "has_attachments": false      }    }  ],  "has_more": false,  "next_cursor": "evt_5r4k2m9x7p1q8w3e",  "notice": null,  "usage": {    "cost": 0,    "balance": 48.08,    "replayed": false  }}

Última atualização em