Hit a weird issue pulling CSAT data. The survey definitely completed. I see the interaction in the Quality tab, and the score is there. But the API is returning an empty array for the evaluations field.
I’m trying to map the CSAT score back to the specific conversation ID in a downstream script. The goal is to update a custom attribute on the contact if the score is below 3.
Here’s the call I’m making:
GET /api/v2/quality/evaluations?interactionId=conv_12345678-90ab-cdef-1234-567890123456&expanded=true
The response comes back with a 200 OK, but the JSON payload looks like this:
{
"items": [],
"pageSize": 100,
"totalCount": 0,
"pageCount": 0
}
I’ve verified the interactionId is correct. It matches the ID from the /api/v2/conversations endpoint. The survey was completed about 15 minutes ago. Is there a delay between the survey submission and when it becomes queryable via the Quality API? Or am I missing a specific filter?
I tried adding &survey=true to the query string, but that just returns a 400 Bad Request saying the parameter is unknown.
Also, I noticed that if I query by agentId, the evaluations show up eventually. But I need the specific link to the conversation. The interactionId filter seems to be the only way to get that granularity, but it’s dead silent.
Here’s the code snippet from the Studio Snippet action where I’m making the call:
ASSIGN restResponse = GetRESTProxy("GetCSATData", {"interactionId": ${conversationId}})
The trace shows the request going out correctly. The 400 error was just a manual test in Postman. The Studio call returns the empty array. I’m stuck. Need to know if this is a known limitation or if I’m doing something wrong with the filter syntax.