Hi everyone,
We are using Retell AI with a custom SIP trunk from peoplefone / PLFON.
Inbound calls to Retell work correctly. Call transfer also works in one configuration.
The issue is with forwarded inbound calls.
Scenario:
Caller +48XXXXXXXXX calls an Orange mobile number +48YYYYYYYYY.
That Orange number has unconditional call forwarding to our peoplefone / Retell number +48739104349.
Retell answers the call.
Our SIP provider confirmed that they send the following header in the INVITE to Retell:
Diversion: sip:48YYYYYYYYY@85.194.242.49;reason=unconditional
However, in the Retell call_analyzed webhook we only receive:
custom_sip_headers: {
“x-lk-call-info”: “…”,
“x-lk-real-ip”: “…”,
“x-lk-transport”: “tcp”
}
We do not see the Diversion header in the webhook.
Questions:
- Does Retell expose inbound SIP Diversion headers anywhere?
- Should Diversion appear in call.custom_sip_headers?
- Does Retell only expose X-* SIP headers?
- Has anyone solved this by asking the SIP provider to copy Diversion into X-Original-Called-Number or X-Diversion?
We need to identify which real estate agent’s phone number forwarded the call to the AI agent.