CXone Studio Session Handover 400 Error with Cognigy Voicebot

Hi folks,

We are trying to implement a voicebot handover from NICE Cognigy to a live agent in CXone. The flow works fine in the Cognigy sandbox, but when we hit the Studio GetRESTProxy action to transfer the session, we get a 400 Bad Request. The error message is vague, just saying ‘Invalid request body’.

Here is the JSON payload we are sending to the /api/v2/outbound/campaigns endpoint to trigger the transfer:

{
 "to": { "uri": "tel:+442071234567", "type": "phone" },
 "from": { "uri": "tel:+442079876543", "type": "phone" },
 "context": { "botSessionId": "abc-123-def" }
}

I’ve checked the documentation for the GetRESTProxy action, and it seems like the structure should be correct. The botSessionId is being passed correctly from the Cognigy side. We are using the standard CXone voicebot integration.

Is there a specific field we are missing? The context object might be too simple. We also tried adding a campaignId but that didn’t help. The timezone is set to Europe/London, so that shouldn’t matter.

Any ideas on what could be causing the 400 error? We are stuck on this step.

You’re hitting the wrong endpoint. /api/v2/outbound/campaigns is for dialer campaigns, not session handovers. Use the Conversations API to transfer the interaction to an agent queue instead.

POST /api/v2/communications/interactions/{interactionId}/transfer
{
 "to": {
 "id": "queue-id-here",
 "type": "queue"
 }
}