Add optional ;user=phone on outbound SIP URIs (#615) - #769
Open
lixuanqun wants to merge 1 commit into
Open
Conversation
Some PSTN carriers (e.g. Airtel) require the RFC 3261/3966 user=phone URI parameter on Request-URI, From, and To. Enable via config uri_user_phone or feature flag sip.uri_user_phone=true. Co-authored-by: li xuanqun <793005378@qq.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #769 +/- ##
==========================================
+ Coverage 65.25% 66.06% +0.81%
==========================================
Files 51 41 -10
Lines 6588 7960 +1372
==========================================
+ Hits 4299 5259 +960
- Misses 1915 2216 +301
- Partials 374 485 +111 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #615.
Some PSTN carriers (notably Airtel and similar Indian trunks) require the RFC 3261 / RFC 3966
;user=phoneURI parameter on outbound Request-URI, From, and To. LiveKit previously had no way to add URI parameters there (custom headers / trunkaddresscannot do this).This change adds an opt-in:
uri_user_phone: truein SIP service YAMLsip.uri_user_phone=trueon the create-participant request feature flagsWhen enabled,
;user=phoneis appended to Request-URI, From, and To (idempotent if already present). Contact is unchanged. Default remains off.Longer term, a trunk-level
uri_paramsfield in protocol would be nicer; this unblocks carriers without a protocol bump.Test plan
TestBuildOutboundHeaderscovers config, feature flag, transport combo, and raw-URI idempotencyUsage
or project feature flag
sip.uri_user_phone=true.