when making an outbound call, how do I pass proper...
# ask-ai
p
when making an outbound call, how do I pass properties, so that the telephony system on the destination can grab it?
t
Thanks for reaching out, Mario. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
I'm happy to guide you through passing properties during an outbound call so the destination telephony system can easily retrieve them. You can achieve this by using SIP headers and participant attributes: • Custom SIP Headers: You can include custom headers (like
X-Custom-Property
) in the SIP INVITE request by using the
headers
field when creating a SIP participant. Here’s an example to illustrate:
Copy code
{
  "sip_trunk_id": "trunk_123",
  "sip_call_to": "+1234567890",
  "room_name": "call_room",
  "headers": {
    "X-Client-ID": "abc123",
    "X-Custom-Data": "priority:high"
  }
}
• The destination system can then parse these headers to extract the properties you’ve sent. • Mapping SIP Headers to Participant Attributes: You can also configure
headers_to_attributes
to map specific SIP headers directly to participant attributes within LiveKit, which can be really handy. • Provider Configuration: Just a heads-up—make sure your SIP trunk provider supports custom header passthrough, as some may block or strip non-standard headers. If you’d like, I’m here to help you with any part of the implementation or testing process. Just let me know! Sources: SIP overview | LiveKit Docs | SIP APIs | LiveKit Docs | SIP participant | LiveKit Docs | livekit-protocol/livekit/protocol/sip.pyi | Preserving Caller ID During SIP Transfers in LiveKit Agents
p
If I call zoom from livekit, would it get those properties?
t
I'm happy to share that LiveKit can send custom SIP headers when making an outbound call to Zoom. These headers are included in the SIP INVITE request and can carry the properties you define, giving you some great flexibility. That said, whether Zoom accepts and processes these headers really depends on its SIP endpoint configuration and capabilities. Since this isn’t clearly detailed in the available documentation, I’d recommend checking out Zoom's SIP documentation or trying a direct test of the integration. This way, you can be sure if the properties are received and used as you expect. Sources: SIP overview | LiveKit Docs | SIP APIs | LiveKit Docs | protobufs/rpc/io.proto
p
what about sip_number from CreateSIPParticipantRequest, what does it do?
t
Hey there! Just wanted to help clarify the
sip_number
field in
CreateSIPParticipantRequest
for you. This field is where you specify the caller ID (the "from" number) that the person receiving the outbound SIP call will see. • If you leave this field empty, no worries—the system will automatically use the default trunk number linked to your SIP trunk as the caller ID. • This feature is super handy in situations like SIP transfers, where you might want to keep the original caller's phone number visible instead of showing the transferring agent's number. • Just a heads-up: whether you can set a custom caller ID depends on if your SIP trunk provider supports arbitrary caller ID passthrough. Sources: SIP APIs | LiveKit Docs | livekit/livekit_sip.pb.go | Preserving Caller ID During SIP Transfers in LiveKit Agents