GET /api/v2/analytics/queues/realtime returns a 400 Bad Request with {“code”:“bad_request”,“message”:“Invalid query parameter: interval”}. Step one: the Studio flow needs to pull live agent counts before routing to the overflow queue, so we’ve wired up a REST Proxy endpoint to hit that v2 Reporting call. The SNIPPET action builds the query string with interval=pt1h&group=queue&from=now-1h&to=now. The payload looks fine on paper, but the API keeps rejecting the interval parameter even though the docs say it’s optional for realtime stats. Stripping it out flips the error to missing required parameter: group. Swapping group to agent just cycles through different 400s. The auth token is fresh, pulled from the standard OAuth2 flow, and the same headers work perfectly against the historical endpoints.
Step two: I checked the request routing. Postman handles the exact same call without breaking a sweat, which points to something in the REST Proxy v4.5.1 query string encoder or maybe how Studio escapes the + in pt1h. We’re running this out of London, so the local clock is pushing BST, but the API expects strict UTC. Dropping the Z and swapping it for +00:00 makes the request hang until it times out at thirty seconds. The response headers show x-cxone-request-id matching across every retry, so it’s definitely hitting the same routing rule. I’ve tried base64 encoding the entire query string before passing it to the proxy, which just returns a 415 Unsupported Media Type. The SNIPPET variable holding the URL gets truncated if I add extra query params, but I’m well under the character limit.