Nos cabeçalhos dos requests, é necessário incluir uma chave "token" cujo valor seja um token de API.
Report URL |
/callcenter/report/answered_abandoned_sla |
API URL: |
/api/v1/report/answered_abandoned_sla |
Atualmente, a maneira mais fácil de usar essa API é através do relatório original. Acessar a Report URL pela interface Web, escolher os filtros desejados e copiar os parâmetros GET que o relatório preenche na URL ao ser gerado.
Acesso via WEB do Relatório (Report URL)
http://example.callwe.io:8080//callcenter/report/answered_abandoned_sla?entity=queues&queue_or_group=queues&group_by=day&week_day=0&start_hour=07&end_hour=19&start_date=&end_date=&state=&city=&generate_report=true
Parâmetros GET da URL:
?entity=queues&queue_or_group=queues&group_by=day&week_day=0&start_hour=07&end_hour=19&start_date=&end_date=&state=&city=&generate_report=true
Acesso via API do Relatório (API URL)
curl 'http://example.callwe.io:8080/api/v1/report/answered_abandoned_sla?token=011621c7-2D03-592b-1027-c3d8a1224296&entity=queues&queue_or_group=queues&group_by=day&week_day=0&start_hour=07&end_hour=19&start_date=&end_date=&state=&city=&generate_report=true'
Para usar a API, é necessário incluir também o parâmetro Token na requisição.
Retorno:
{"data":
[
{"in_sla_duration_percent": 91.72185430463577,
"abandoned_after_threshold_percent": 32.16266173752311,
"in_sla_duration_balanced_percent": 114.65231788079468,
"in_sla_duration": 277,
"sla_wait": 20,
"lost_percent": 0.0, "time_end": 1474599599,
"in_sla_wait_balanced_percent": 34.354304635761586,
"asa": 169, "answered_after_60s": 181,
"unanswered": 239, "answered_percent": 55.822550831792974,
"active": 0, "calls": 541, "asa_sum": 51124,
"abandoned_percent": 44.17744916820702,
"abandoned_until_2m_percent": 74.05857740585773,
"abandoned_until_2m": 177,
"abandoned_before_threshold_percent": 12.014787430683919,
"abandoned": 239,
"abandoned_until_1m": 131,
"abandoned_until_1m_percent": 54.811715481171554,
"in_sla_wait_percent": 27.483443708609272,
"time_start": 1474513200,
"sla_duration": 300, "lost": 0,
"abandoned_until_30s_percent": 37.238493723849366,
"in_sla_wait": 83,
"in_sla_wait_inclusive_percent": 17.436974789915965,
"abandoned_until_10s": 37,
"abandoned_until_10s_percent": 15.481171548117153,
"label": "22/09/2016",
"unanswered_percent": 44.17744916820702,
"answered": 302, "att": 130,
"in_sla_duration_inclusive_percent": 58.19327731092437,
"abandoned_before_threshold": 65, "abandoned_after_threshold": 174,
"abandoned_until_30s": 89, "att_sum": 39265
},
{
"in_sla_duration_percent": 91.72185430463577,
"in_sla_duration_balanced_percent": 34.354304635761586,
"in_sla_wait_balanced_percent": 100, "answered_after_60s": 181,
"answered_percent": 55.822550831792974, "abandoned_percent": 44.17744916820702,
"abandoned_until_2m": 177, "abandoned_before_threshold_percent": 12.014787430683919,
"abandoned_until_30s": 89, "abandoned_until_1m_percent": 54.811715481171554,
"lost_percent": 0.0, "in_sla_duration_inclusive_percent": 58.19327731092437,
"abandoned_until_10s": 37, "unanswered": 239, "label": "Total",
"unanswered_percent": 44.17744916820702, "answered": 302,
"abandoned_after_threshold": 174, "abandoned_after_threshold_percent": 32.16266173752311,
"in_sla_duration": 277, "abandoned_until_10s_percent": 15.481171548117153,
"abandoned_until_2m_percent": 74.05857740585773, "asa": 169, "abandoned_before_threshold": 65,
"abandoned_until_1m": 131, "abandoned": 239, "lost": 0,
"abandoned_until_30s_percent": 37.238493723849366, "att": 130, "in_sla_wait": 83,
"calls": 541, "in_sla_wait_inclusive_percent": 17.436974789915965,
"in_sla_wait_percent": 27.483443708609272
}
],
"meta": {"status": 200, "message": "OK"},
"params": {"city": "", "week_day": "0",
"queues": [
{"name": "Fila 01", "id": 151},
{"name": "Fila 02", "id": 324},
{"name": "Fila 03", "id": 55},
{"name": "Fila 04", "id": 8},
{"name": "Fila 05", "id": 282},
{"name": "Fila 06", "id": 12},
{"name": "Fila 07", "id": 1},
{"name": "Fila 08", "id": 3},
{"name": "Fila 09", "id": 111},
{"name": "Fila 10", "id": 2}],
"start_hour": "07", "end_hour": "19", "state": "", "group_by": "day", "queue_groups": []}}