Skip to main content

2.26.1 (2026-04-10)

Structured Errors & Warnings

  • Feat: wire structured errors and warnings across SDK (#548) Comprehensive overhaul introducing typed error codes (40xxx49xxx) and warning codes (3xxxx) throughout the SDK. Replaces previously swallowed errors with structured TelnyxError events and ITelnyxWarning notifications while maintaining backward compatibility.
    • SDP errors (400xx): offer, answer, local/remote description, and send failures
    • Media errors (420xx): microphone permission denied, device not found, general media failures
    • Call-control errors (440xx): hold failed, invalid parameters, BYE send failed, subscribe failed
    • WebSocket/transport errors (450xx): connection failed, reconnection exhausted, gateway failures
    • Authentication errors (460xx): login failed, invalid credentials, authentication required
    • Network errors (480xx): network offline
    • Quality warnings (310xx): high RTT, jitter, packet loss, low MOS
    • Connection warnings (320xx): low bytes received/sent
    • ICE warnings (330xx): connectivity lost, gathering timeout, peer connection failed, host-only candidates
    • Auth warnings (340xx): token expiring soon
    • Session warnings (350xx): session not reattached
  • Chore: improve errors docs and export error/warning code constants (#602) Restructured error-handling documentation for clarity. Exports TELNYX_ERROR_CODES and TELNYX_WARNING_CODES from the main package index so consumers can reference them directly. Listening for errors and warnings:
    import {
      SwEvent,
      TelnyxError,
      TELNYX_ERROR_CODES,
      TELNYX_WARNING_CODES,
    } from '@telnyx/webrtc';
    
    client.on(SwEvent.Error, (event) => {
      switch (event.error.code) {
        case TELNYX_ERROR_CODES.MICROPHONE_PERMISSION_DENIED:
          showMessage('Microphone access was denied.');
          break;
        case TELNYX_ERROR_CODES.NETWORK_OFFLINE:
          showMessage('You appear to be offline.');
          break;
        case TELNYX_ERROR_CODES.AUTHENTICATION_REQUIRED:
          showMessage('Session expired. Please re-authenticate.');
          break;
        default:
          showMessage(event.error.message);
      }
    });
    
    client.on(SwEvent.Warning, (event) => {
      if (event.warning.code === TELNYX_WARNING_CODES.PEER_CONNECTION_FAILED) {
        showBanner('Call connectivity degraded.');
      }
      if (event.warning.code === TELNYX_WARNING_CODES.TOKEN_EXPIRING_SOON) {
        refreshToken();
      }
    });
    

Media Recovery

  • Fix: interrupt call negotiation on media failure for non-receive-only peers (#582) When media retrieval (e.g. microphone access) fails during peer initialization, the SDK now interrupts call negotiation immediately instead of continuing into SDP setup. Previously, media failures triggered hangup asynchronously, creating a race condition where an answer SDP could be created before hangup executed on inbound calls. Receive-only peers are unaffected since they do not require local media. Media recovery on inbound calls:
    import { isMediaRecoveryErrorEvent } from '@telnyx/webrtc';
    
    const client = new TelnyxRTC({
      login_token: '...',
      mediaPermissionsRecovery: {
        enabled: true,
        timeout: 20000,
        onSuccess: () => console.log('Media recovered, call proceeding'),
        onError: (err) => console.error('Recovery failed', err),
      },
    });
    
    client.on(SwEvent.Error, (event) => {
      if (isMediaRecoveryErrorEvent(event)) {
        // Show a prompt so the user can grant microphone access
        // User need to implement it on their side
        showPermissionDialog({
          deadline: event.retryDeadline,
          onAllow: () => event.resume(), // retries getUserMedia
          onDeny: () => event.reject(), // terminates the call
        });
      }
    });
    
  • Fix: remove trickleIce guard for attach method (WEBRTC-3395) (#584) Removes the forced trickleIce=false override for the attach (reconnection) method. The guard was originally added for b2bua-rtc codec negotiation compatibility but is no longer needed.

Call Teardown & Disconnect

  • Fix: separate client.disconnect() and PUNT disconnect paths with correct BYE behavior (#580) Distinguishes between client-initiated graceful disconnect and server-initiated disconnect (PUNT). client.disconnect() now sends BYE messages to active calls before purging; PUNT triggers serverDisconnect() which purges calls without BYE since the server connection is already gone.
  • Feat: make hangup async, properly await BYE execution (#581) Breaking: hangup() is now an async method returning Promise<void> (previously synchronous/fire-and-forget). Callers can now await hangup() to ensure BYE messages are fully sent before proceeding, enabling clean call termination sequences.
    // Before (fire-and-forget)
    call.hangup();
    
    // After (await to ensure BYE is sent)
    await call.hangup();
    

Features

  • Feat: store source datacenter identifier from REGED message (#583) The SDK now extracts and stores dc and region fields from the REGED WebSocket message, allowing consumers to identify which Telnyx regional infrastructure handled their connection.

Bug Fixes

  • fix(types): point types field at lib/src/index.d.ts (#601)

Documentation

  • docs: Voice SDK Network Connectivity Requirements (#564) New comprehensive guide covering signaling server endpoints, STUN/TURN addresses, media server IP subnets, port ranges (UDP 16384–32768), bandwidth requirements (Opus ~40 kbps, PCMU ~100 kbps), firewall configuration, and best practices for enterprise/VPN environments.

CI / Chores

  • fix(ci): push release branch before pinning draft release target (#597)
  • fix(ci): pin draft target to bump SHA, publish from tag (#596)
  • fix(ci): single release-it call for bump + tag + draft (#593, #594)
  • fix(ci): allow non-immutable installs for draft release tagging step (#592)
  • fix(ci): drop lockfile update step, set YARN_ENABLE_IMMUTABLE_INSTALLS=false (#591)
  • fix(ci): use —mode update-lockfile to avoid upgrading all deps (#589)
  • fix(ci): update lockfile after version bump in draft-release (#587)
  • fix(ci): create release tag after version bump commit (#586)
  • chore: include README.md in npm packages and remove Slack notifications (#578)

2.26.1-beta.2 (2026-04-08)

  • chore: release webrtc@2.26.1-beta.1 (#595)
  • fix(ci): allow non-immutable installs for draft release tagging step (#592)
  • fix(ci): allow non-immutable installs for draft release tagging step
  • fix(ci): drop lockfile update step, set YARN_ENABLE_IMMUTABLE_INSTALLS=false (#591)
  • fix(ci): use —mode update-lockfile to avoid upgrading all deps (#589)
  • fix(ci): update lockfile after version bump in draft-release (#587)
  • fix(ci): create release tag after version bump commit (#586)
  • Fix: interrupt call negotiation on media failure for non-receive-only peers (#582)
  • feat: make hangup async, properly await BYE execution (#581)
  • Feat: wire structured errors and warnings across SDK (#548)

2.26.1-beta.1 (2026-04-08)

  • fix(ci): allow non-immutable installs for draft release tagging step (#592)
  • fix(ci): allow non-immutable installs for draft release tagging step
  • fix(ci): drop lockfile update step, set YARN_ENABLE_IMMUTABLE_INSTALLS=false (#591)
  • fix(ci): use —mode update-lockfile to avoid upgrading all deps (#589)
  • fix(ci): update lockfile after version bump in draft-release (#587)
  • fix(ci): create release tag after version bump commit (#586)
  • Fix: interrupt call negotiation on media failure for non-receive-only peers (#582)
  • feat: make hangup async, properly await BYE execution (#581)
  • Feat: wire structured errors and warnings across SDK (#548)

2.26.1-beta.0 (2026-04-07)

  • docs: update ts docs
  • fix: read dc/region instead of local_dc/local_region from REGED params
  • refactor: rename localDc/localRegion to dc/region and use structured logging
  • feat: store local_dc and local_region from REGED message
  • feat: store source datacenter identifier from REGED message
  • chore: include README.md in npm packages and remove Slack notifications (#578)

2.26.0 (2026-03-31)

  • chore: upgrade Node.js to 24.5.0 (npm 11.5.1 for OIDC trusted publishing) (#576)

2.25.29 (2026-03-31)

  • fix: upgrade actions/setup-node from v4 to v6 for OIDC compatibility (#574)

2.25.28 (2026-03-31)

  • chore: upgrade Node.js from 18 to 22.14 across all workflows (#572)
  • chore: release webrtc@2.25.27 (#571)

2.25.27 (2026-03-31)

  • chore: remove NODE_AUTH_TOKEN from publish steps for OIDC auth (#570)

2.25.26 (2026-03-31)

  • fix: guard against null localDescription in _onIceSdp (#557)
  • chore: consolidate publish workflows for npm trusted publisher OIDC (#567)
  • fix: reset keepalive on any inbound message to prevent false ping/pong warnings (#556)
  • fix: don’t null global LogCollector on call cleanup (#555)
  • chore: add OIDC permissions and npm provenance to prerelease workflow (#566)
  • chore: add OIDC permissions and npm provenance to publish-release workflow (#565)

2.25.26-beta.2 (2026-03-13)

  • docs: update ts docs
  • feat: add recoveredCallId to call object for recovery correlation (ENGDESK-50308)

2.25.25 (2026-03-11)

  • docs: update ts docs
  • fix: disable trickle ICE for attach (reconnection) (#550)
  • feat: add recvonly audio transceiver when audio=false (WEBRTC-3394) (#549)
  • feat(WEBRTC-3324): support target_params in anonymous_login (#542)
  • feat: auto-trigger developer docs update on JS SDK release (#545)

2.25.24 (2026-03-03)

  • docs: update ts docs
  • fix: handle getUserMedia failure gracefully (no microphone) (#541)
  • feat: add audioLevel + transport stats to call report (WEBRTC-3321) (#540)

2.25.23 (2026-02-27)

  • docs: update ts docs
  • feat: add ICE candidate pair stats to call report (WEBRTC-3302) (#538)
  • chore: release webrtc@2.25.22 (#536)

2.25.22 (2026-02-26)

  • fix: retry once on network error when posting call report (#534)

2.25.21 (2026-02-25)

  • fix: send call reports for calls shorter than the collection interval (#532)

2.25.20 (2026-02-25)

  • fix: serialize log context to capture DOM Event properties in call reports (#520)
  • chore: update CODEOWNERS to @lucasassisrosa @ArtemPapazian (#530)
  • fix: set direction before setState on inbound invite (#527)
  • fix: use state-dependent hangup cause code (#528)

2.25.19 (2026-02-23)

  • fix: commit CHANGELOG.md before yarn release to avoid dirty worktree error (#524)
  • fix: strip localElement and remoteElement from dialogParams (#450) (#521)
  • fix: keep loglevel at debug so LogCollector captures all logs for call reports (#522)
  • feat: enable prefetchIceCandidates by default (#523)
  • fix: Apply safety timeout to all close() calls (#515)
  • chore: generate CHANGELOG.md in draft-release workflow (#519)
  • chore: use ubuntu-latest runner for draft-release workflow (#517)
  • feat: automatic call quality reporting to voice-sdk-proxy (#494)
  • fix: reuse single VertoHandler instance and convert static state to instance state (#509)
  • fix(WEBRTC-3267): Fire telnyx.ready event on reconnection (#513)
  • fix(WEBRTC-3266): Prevent race condition in network reconnection by deferring _wasOffline reset (#511)
  • fix(ENGDESK-49463): use correct hangup code (16) instead of hardcoded USER_BUSY (17) (#506)
  • fix: set TURN transport to udp as default and tcp as fallback (#495)
  • fix: stop debug reporter when peer connection is closing (#498)
  • fix: remove canary flag requirement for trickleIce (#507)
  • fix: remove trickle ICE support check that sends empty candidate on login (#500)
  • docs: add 4014 gateway down close code to error handling (#504)
  • chore: fix TelnyxRTC.md (#497)
  • fix: if we get attach always run reconnection flow (#503)
  • FIX: Reconnection flow (#492)
  • feat: getUserMedia fallback for device-specific errors (#490)
  • docs: add authentication error handling documentation (#491)
  • fix: documentation on event listening (#489)

2.25.18 (2026-02-10)

  • fix: use correct hangup code (16) instead of hardcoded USER_BUSY (17)
  • fix: stop debug reporter when peer connection is closing
  • fix: remove canary flag requirement for trickleIce
  • fix: remove trickle ICE support check that sends empty candidate on login
  • fix: set TURN transport to udp as default and tcp as fallback
  • fix: if we get attach always run reconnection flow
  • docs: add 4014 gateway down close code to error handling
  • chore: fix TelnyxRTC.md
  • chore: add meta-dev.yml for GitHub access control

2.25.17 (2026-02-02)

  • fix: reconnection flow
  • feat: implement manual Login function
  • feat: getUserMedia fallback for device-specific errors

2.25.16 (2026-01-22)

  • fix: documentation on event listening
  • docs: add authentication error handling documentation
  • docs: document manual re-authentication with new token

2.25.15 (2026-01-12)

  • fix: recreate call if peer connection signaling state is closed
  • chore: restart debug stats reporter on session reconnect
  • chore: expose PeerConnectionSignalingStateClosed event
  • chore: update documentation for event and error handling
  • fix: remote stream assignment to properly persist (@maiconpavi)
  • fix: propagate session forceRelayCandidate option to call
  • fix: address race condition on peer creation during reconnect
  • fix: active call leg on reconnection with ice restart
  • fix: send hangup msg before reconnectionOnAttach flag activation
  • fix: avoid creating multiple calls on reconnection
  • fix: flag usage on attach handler nested condition
  • fix: hangup bye execute logic and buffer manipulation
  • feat: update documentation on flag optimistic behavior

2.25.14 (2025-12-16)

  • fix: make sure offerToReceiveAudio is set if call audio options is undefined

2.25.12 (2025-12-15)

  • feat: clear intervals setup on device sleep wake

2.25.11 (2025-12-15)

Enhancements

  • normalize logging calls
  • improve debug logs and socket disconnect on retry
  • add device sleep mode detection code

Fixes

  • address connection state not transitioning
  • maintain call state on peer connection signaling state change

2.25.10 (2025-12-04)

  • fix: consider keepConnectionAliveOnSocketClose in session call for Punt
  • fix: do not empty execution queue on keepConnectionAliveOnSocketClose to avoid old refs

2.25.9 (2025-12-02)

Enhancements

  • move mutedMicOnStart from call to client options

2.25.8 (2025-11-28)

Features

  • add iceServers to client options
  • add mutedMicOnStart to call options

2.25.7 (2025-11-25)

Features

  • add useCanaryRtcServer to client options

Enhancements

  • add call_id for debug_report_start and debug_report_stop messages

2.25.6 (2025-11-18)

Fixes

  • received authentication required counter cleanup

2.25.5 (2025-11-13)

Fixes

  • punt message handling logic on keepConnectionAliveOnSocketClose option set

Enhancements

  • add SwEvent handling reference with session readiness, notifications, diagnostics, and telemetry docs
  • add SwEvent error reference to error handling docs

2.25.4 (2025-11-12)

  • fix: ws connection down case on reconnection
  • chore: update keepConnectionAliveOnSocketClose docs to point users to client options usage

2.25.3 (2025-11-12)

  • fix: called createWebRTCStatsReporter before use statsReporter

2.25.2 (2025-11-07)

Enhancements

  • update audio constraints types in call options
  • update ts docs
  • log audio constraints applied to peer connection

Fixes

  • correct typings declaration file export

2.25.1 (2025-11-05)

Features

  • add keepConnectionAliveOnSocketClose to client options

Enhancements

  • improve logs on peer connection failure
  • remove legacy code
  • keep alive check on ping messages

Fixes

  • correct method scope in browser session
  • clear call and peer connection on unrecoverable state
  • add cleanup to network listeners
  • reconnect on false positive reged state from gateway
  • restart ice on offer peer only
  • do not disconnect session on punt if keepConnectionAliveOnSocketClose is set
  • hangup and recreate call if peer connection instance is destroyed

2.24.2 (2025-11-04)

  • chore: socket connection error handling documentation (#460)

2.24.1 (2025-10-30)

  • fix: update inner voice_sdk_id state on first trickle ice canary use (#459)

2.24.0 (2025-10-29)

Features

  • true trickle ice implementation (#439)

Enhancements

  • check for gateway trickle ice support and add fallback
  • improve logging on connection state changes
  • add trickle ice performance metrics
  • remove legacy video code

2.22.19 (2025-10-29)

fix: enforce callID from call options to be string (#456)

2.22.18 (2025-10-23)

fix: expose getIsRegistered (#448) fix: preferred codecs should only be enforced on INVITE, not on ANSWER (#452)

2.22.17 (2025-08-04)

chore: add detailed performance measuring for invite (#438)

2.22.16 (2025-08-04)

feat: add support for image attachments (#436)

2.22.15 (2025-07-24)

feat: pass target_version_id for anonymous login (#434)

2.22.14 (2025-07-09)

feat: send messages to AI agents (#432)

2.22.13 (2025-07-04)

fix: improve p2p connection establishment time (#431) fix: export Call via relative path (#429)

2.22.12 (2025-05-20)

chore: Tidy up exposed interfaces in entrypoint (#428)

2.22.11 (2025-05-14)

Bug fixes

fix: the pre-call diagnosis report sometimes doesn’t resolve. (#426)

2.22.10 (2025-05-09)

Bug fixes

fix: debug report file is not generated (#425)

2.22.9 (2025-04-14)

Features

feat: anonymous login and ai_agent calls (#420)

2.22.8 (2025-03-28)

Features

feat: regional subdomains for voice-sdk (#417)

2.22.7 (2025-03-06)

Features

feat: implement real time call quality metrics (#414) feat: implement pre-call diagnosis (#407)

Bug fixes

fix: disable automatic video response in favor of answer option (#413)

2.22.6 (2025-02-20)

Bug fixes

fix: attach with video when receiving m=video sdp (#409)

2.22.5 (2025-01-17)

Bug Fixes

fix(webrtc): Stop ringback tone when call is hung up (#406)

2.22.4 (2025-01-14)

Bug fixes

Fix inconsistency in reporting addConnection debug event through the websocket

2.22.3 (2024-12-03)

Bug fixes

fix: Fix compatibility with NextJS

Features

feat: add option to force usage of relay candidate (#400)

2.22.2 (2024-11-14)

Enhancement

  • WebRTC Debug Report: Enhance collected data.

Features

  • add an option to allow ice candidate prefetching (#396)

2.22.1 (2024-10-14)

Bug Fixes

Improve stability for ICE gathering process. (See #391)

2.22.0 (2024-10-14)

Features

2.21.2 (2024-09-05)

Bug Fixes

2.21.1 (2024-08-22)

Bug Fixes

2.21.0 (2024-08-14)

Features

2.20.0 (2024-08-01)

Features

  • get registration state from the gateway (#366) (c5af08b)

2.19.0 (2024-06-20)

Features

Bug Fixes

2.18.0 (2024-06-10)

Features

2.17.0 (2024-05-28)

Features

  • propagate session id with error event (#358) (0f931ed)

2.16.0 (2024-05-14)

Features

2.15.0 (2024-04-30)

Features

2.14.0 (2024-04-26)

Features

  • implement debug output for file and websocket (#352) (8d1f8e6)

2.13.0 (2024-04-22)

Features

  • add probe to fetch webrtc statistics periodically (#350) (2a72b60)

2.12.0 (2024-04-05)

Features

  • add a faster work-around for ice gathering never completing (#349) (47e1863)

2.11.0 (2024-02-26)

Features

  • TELAPPS-4794: expose user agent on login (#343) (a8b9606)

Bug Fixes

  • ENGDESK-23349: bind telnyxids on ringing event for outbound calls (#342) (1b1df78)
  • ENGDESK-28811: call object direction is undefined upon receiving call (#341) (8ac5a3f)

2.10.2 (2024-02-20)

Bug Fixes

  • ENGDESK-26922: Make login_token optional (#340) (1c0b36a)

2.10.1 (2023-11-23)

Bug Fixes

  • the params.customHeaders was not being destructuring correctly the values (#339) (b7e1c2a)

2.10.0 (2023-11-22)

Features

  • ENGDESK-26634: add custom headers to invite and answer messages (#338) (69814b4)
  • ENGDESK-27107: Upgrade WebRTC library to support React 18 (#321) (66d0c0e)

2.9.0 (2023-01-31)

Features

  • ENGDESK-21003: add beforeunload event to hang up active calls when the browser is closed or refreshed (#304) (5f4a899)

2.8.2 (2022-09-28)

Bug Fixes

  • ENGDESK-19054: Voice SDK missing types when installed in TypeScript projects. (#299) (ae76c98)

2.8.1 (2022-07-07)

2.8.0 (2022-05-25)

Features

  • WEBRTC-1798: add ping request to the server to keep connected (#287) (95ce187)

2.7.6 (2022-04-26)

2.7.5 (2022-04-26)

2.7.4 (2022-04-25)

Bug Fixes

  • change timeout value of 500 to use a random number between 3000 (#246) (34a232a)
  • WEBRTC-1705: reverting dependabot updates to fix typedoc generation (#278) (5ac667d)

2.7.3 (2021-12-14)

Bug Fixes

  • change previousGatewayState only if gateWayState exist to avoid send many REGISTER messages (#244) (70c10fa)

2.7.2 (2021-12-13)

Bug Fixes

  • ENGDESK-12851: add code to avoid multiples REGED messages on the client side (#235) (86b3a0e)

2.7.1 (2021-12-09)

Bug Fixes

2.7.0 (2021-12-08)

Features

Bug Fixes

  • Hotfix: package.lock update and node upgrade to 14 (#228) (29b7c27)
  • WEBRTC-746: recursive call to getDevices when the browser does not support audiooutput like Safari and Firefox. (#223) (bbc2231)

2.2.7 (2021-01-08)

2.2.6 (2021-01-08)

2.2.5 (2021-01-06)

2.2.4 (2020-12-11)

2.2.3 (2020-12-04)

Changed

  • Updates to docs

2.2.2 (2020-11-19)

Bug Fixes

  • ENGDESK-7173: change the STUN_SERVER port from 3843 to 3478 (#60) (cc8f78f)

2.1.6 - 2020-10-05

Changed

  • Added cause and causeCode when hangup the call

2.1.5 - 2020-08-26

Changed

  • Removed adapter-webrtc it was breaking the react-native SDK

Added

  • Added improvements in production bundle code.

2.1.4 - 2020-08-26

Changed

  • Enabled multiple connections in multiple devices (browsers, tabs, and etc)
  • Changed localStorage to use sessionStorage on Login class to save sessid

2.1.3 - 2020-08-13

Added

  • Added SipReason SipCode and SIP Call ID to show friendly error messages.

Changed

  • Changed the project structure to use monorepo yarn workspaces.

2.1.2 - 2020-08-06

Fixed

  • Fixed alert message about Authentication required

2.1.1 - 2020-08-03

Added

  • Added a new react video example to make video call.

Updated

  • Updated storybook react example, removed deprecated methods, and added new ones.

Fixed

  • Fixed audio call on Firefox v78. It only add offerToReceiveAudio/offerToReceiveVideo when provided in the options

Security

  • Fixed vulnerabilities in some dev dependencies.

2.1.0 - 2020-07-09

Added

  • Added the property ringbackFile to provide a ringback audio file.
  • Added support to play ringback file when receive the event telnyx_rtc.ringing.
  • Added the property login_token to support login with ephemeral token.
  • Added CHANGELOG file.

Changed

  • Changed the property ringFile to be ringtoneFile.

Security

  • Fixed vulnerabilities in some dev dependencies.

2.0.3 - 2020-06-08

Added

  • Added setStateTelnyx method to BaseCall.ts.

2.0.2 - 2020-05-12

Added

  • Added support to react-native

2.0.1 - 2020-05-12

First Release!

Release: WebRTC SDK V2.22.17

feat: add call initialization metrics