Collect customer satisfaction on resolved tickets. Requires a Bearer token (see Tickets Overview).
Rate a ticket
POST /tickets/ratings/{ticket_id}
Submits a satisfaction rating once a ticket is Accepted or Declined. A ticket can only be rated once — rating an already-rated ticket returns 422.
Path parameters
| Param | Type | Required | Description |
|---|---|---|---|
ticket_id | integer | yes | The ticket ID. |
Body
| Prop | Type | Required | Description |
|---|---|---|---|
rating | integer — 1 to 5 | yes | Satisfaction score. |
comment | string (nullable) | optional | Optional free-text feedback. |
curl --request POST \
--url https://queries.envia.com/tickets/ratings/987654 \
--header 'Authorization: Bearer YOUR_API_TOKEN' \
--header 'Content-Type: application/json' \
--data '{ "rating": 5, "comment": "Fast and helpful resolution." }'Response 200
{ "data": true, "message": "Successful." }