Skip to contentSkip to navigationSkip to topbar
Rate this page:
On this page

Voice JS SDK v1: Troubleshooting & Common Errors


(warning)

Warning

You're viewing the 1.X version of the Voice JavaScript SDK (formerly called Twilio Client). Click here for information on how to migrate to the 2.X version.


DSCP Support

dscp-support page anchor

Due to a breaking change introduced in Chrome 72, SDK versions prior to 1.6.10 will no longer enable DSCP. For DSCP support, please update to the newest version of the SDK.


Following are the common errors encountered in twilio.js, what they mean, and our troubleshooting recommendations.

Error text: 31201 Error while accessing microphone

error-text-31201-error-while-accessing-microphone page anchor

Where: This error is a result of a getUserMedia failure, usually in response to calling device.connect() or connection.accept().

Details: The user granted permission, but there was an issue getting the media. The user may need to try another input device, or troubleshoot their hardware. The failure will correspond to one of the many getUserMedia exceptions listed here(link takes you to an external page). The most common issue is the NotFoundError which indicates the device ID passed to Device.audio.setInputDevice() was not found.

Error text: 31208 Permission Denied

error-text-31208-permission-denied page anchor

Where: This error is a result of a getUserMedia failure, usually in response to calling device.connect() or connection.accept().

Details: Received when the user denies permission to the microphone. The user won't have an input audio track, and should be asked to refresh and grant permission.

Error text: 31205 Token Expired

error-text-31205-token-expired page anchor

Where: This error will be emitted via device.on('error') when a token expires, and will throw to console if uncaught.

Details: The access token has expired. The signaling channel, DTMF and Insights will stop working until a new token is provided via Device.setup(token). The application should create a new token and replace it before the prior token expires.

Error text: 31003 ICE negotiation failed

error-text-31003-ice-negotiation-failed page anchor

Where: This error will be emitted via connection.on('error') during connecting, shortly after device.connect() or connection.accept().

Details: The ICE negotiation couldn't find any acceptable candidates, or otherwise failed to connect. The end user may want to try again; if failures continue, there's likely a network issue, such as firewall, preventing connectivity.

Error text: 31003 Connection interrupted

error-text-31003-connection-interrupted page anchor

Where: This error will be emitted via connection.on('error') during an established and active call.

Details: The ICE status changed from connected to failed. As of 1.6.5, this automatically disconnects the connection, however in a future update Twilio will attempt to re-establish the ICE connection.


Rate this page: