Pular para o conteúdo

POST /v1/analytics/csat/search

POST
/v1/analytics/csat/search
curl --request POST \
--url https://seu-endereco-da-api/v1/analytics/csat/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "window": "current", "period": "7", "filter": {} }'

Permissão que a Chave de acesso precisa: Relatórios de atendimento (analytics:service).

Media typeapplication/json
object
window
string
Allowed values: current previous
period
string
Allowed values: 7 30 90
filter
object
key
additional properties
any
Media typeapplication/json
object
period
required
string
Allowed values: 7 30 90
seriesBreakAt
required
string
nullable
windowStart
required

First instant the report counts, so a list drawn from a wider window can be cut to the same answers

string format: date-time
nullable
kpis
required
object
answered
required
number
good
required
number
neutral
required
number
bad
required
number
unclassified
required

Answered with a rating that no option of its survey declares, so it counts nowhere

number
satisfaction
required

Share of satisfied customers, null when nobody answered

number
nullable
average
required

Null when the slice mixes surveys of different scales

number
nullable
previousSatisfaction
required
number
nullable
satisfactionDelta
required

Difference in percentage points against the previous window

number
nullable
previousAnswered
required

Answers in the previous window; 0 means there was no base to compare against

number
previousAverage
required

Null when the previous window mixes surveys of different scales

number
nullable
previousUnclassified
required
number
funnel
required

Where the answers came from, so the screen can say what slice the score speaks for

object
closed
required

Tickets opened inside the window that already ended

number
withoutSurvey
required

Ended without a survey going out: no survey on the closing reason, survey disabled, group chat, or a blocked contact

number
sent
required
number
answered
required
number
unanswered
required

Survey delivered and the customer never replied

number
unusable
required

Customer replied but the answer matched no option of the survey

number
drivers
required

Situations compared against their complement, worst drop first

Array<object>
object
key
required
string
label
required
string
inGroup
required
object
label
required
string
answered
required
number
satisfaction
required
number
nullable
outGroup
required
object
label
required
string
answered
required
number
satisfaction
required
number
nullable
gap
required

Difference in percentage points, negative when the group is worse

number
nullable
weak
required

True when the difference is too small to explain anything

boolean
filters
required

Condition leaves that open this group in the ticket list, already narrowed to who answered, or null when the dialect cannot express the group yet

Array<object>
nullable
object
distribution
required

One row per rating actually given, ascending

Array<object>
object
value
required
number
label
required
string
sentiment
required
string
nullable
Allowed values: bad neutral good
count
required
number
trend
required
Array<object>
object
label
required
string
answered
required
number
satisfaction
required
number
nullable
surveys
required

One row per survey answered in the slice, busiest first

Array<object>
object
surveyId
required
string
nullable
name
required
string
answered
required
number
satisfaction
required
number
nullable
average
required
number
nullable
byAgent
required

Agents with enough answers first, then the ones below the minimum

Array<object>
object
userId
required
string
nullable
name
required
string
answered
required
number
satisfaction
required
number
nullable
average
required
number
nullable
belowMinimum
required

Too few answers for the score to mean anything; the screen shows the name without a score

boolean
byDepartment
required
Array<object>
object
name
required
string
answered
required
number
satisfaction
required
number
nullable
byChannel
required

One row per channel family, busiest first

Array<object>
object
key
required

Channel family key, with providers of the same family folded together

string
answered
required
number
satisfaction
required
number
nullable
agentMinResponses
required

The tenant’s own floor, echoed so the screen can say how many answers are missing

number
heatDays
required
Array<string>
heatCols
required
Array<string>
heat
required

Satisfaction per weekday and three hour band, null where nobody answered

Array<Array<number>>
heatAnswers
required

Answers behind each cell

Array<Array<number>>
periodAverage
required

The middle of the heat scale: the period’s own satisfaction

number
nullable
recovery
required

How many customers are waiting to be called back

object
enabled
required

Whether the tenant turned the recovery queue on

boolean
open
required

Customers waiting or already being called back

number
overdue
required

How many of those are past their deadline

number
postSale
required

Ratings the post-sale flows asked after a delivery or a won deal, a slice of its own that the report filters do not narrow

object
answered
required

Post-sale ratings given in the period, kept out of every attendant and ticket figure

number
good
required
number
neutral
required
number
bad
required
number
satisfaction
required
number
nullable
average
required

Average rating, only when a single survey was used

number
nullable

Example

{
"period": "7",
"distribution": [
{
"sentiment": "bad"
}
]
}