Hello Support Team,We are currently trying to inte...
# support
t
Hello Support Team, We are currently trying to integrate Vapi with a Karel PBX through a SIP trunk, and we are facing an issue related to SIP REGISTER/signaling format compatibility. When we inspect the SIP REGISTER message generated from the Vapi side, it is currently being sent in a structure like this: *
REGISTER sip:tolunaydin.connect.com SIP/2.0
*
Via: SIP/2.0/UDP 34.213.129.25
*
From: <sip:1000@fe791a92-81a7-4b7a-a33a-9f13acb964fe.sip.vapi.ai>
*
To: <sip:1000@fe791a92-81a7-4b7a-a33a-9f13acb964fe.sip.vapi.ai>
However, for Karel to properly track and associate the active call, the SIP signaling needs to be in a structure closer to the following format: *
REGISTER sip:tolunaydin.connect.com:5080 SIP/2.0
*
Via: SIP/2.0/UDP 10.40.44.13:54548
*
Route: <sip:test1connect.karel.cloud:5080;lr>
*
From: "1000" <sip:1000@tolunaydin.connect.com>
*
To: "1000" <sip:1000@tolunaydin.connect.com>
The main concern is that the current Vapi-generated REGISTER message uses the
sip.vapi.ai
domain in the From/To headers and a different Contact format, while Karel expects the registration and signaling to be associated with our trunk/domain structure in order to correctly monitor and match the active call. Could you please confirm: 1. Whether the REGISTER / SIP signaling format can be customized on the Vapi side 2. Whether the Request-URI can include the required port, such as
:5080
3. Whether the From / To / Contact headers can be rewritten to match the trunk domain 4. Whether adding a Route header is supported 5. Whether there is any recommended configuration for compatibility with Karel PBX systems This signaling/header compatibility is critical for Karel to properly track and associate active calls. Thank you in advance for your support.
v
Thank you for the detailed description. To help us provide the most accurate guidance, could you please confirm whether you are using a "BYO SIP trunk" configuration in Vapi, and if so, have you already specified the gateway IP and port (e.g.,
5080
) in your trunk setup? Sources: - [Vapi SIP Trunk Documentation](https://docs.vapi.ai/advanced/sip/sip-trunk) - [Vapi SIP Networking Reference](https://docs.vapi.ai/advanced/sip/sip-networking) - [Vapi SIP Trunk Troubleshooting](https://docs.vapi.ai/advanced/sip/troubleshoot-sip-trunk-credential-errors)
m
Yeah, you’re right to flag this, Karel usually relies on consistent From/To and domain matching, so Vapi’s default sip.vapi.ai format can break call tracking. From experience, Vapi doesn’t give much control over REGISTER or header rewriting, so people typically fix this with a SIP proxy (like OpenSIPS/Kamailio) in between. That also helps handle the port in the Request-URI and adding Route headers cleanly. Would you be open to using a SIP proxy, or are you trying to keep it as a direct connection only? @Tudoshiy
t
hey mate i want to make it with proxy , could you please help me how to do that
or if there is another way to do that with direct connection can you share details
c
Hi Tudoshiy, Thank you for the detailed breakdown. Here are answers to each of your questions: 1. Can the REGISTER / SIP signaling format be customized? Partially. When creating a BYO SIP Trunk credential, you can configure a
sipRegisterPlan
under
outboundAuthenticationPlan
with
domain
,
username
, and
realm
fields to influence the REGISTER message format. SIP signaling will continue to follow the
<phone_number>@<credential_id>.sip.vapi.ai
format 2. Can the Request-URI include a custom port like `:5080`**?** Yes. Set
port: 5080
on your gateway object in the
gateways
array of your BYO SIP Trunk credential. This is fully supported (range 1–65535, default 5060). 3. Can From / To / Contact headers be rewritten to match your trunk domain? The
sipRegisterPlan.domain
field is designed for this purpose. Setting
domain: "tolunaydin.connect.com"
along with the appropriate
username
and
realm
should influence the From/To headers sent in the REGISTER. 4. Is adding a Route header supported? Not currently. This is not an available configuration option at this time. 5. Is there a recommended configuration for Karel PBX? We don't have Karel-specific guidance. We recommend configuring your BYO SIP Trunk with the gateway
port
set to
5080
, and using the
sipRegisterPlan
fields (
domain
,
username
,
realm
) to align the REGISTER headers with what Karel expects. If any of these capabilities don't meet your needs or you'd like to request enhancements (such as Route header support), please submit a feature request here: https://roadmap.vapi.ai/feature-requests Thank you for reaching out.