Skip to content

Evaluations

Management of call evaluations submitted by customers. Requires attendant role or above.

Endpoints

MethodEndpointDescriptionMinimum Role
GET/api/v1/evaluationsList evaluationsattendant
GET/api/v1/evaluations/:idGet evaluationattendant
POST/api/v1/evaluationsCreate evaluation (internal)attendant
GET/api/v1/evaluations/statsEvaluation statisticsattendant

Note

Evaluations are normally created by the customer at the end of the call via the public endpoint (POST /api/v1/call/evaluate/:call_id). The authenticated endpoint allows manual creation by agents.


List Evaluations

GET /api/v1/evaluations

Query Parameters

ParameterTypeDefaultDescription
pageinteger1Page number
page_sizeinteger20Items per page
sort_bystringinserted_atSort field
sort_orderstringdescSort direction
ratinginteger-Filter by rating (1-5)
date_fromstring-Start date
date_tostring-End date

Request Example

bash
curl -X GET "https://voki.avanter.com.br/api/v1/evaluations?page=1&page_size=10" \
  -H "Authorization: Bearer eyJhbGci..." \
  -H "X-Tenant: avanter"

Success Response (200)

json
{
  "data": [
    {
      "id": "ev1a2b3c-d4e5-6789-abcd-ef1234567890",
      "call_id": "1a2b3c4d-5e6f-7890-abcd-ef1234567890",
      "rating": 5,
      "comment": "Excelente atendimento!",
      "customer_name": "Carlos Ferreira",
      "user_name": "João Silva",
      "department_name": "Suporte Técnico",
      "inserted_at": "2026-02-15T14:40:00Z"
    }
  ],
  "meta": {
    "current_page": 1,
    "page_size": 10,
    "total_pages": 5,
    "total_count": 48
  }
}

Evaluation Statistics

GET /api/v1/evaluations/stats

Query Parameters

ParameterTypeDefaultDescription
date_fromstring30 days agoStart date
date_tostringtodayEnd date
department_iduuid-Filter by department
user_iduuid-Filter by agent

Request Example

bash
curl -X GET "https://voki.avanter.com.br/api/v1/evaluations/stats" \
  -H "Authorization: Bearer eyJhbGci..." \
  -H "X-Tenant: avanter"

Success Response (200)

json
{
  "data": {
    "total_evaluations": 48,
    "average_rating": 4.6,
    "distribution": {
      "1": 1,
      "2": 2,
      "3": 3,
      "4": 12,
      "5": 30
    },
    "with_comments": 35,
    "satisfaction_rate": 87.5
  }
}

Create Evaluation

POST /api/v1/evaluations

Request Body

FieldTypeRequiredDescription
call_iduuidYesCall ID
ratingintegerYesRating from 1 to 5
commentstringNoCustomer comment

Request Example

bash
curl -X POST https://voki.avanter.com.br/api/v1/evaluations \
  -H "Authorization: Bearer eyJhbGci..." \
  -H "X-Tenant: avanter" \
  -H "Content-Type: application/json" \
  -d '{
    "evaluation": {
      "call_id": "1a2b3c4d-5e6f-7890-abcd-ef1234567890",
      "rating": 5,
      "comment": "Excellent service"
    }
  }'

Success Response (201)

json
{
  "data": {
    "id": "ev2b3c4d-e5f6-7890-bcde-f23456789012",
    "call_id": "1a2b3c4d-5e6f-7890-abcd-ef1234567890",
    "rating": 5,
    "comment": "Excellent service",
    "inserted_at": "2026-02-18T18:00:00Z"
  }
}

Documentação da API Voki v4.0