Pular para o conteúdo
CognizyCognizyAjuda
Entrar
Nesta área

Campaigns

Read campaigns and their analytics.

List campaigns

get/v1/public/campaigns

Paginated list of campaigns in the organization. Filter by status or channel. Returns data (with template name) + meta.{total,page,limit,totalPages}.

Parâmetros

limitnumberopcional· consulta
Range 1–100
pagenumberopcional· consulta
channelWEB_CHAT | WHATSAPP | EMAIL | INSTAGRAM | MESSENGER | APIopcional· consulta
statusDRAFT | SCHEDULED | RUNNING | COMPLETED | CANCELLEDopcional· consulta

Respostas

  • 200

Exemplos

bash
curl -X GET "https://api.cognizy.ai/api/v1/public/campaigns" \
  -H "Authorization: Bearer $COGNIZY_API_KEY"

Get a campaign

get/v1/public/campaigns/{id}

Returns the campaign with template, segment, handoff department, and all the denormalized counters (sent, replied, opened, etc).

Parâmetros

idstringobrigatório· caminho
Campaign ID

Respostas

  • 200Campaign returned
  • 404Campaign not found

Exemplos

bash
curl -X GET "https://api.cognizy.ai/api/v1/public/campaigns/<id>" \
  -H "Authorization: Bearer $COGNIZY_API_KEY"

Get campaign analytics

get/v1/public/campaigns/{id}/analytics

Returns totals (sent, failed, replied, qualified, booked, opted-out, email deliverability) plus a bucketed time series of conversations spawned by this campaign. Use for A/B test analysis and engagement over time.

Parâmetros

idstringobrigatório· caminho
Campaign ID
granularityhour | day | weekopcional· consulta
Default day

Respostas

  • 200Campaign analytics returned
  • 404Campaign not found

Exemplos

bash
curl -X GET "https://api.cognizy.ai/api/v1/public/campaigns/<id>/analytics" \
  -H "Authorization: Bearer $COGNIZY_API_KEY"

Toda a referência