Upcoming Breaking Changes in Twilio Voice JavaScript SDK & Google Chrome

Twilio Voice JavaScript SDK (formerly "Twilio Client") versions prior to version 1.7.1 rely on the Plan B SDP (Session Description Protocol) API, which Google will be removing from Chrome by Q1 of 2020. The removal of Plan B SDP could cause users of SDK version 1.7.0 and earlier to lose audio if they switch audio input devices during an active call. Due to this change, we no longer consider these older versions of the Twilio Voice JavaScript SDK to be compatible with future versions of Chrome.

Twilio recommends upgrading to the latest 1.x version of the Twilio Voice JavaScript SDK as soon as possible.

Notice - 2019/08/22: This article was republished with the updated Q1 2020 guidance from Google for the removal of Plan B SDP. The previous timeline given was "End of 2019".

Impact Timeline

Google has communicated to Twilio these latest changes will be in a Chrome release targeted for Q1 of 2020. Google has not indicated the exact version of Chrome, or a more precise date. We recommend that you upgrade to the latest Twilio Voice JavaScript SDK release as soon as possible.

Detailed Explanation

In December 2018, Google began the phased migration of Chrome from using the Plan B SDP (Session Description Protocol) format to the Unified Plan SDP format. As they have now entered the final phase, Google will completely remove Plan B support from Chrome. Google has indicated this will be completed by Q1 of 2020.

With this phase out, SDK versions prior to 1.7.1 exhibit incompatibilities with the new Unified Plan format that causes the user to lose audio if the input device is changed. With the loss of audio, this will ultimately cause the caller and/or callee to hang up the call.

Is my application affected?

You will be affected if you are using a version prior to 1.7.1.

How do I upgrade my application?

If you depend on the SDK served directly from Twilio's CDN, update your dependency to the latest version of the Twilio voice JavaScript SDK. The latest 1.x version is backward-compatible with all versions starting with 1.4, and should require no additional migration steps.

To update to the latest version of 1.x, use the following URL in your application:

https://media.twiliocdn.com/sdk/js/client/v1.10/twilio.min.js

For customers using NPM, install the newest version before rebuilding your application:

  • twilio-client (1.x): npm install twilio-client --save
  • twilio/voice-sdk (2.x): npm install @twilio/voice-sdk --save

Notice: We recommend that all customers currently using our CDN to switch to a build process using the official twilio-client NPM package. In fact, the Voice JavaScript SDK 2.X line will no longer be uploaded to Twilio's CDN. Using NPM provides developers with more precise versioning rules, and adding dependencies as a build step provides more control over what makes it into your production application. That said, you don't need to switch to NPM to address this upcoming compatibility issue with Chrome.

For help switching over from the CDN, see Use the new NPM module instead of CDN.

Additional Resources

Have more questions? Submit a request
Powered by Zendesk