The recording export endpoint - GET /api/v2/orphanrecordings/{orphanId}/media - is failing with a 413 Payload Too Large error when requesting the full audio stream for recordings exceeding sixty minutes. We’ve verified the recording is fully processed and available within the Genesys Cloud UI.
Attempting to mitigate this by implementing segmented export requests - requesting audio in five-minute chunks - introduces significant overhead and disrupts real-time biometric analysis pipelines. This approach also necessitates the handling of potentially hundreds of individual requests for a single recording.
It appears the default payload size limit for this endpoint is insufficient for longer calls, yet documentation doesn’t clearly define a maximum recording duration supported via the API. A workaround involving increasing the server-side payload size limit would be preferable.
2 Likes
yes, the 413 is… fun. i see this sometimes. the docs, of course, do not tell you about this limit. it’s like they think nobody wants to download a full recording.
try this - i think is the only way. you must set Accept-Encoding: gzip header. i found this in old community post - somebody had same problem with the Data Action, believe it or not. the API is lazy, it only compress when you ask for it.
curl -H "Authorization: Bearer YOUR_TOKEN" \
-H "Accept-Encoding: gzip" \
"https://api.mypurecloud.com/v2/orphanrecordings/{orphanId}/media" \
-o recording.mp3
if still no work, check the Content-Range header in the response. sometimes is giving you hint what is the max size.
also, very important - is the recording really finished? i see sometimes it says ‘complete’ in UI, but the API is still preparing the chunks. you must check the status of the recording. if it is not ‘complete’, wait. it’s the usual thing.
i’m not saying the UI is wrong, only saying… check it anyway.
1 Like