Hey @dorawysocki
Thanks for the detailed explanation. Your overall setup is valid, and the issue appears to be with the phone-number formatting/mapping before the request reaches Retell rather than with the Retell agent or Twilio SIP trunk.
1. Can GoHighLevel / Agent CRM trigger Retell outbound calls through a webhook?
Yes. Retell’s outbound calling API is designed to be triggered programmatically using:
POST https://api.retellai.com/v2/create-phone-call
The request needs, at minimum, a valid from_number and to_number. Both are expected in E.164 format. Your existing custom webhook approach is therefore valid.
A basic request looks like:
{
"from_number": "+1XXXXXXXXXX",
"to_number": "+19142995003"
}
If your outbound agent is already assigned to the from_number, you do not necessarily need to pass the agent ID separately. You can also use override_agent_id when needed.
2. What is the most reliable way to make sure the phone number is E.164?
The best approach is to normalize the number inside GoHighLevel/Agent CRM before sending the webhook.
HighLevel currently provides a built-in Number Formatter workflow action with a Format Phone Number option. It allows you to select the phone field, choose E.164 as the output format, and specify the phone-number country code.
For your U.S. contacts, the workflow can be:
Contact Phone → Format Phone Number → E.164 → United States → Retell Webhook
For example:
(914) 299-5003
becomes:
+19142995003
Then map the formatted output, rather than the original {{contact.phone}}, into Retell’s to_number.
This would be preferable to maintaining custom JavaScript if the Number Formatter action is available in your Agent CRM workflow builder.
3. Can this be done without GoHighLevel Custom Code?
Yes. I would recommend trying HighLevel’s built-in Format Phone Number workflow action first.
That removes the need for your JavaScript normalization step and should also make the workflow easier to maintain.
The duplicated value you are seeing:
+19142995003+19142995003
is being created before the request reaches Retell. Retell only receives the final value supplied in to_number. I would therefore check the Custom Code input mapping or any preceding workflow step to make sure the phone field is not being inserted twice.
If you switch to the native Number Formatter action, the workflow would ideally be:
Contact/Trigger → Format Phone Number → Custom Webhook → Retell
4. Does Retell automatically normalize to_number on the API side?
Retell’s Create Phone Call API specifically requires to_number to already be in E.164 format, such as:
+12137774445
Retell also exposes an ignore_e164_validation option, but this does not solve this case. That option applies only to from_number when using custom telephony; it does not format or bypass validation for to_number.
So even if the Retell dashboard can help format a number when manually placing a call, you should not rely on equivalent normalization when calling /v2/create-phone-call. The API request should already contain the correctly formatted destination number.
Recommended setup
For your current integration, I would use:
Agent CRM / GoHighLevel contact
→ Format Phone Number action
→ Format: E.164
→ Country: United States
→ Custom Webhook
→ Retell /v2/create-phone-call
with the formatted output mapped directly to:
to_number
Your Twilio SIP trunk and Retell agent appear to already be working based on your successful direct Retell tests, so I would focus on fixing this workflow field mapping rather than changing the telephony configuration.
Retell’s outbound API documentation also notes that an invalid destination can fail when the number contains spaces, invalid characters, or does not meet the telephony provider’s expected format.
Best Regards.