pub struct SipInboundTrunkInfo {Show 16 fields
pub sip_trunk_id: String,
pub name: String,
pub metadata: String,
pub numbers: Vec<String>,
pub allowed_addresses: Vec<String>,
pub allowed_numbers: Vec<String>,
pub auth_username: String,
pub auth_password: String,
pub headers: HashMap<String, String>,
pub headers_to_attributes: HashMap<String, String>,
pub attributes_to_headers: HashMap<String, String>,
pub include_headers: i32,
pub ringing_timeout: Option<Duration>,
pub max_call_duration: Option<Duration>,
pub krisp_enabled: bool,
pub media_encryption: i32,
}
Fields§
§sip_trunk_id: String
§name: String
Human-readable name for the Trunk.
metadata: String
User-defined metadata for the Trunk.
numbers: Vec<String>
Numbers associated with LiveKit SIP. The Trunk will only accept calls made to these numbers. Creating multiple Trunks with different phone numbers allows having different rules for a single provider.
allowed_addresses: Vec<String>
CIDR or IPs that traffic is accepted from. An empty list means all inbound traffic is accepted.
allowed_numbers: Vec<String>
Numbers that are allowed to make calls to this Trunk. An empty list means calls from any phone number is accepted.
auth_username: String
Username and password used to authenticate inbound SIP invites. May be empty to have no authentication.
auth_password: String
§headers: HashMap<String, String>
Include these SIP X-* headers in 200 OK responses.
headers_to_attributes: HashMap<String, String>
Map SIP X-* headers from INVITE to SIP participant attributes.
attributes_to_headers: HashMap<String, String>
Map LiveKit attributes to SIP X-* headers when sending BYE or REFER requests. Keys are the names of attributes and values are the names of X-* headers they will be mapped to.
include_headers: i32
Map SIP headers from INVITE to sip.h.* participant attributes automatically.
When the names of required headers is known, using headers_to_attributes is strongly recommended.
When mapping INVITE headers to response headers with attributes_to_headers map, lowercase header names should be used, for example: sip.h.x-custom-header.
ringing_timeout: Option<Duration>
Max time for the caller to wait for track subscription.
max_call_duration: Option<Duration>
Max call duration.
krisp_enabled: bool
§media_encryption: i32
Implementations§
Source§impl SipInboundTrunkInfo
impl SipInboundTrunkInfo
Sourcepub fn include_headers(&self) -> SipHeaderOptions
pub fn include_headers(&self) -> SipHeaderOptions
Returns the enum value of include_headers
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_include_headers(&mut self, value: SipHeaderOptions)
pub fn set_include_headers(&mut self, value: SipHeaderOptions)
Sets include_headers
to the provided enum value.
Sourcepub fn media_encryption(&self) -> SipMediaEncryption
pub fn media_encryption(&self) -> SipMediaEncryption
Returns the enum value of media_encryption
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_media_encryption(&mut self, value: SipMediaEncryption)
pub fn set_media_encryption(&mut self, value: SipMediaEncryption)
Sets media_encryption
to the provided enum value.
Trait Implementations§
Source§impl Clone for SipInboundTrunkInfo
impl Clone for SipInboundTrunkInfo
Source§fn clone(&self) -> SipInboundTrunkInfo
fn clone(&self) -> SipInboundTrunkInfo
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for SipInboundTrunkInfo
impl Debug for SipInboundTrunkInfo
Source§impl Default for SipInboundTrunkInfo
impl Default for SipInboundTrunkInfo
§impl<'de> Deserialize<'de> for SipInboundTrunkInfo
impl<'de> Deserialize<'de> for SipInboundTrunkInfo
§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Source§impl Message for SipInboundTrunkInfo
impl Message for SipInboundTrunkInfo
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>
fn decode<B>(buf: B) -> Result<Self, DecodeError>
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
self
.