Skip to content

CSV Export

Data export in CSV format for external analysis. Requires supervisor role or above.

Endpoints

MethodEndpointDescriptionMinimum Role
GET/api/v1/export/calls.csvExport callssupervisor
GET/api/v1/export/customers.csvExport customerssupervisor
GET/api/v1/export/links.csvExport access linkssupervisor

Export Calls

Returns a CSV file with call data.

GET /api/v1/export/calls.csv

Query Parameters

ParameterTypeDefaultDescription
date_fromstring30 days agoStart date (ISO 8601)
date_tostringtodayEnd date (ISO 8601)
statusstring-Filter by status
department_iduuid-Filter by department

Request Example

bash
curl -X GET "https://voki.avanter.com.br/api/v1/export/calls.csv?date_from=2026-02-01&date_to=2026-02-18" \
  -H "Authorization: Bearer eyJhbGci..." \
  -H "X-Tenant: avanter" \
  -o calls.csv

Response

Returns Content-Type: text/csv with the file:

csv
id,status,department,attendant,customer_name,customer_email,duration,wait_time,rating,started_at,completed_at
1a2b3c4d-5e6f-7890-abcd-ef1234567890,completed,Suporte Técnico,João Silva,Carlos Ferreira,carlos@email.com,345,12,5,2026-02-15T14:30:00Z,2026-02-15T14:35:45Z

Export Customers

GET /api/v1/export/customers.csv

Request Example

bash
curl -X GET "https://voki.avanter.com.br/api/v1/export/customers.csv" \
  -H "Authorization: Bearer eyJhbGci..." \
  -H "X-Tenant: avanter" \
  -o customers.csv

Response

csv
id,name,email,phone,document,call_count,last_call_at,created_at
2a3b4c5d-6e7f-8901-bcde-f23456789012,Carlos Ferreira,carlos@email.com,+5511999998888,123.456.789-00,5,2026-02-15T14:30:00Z,2026-01-10T09:00:00Z

GET /api/v1/export/links.csv

Query Parameters

ParameterTypeDefaultDescription
statusstring-Filter by status (active, used, expired, cancelled)
department_iduuid-Filter by department

Request Example

bash
curl -X GET "https://voki.avanter.com.br/api/v1/export/links.csv?status=used" \
  -H "Authorization: Bearer eyJhbGci..." \
  -H "X-Tenant: avanter" \
  -o links.csv

Response

csv
id,token,status,department,customer_name,customer_email,expires_at,used_at,created_at
6e7f8a9b-0c1d-2345-fghi-678901234567,abc123def456,used,Suporte Técnico,Carlos Ferreira,carlos@email.com,2026-02-25T23:59:59Z,2026-02-20T10:15:00Z,2026-02-18T10:00:00Z

Documentação da API Voki v4.0