I’m hitting a wall with the Genesys Cloud Analytics API while trying to correlate wrap-up codes with my OpenTelemetry spans. The goal is simple: pull the specific wrapUpCode for every completed interaction so I can tag the trace context accurately.
I’m using the GET /api/v2/analytics/interactions/summary/queues endpoint with a detailed breakdown. Here is the query payload I’m sending:
{
"dateFrom": "2023-10-01T00:00:00.000Z",
"dateTo": "2023-10-02T00:00:00.000Z",
"groupings": ["wrapUpCode"],
"metrics": ["callsHandled"],
"filterType": "all",
"filterValue": ""
}
The API returns a 200 OK. The response structure looks standard, but the wrapUpCode values in the groups array are consistently null. I’ve checked the UI reports, and the data is definitely there. Agents are selecting codes like Sale or No Sale correctly.
I tried adding "filterType": "wrapUpCode", "filterValue": "Sale" to see if filtering helps, but it just returns zero records. I also swapped to the /api/v2/analytics/interactions/details endpoint to get raw interaction data, hoping to find the code in the wrapUpCode field of the response object. Still null.
Is this a known limitation of the analytics API where wrap-up codes aren’t exposed in the summary or detail views for certain interaction types? Or am I missing a specific grouping parameter? I’ve been staring at the docs for hours and the schema doesn’t mention any restrictions on this field. My OTel exporter is failing because it expects a string, not null.
Here’s the relevant snippet from the response:
{
"groups": [
{
"wrapUpCode": null,
"metrics": {
"callsHandled": 150
}
}
]
}
Any idea why the code is stripping out? I need to fix this before our next sprint review. The trace context propagation depends on this metadata being present.