Relatório de campanhas

GET
/v1/reports/campaigns

Campanhas: enviadas, entregues, lidas e respondidas, por campanha. period é today, 7d, 30d (padrão), 90d ou custom com from e to.

Escopo: campaigns:read

Autorização

bearer campaigns:read
headerAutorizaçãoBearer <token>

A chave de API de uma conta de serviço (sk_live_…, 600 requisições por minuto cada) ou um access token OAuth para o recurso /api/v1 (600 requisições por minuto por conexão).

Escopo: campaigns:read

period?string
Valor em"today""7d""30d""90d""custom"
from?string

YYYY-MM-DD, with period custom.

Padrão^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
Formatodate
to?string

YYYY-MM-DD, with period custom.

Padrão^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))$
Formatodate
number?string

A number's id, from list_numbers.

Tamanho1 <= length <= 100
team?string

A team's id, from list_teams.

Tamanho1 <= length <= 100
agent?string

A member's id, from list_members.

Tamanho1 <= length <= 100
automation?string
Tamanho1 <= length <= 100
campaign?string
Tamanho1 <= length <= 100
pipeline?string
Tamanho1 <= length <= 100
origin?string
Valor em"direct""form""import""campaign""team"

Corpo da resposta

Feito.

application/json
  1. response
workspace*string
range*
now*string
Formatodate-time
time_zone*string
sent*integer
Intervalo-9007199254740991 <= value <= 9007199254740991
delivered*integer
Intervalo-9007199254740991 <= value <= 9007199254740991
read*integer
Intervalo-9007199254740991 <= value <= 9007199254740991
replied*integer
Intervalo-9007199254740991 <= value <= 9007199254740991
left*integer
Intervalo-9007199254740991 <= value <= 9007199254740991
change*number|null
series*integer
Intervalo-9007199254740991 <= value <= 9007199254740991
days*array<>
campaigns*array<>
Exemplo de requisição
curl -X GET 'https://app.zaplin.com.br/api/v1/reports/campaigns' \  -H 'Authorization: Bearer sk_live_...'
Exemplo de resposta
{  "workspace": "string",  "range": {    "from": "2026-10-17",    "to": "2026-10-17",    "days": 0,    "previous": {      "from": "2026-10-17",      "to": "2026-10-17"    }  },  "now": "2026-10-17T12:00:00.000Z",  "time_zone": "string",  "sent": 0,  "delivered": 0,  "read": 0,  "replied": 0,  "left": 0,  "change": 0,  "series": 0,  "days": [    {      "day": "2026-10-17",      "sent": 0,      "read": 0    }  ],  "campaigns": [    {      "id": "string",      "name": "string",      "recurring": false,      "sent": 0,      "delivered": 0,      "read": 0,      "replied": 0,      "left": 0    }  ]}