Agent_performance_summary_view

Hi, how are you?

I am consuming the / api / v2 / analytics / reporting / export endpoint and sending the following json through the body:

{
"name": "Campaign load test using api for tokenized",
"timeZone": "GMT-3",
"exportFormat": "CSV",
"interval": "2021-06-01T00: 00: 00.000Z / 2021-06-07T00: 00: 00.000Z",
"period": "P1D",
"viewType": "AGENT_PERFORMANCE_SUMMARY_VIEW",
"filter": {
"showSecondaryStatus": "true"
},
"read": true,
"locale": "en-us"
}

The answer is:

{
"message": "select at least one media type to view",
"code": "general.bad.request",
"status": 400,
"contextId": "e4829232-f910-4c1c-ae04-3f7d56542fa1",
"details": [],
"mistakes": []
}

I don't understand exactly what it is: "select at least one media type to view"

Thank you

Hi Daniela,

The error message indicates you have to provide a view filter with the mediaType attribute set (e.g. callback, chat, co-browse, email, message, screen share, video or voice). Without the filter, the query will fail.

I hope that helps.

Thanks,
John Carnell
Manager, Developer Engagement

Yes, I have tried that, but the error persists

Body:

{
"name": "Prueba subida campaƱa por api para tokenizado",
"timeZone": "GMT-3",
"exportFormat": "CSV",
"interval": "2021-06-01T00:00:00.000Z/2021-06-07T00:00:00.000Z",
"period": "P1D",
"viewType": "AGENT_PERFORMANCE_SUMMARY_VIEW",
"filter": {
"showSecondaryStatus": "true"
},
"ViewFilter": {
"mediaTypes": ["callback", "voice"]
},
"read": true,
"locale": "en-us"
}

{
"message": "select atleast one media type for the view",
"code": "general.bad.request",
"status": 400,
"contextId": "e7a51ab1-935e-4674-90e1-ddb408630cd5",
"details": [],
"errors": []
}

what else could i do?

Please refer to the documented schema for the properties you can use: POST /api/v2/analytics/reporting/exports; ViewFilter is not a property. The error is saying you need to add the media type property on the filter, which exists as the property filter.

Ready, I was not understanding where to add the filters.

{
"name": "Test campaign upload by api for tokenized",
"timeZone": "GMT-3",
"exportFormat": "CSV",
"interval": "2021-06-01T00: 00: 00.000Z / 2021-06-07T00: 00: 00.000Z",
"period": "P1D",
"viewType": "AGENT_PERFORMANCE_SUMMARY_VIEW",
"filter": {
"showSecondaryStatus": "true",
"mediaTypes": ["callback"]
},
"read": true,
"locale": "en-us"
}

Thank you

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.