Stuck on a persistent WebRTC connection error while migrating our agent softphone setup from Zendesk Talk to Genesys Cloud. The goal is to replace the Zendesk browser-based audio widget with the native Genesys Cloud softphone experience for our remote support team in Paris.
We are using the Genesys Cloud JavaScript SDK version 4.28.0 in a custom embedded iframe. When an agent attempts to register the softphone via the webRtc.register() method, the console immediately throws a WebRTC_ERROR_401: Unauthorized. The error payload indicates that the user token is invalid or expired, despite the fact that the OAuth2 access token was generated just seconds prior using the correct client ID and secret for our eu-west-1 environment.
In Zendesk, we simply injected the API key into the embed script, and the audio channel established without complex token rotation. Here, the documentation suggests using a short-lived user token, but the validation step fails consistently. We have verified that the user account has the webRtc:enable capability and is assigned to a routing queue. The network logs show the initial handshake to wss://websockets.genesyscloud.com succeeds, but the subsequent STUN server binding request drops with the 401 status.
Is there a specific scope requirement for the access token that differs from standard API calls? We are currently requesting webRtc:enable and user:read, but the softphone registration seems to demand more. We have tried regenerating the client secret and clearing the browser cache, but the result is identical.
Any insights into the token scope requirements for WebRTC registration in the European data center would be appreciated. We want to ensure the migration path from Zendesk’s simpler auth model to Genesys’s token-based approach is handled correctly.
Thanks for the help.