Caller Number Displayed Not Caller Name

bc24fl

Bronze Partner
Basic Certified
Joined
Jan 9, 2020
Messages
20
Reaction score
1
We're using 3cx v20 upgraded to the latest stable version with a twilio trunk where we also subscribe to cnam database lookup however the incoming callers id "name" is not displayed only the phone number. Is there something in the trunk settings that need to be changed to get this functionality to work? I checked the activity log on a verbose setting and it does show the name of the business like so:

From: "COMPANY NAME" <sip:[email protected]>;tag=dfgf87

Appreciate any insights, thanks!
 
In v18, you had to change the inbound parameters so that "From : Display Name" had Display Name selected.

In v20, it looks like this was moved under the Caller ID control section of the trunk. We just upgraded to v20 on Monday.

Try changing the boxed setting below.

1737048832582.png
 
  • Like
Reactions: bc24fl
I don't see any effect, not sure if I should refresh the Trunk (something I should wait until after hours). Are you sure it's not "CallerName" as in the screenshot?
 

Attachments

  • 3cx-callerid.png
    3cx-callerid.png
    36.1 KB · Views: 67
I don't see any effect, not sure if I should refresh the Trunk (something I should wait until after hours). Are you sure it's not "CallerName" as in the screenshot?
It’s possible that 3CX changed the way these mappings are interpreted, and it may now be CallerName. You can try cycling though some of those options to see if the CNAM appears on your phones.

As long as it’s also enabled in the Twilio trunk settings in the Twilio console, it should be instant once the right mapping is selected.
 
  • Like
Reactions: Evolute IT
I found a temporary resolution on this forum article: "Twilio Incoming CNAM on V20". The Twilio templates for incoming call parameters are wrong. There are 3 lines in the 2 template files (twilio.pv.xml and twilioauto.pv.xml) that read as follows:
<!-- Gateway / Provider Inbound Parameters -->
<field name="ParameterIn" custom="" parameter="ToUserPart">$CalledNum</field>
<field name="ParameterIn" custom="" parameter="FromUserPart">$CallerName</field>
<field name="ParameterIn" custom="" parameter="FromUserPart">$CallerNum</field>
They should read as follows:
<!-- Gateway / Provider Inbound Parameters -->
<field name="ParameterIn" custom="" parameter="FromUserPart">$CallerNum</field>
<field name="ParameterIn" custom="" parameter="FromDisplayName">$CallerName</field>
<field name="ParameterIn" custom="" parameter="ToUserPart">$CalledNum</field>

Further, I had to then, for some reason, recreate the Twilio trunk in 3cx, and then alter the trunk Options \ Caller ID Control \ From : Display Name to be "CallerName".

Here's hoping 3cx revises this in an upcoming update to v20.
I'm running a new install of Version 20.0 Update 5 (Build 506 Beta)
 
  • Like
Reactions: acontreras
@Ron Gladski Thanks for this. We have the same issue on Twilio.
 
  • Sad
Reactions: acontreras
@Ron Gladski Thanks for this. We have the same issue on Twilio.
Hi Jim and Ron

Were you able to make it work, we are having the same issue and having a hard time.

We enabled CNAM Lookup on Twilio
We implemented a template provided by 3CX (not the regular, a different one for the extra paid feature)
Our trunking options --> caller ID control settings are included on image below.

If anyone has any tip or extra information, maybe someone can share their working temple, we will appreciate it.

Our system is cloud base hosted (amazon aws)
Version 20.0 Update 5 (Build 551 Release)
Professional license
8GB RAM
60 GB HD (50% free)

Mobile client receiving calls
iPhone app, latest version.
Yealink T53W, latest version

Regards,

Antonio
 

Attachments

  • Screenshot from 2025-04-09 19-00-53.png
    Screenshot from 2025-04-09 19-00-53.png
    133.2 KB · Views: 64
  • Screenshot from 2025-04-09 19-05-58.png
    Screenshot from 2025-04-09 19-05-58.png
    54.4 KB · Views: 64
3CX has since overwritten the Twilio template files with recent upgrades. They have yet to address the bug in the template. I don't know what's up with this...
 
Months ago I opened a ticket with 3CX, and they told me had to be addressed by Twilio, I asked Twilio, and they said any changes will need to be requested by the Eng channel, 3CX.

:(
 
I suspect 3CX writes the templates as it's for their architecture, not the SIP providers (Twilio, etc.). Does anybody at 3CX look at these threads or respond to requests to fix a known bug??
 
Anyone figure out a fix to this yet?
 
You can try this template, remember only pro and ent licenses can import templates


<?xml version="1.0"?>
<doc xmlns:tcx="http://www.3cx.com">
<header>
<type>gateway-template</type>
<version>150001</version>
<time>2025-02-14 09:30:00</time>
<name>Twilio (Auto-setup)</name>
<url>https://www.3cx.com/docs/sip-trunk/twilio/</url>
<image>default-icon.png</image>
<logo>default-logo.png</logo>
<description>AR,AT,AU,BE,BG,BR,CA,CH,CL,CN,CY,CZ,DE,DK,ES,FR,GR,HK,HR,HU,IE,IL,IN,IS,IT,JP,LT,LV,MT,MX,MY,NL,NO,NZ,PE,PL,PT,RO,RU,SE,SG,SI,SK,TH,TR,UA,UK,US,VN,Worldwide,ZA</description>
<priority>2</priority>
<tags>e164,registrar,port</tags>
<templatetype>preferred</templatetype>
</header>
<data>
<sms>
<variable name="MESSAGING_SID">
<title>ACCOUNT_SID</title>
<option name="Messaging Account SID" required="true" maxlength="60" type="textbox"></option>
</variable>
<variable name="MESSAGING_TOKEN">
<title>AUTH_TOKEN</title>
<option name="Auth token" secure="true" required="true" maxlength="100" type="password"></option>
</variable>
<field name="MessagingUrl" status="readonly">https://api.twilio.com/2010-04-01/Accounts/{MESSAGING_SID}/Messages.json</field>
<field name="ProviderName" status="readonly">Twilio</field>
<field name="OptionalProvider" status="readonly">1</field>
<field name="ProviderType" status="readonly">twilio</field>
<field name="OutboundRouting" status="readonly">1</field>
<field name="HasWebhook" status="readonly">1</field>
</sms>
<device>
<type>provider</type>
<manufacturer>Twilio (Auto-setup)</manufacturer>
<model>Provider</model>

<!-- Friendly Name -->
<field name="Name">Twilio (Auto-setup)</field>

<!-- Hostnames and Port Numbers -->
<field name="RegistrarHost">[TERMINATION SIP URI].pstn.twilio.com</field> <!-- Registrar & Proxy IP / FQDN -->
<field name="RegistrarPort">5060</field> <!-- Registrar & Proxy Port Number -->
<field name="ProxyHost"></field> <!-- Proxy IP / FQDN -->
<field name="ProxyPort">5060</field> <!-- Proxy Port Number -->
<field name="StunServerHost"></field> <!-- StunServer IP / FQDN -->
<field name="StunServerPort"></field> <!-- StunServer Port Number -->

<!-- Registration Settings -->
<field name="LineAuthenticationPassword" status="readonly"></field>
<field name="TimeBetweenRegistration">600</field> <!-- Registration Expiry -->
<field name="RequireAuthFor">1</field> <!-- No=1; In=2; Out=3; Both=4 -->
<field name="IpInContactReg">1</field> <!-- Ext=1; Int=2; Both=3; Specified=4 -->
<field name="IpInContactRegValue"></field> <!-- List of PBX IPs -->
<field name="3wayauthenticationid" status="readonly"></field> <!-- Entry to enable 3 way authentication-->

<!-- Provider Capabilities -->
<field name="IsSupportReinvite">0</field> <!-- Yes=1; No=0 -->
<field name="IsSupportReplaces">0</field> <!-- Yes=1; No=0 -->
<field name="DisableVideo">1</field> <!-- Yes=1; No=0 -->

<!-- Location of Destination Number -->
<field name="DestNumberIn_TO">1</field> <!-- Yes=1; No=0 -->
<field name="DestNumberIn_REQLINEURI">1</field> <!-- Yes=1; No=0 -->
<field name="DestNumberIn_RPID_CALLED">0</field> <!-- Yes=1; No=0 -->

<!-- Other Options -->
<field name="IPRestriction">ANY</field> <!-- Restricts IPv4 or IPv6. Values: ANY, IPV4, IPV6 -->
<field name="TransportRestriction">UDP</field> <!-- Restricts the Transport Protocol. Values: ANY, UDP, TCP, TLS -->
<field name="SecondaryRegistrar"></field> <!-- Possible values: FQDN:Port or IP:Port -->
<field name="IsBindToMS">1</field> <!-- Bound=1; NotBound=0 -->
<field name="UseIPInContact">0</field> <!-- UseIP=1; DoNotUseIP=0 -->
<field name="CallerIDIn">1</field> <!-- Fm=1; To=2; ReqURI=3; Con=4; RemPtyClg=6 -->
<field name="CalledNumberIn">2</field> <!-- Fm=1; To=2; ReqURI=3; Con=4; RemPtyCld=5 -->

<codecs>
<codec rfcname="pcmu"/>
</codecs>

<!--Source Identification - Use Default PBX Internal Source Identification-->
<!--<field name="MatchStrategy">1</field>-->
<field status="readonly" name="MatchStrategy">1</field>
<field status="readonly" name="Source" parameter="FromHostPart" custom="">$GWHostPort</field>

<!-- Gateway / Provider Inbound Parameters -->
<field name="ParameterIn" custom="" parameter="ToUserPart">$CalledNum</field>
<field name="ParameterIn" custom="" parameter="FromUserPart">$CallerName</field>
<field name="ParameterIn" custom="" parameter="FromUserPart">$CallerNum</field>

<!-- Gateway / Provider Outbound Parameters -->
<field name="ParameterOut" custom="" parameter="RequestLineURIUser">$CalledNum</field>
<field name="ParameterOut" custom="" parameter="RequestLineURIHost">$GWHostPort</field>
<field name="ParameterOut" custom="" parameter="ContactUser">$AuthID</field>
<field name="ParameterOut" custom="" parameter="ContactHost">$ContactURI</field>
<field name="ParameterOut" custom="" parameter="ToUserPart">$CalledNum</field>
<field name="ParameterOut" custom="" parameter="ToHostPart">$GWHostPort</field>
<field name="ParameterOut" custom="" parameter="FromDisplayName">$CustomField</field>
<field name="ParameterOut" custom="" parameter="FromUserPart">$OutboundCallerId</field>
<field name="ParameterOut" custom="" parameter="FromHostPart">$GWHostPort</field>
<field name="ParameterOut" custom="" parameter="RemotePartyIDCallingPartyUserPart">$OutboundCallerId</field>
<field name="ParameterOut" custom="" parameter="RemotePartyIDCallingPartyHostPart">$GWHostPort</field>
<field name="ParameterOut" custom="" parameter="P-AssertedIdentityUserPart">$OutboundCallerId</field>
<field name="ParameterOut" custom="" parameter="P-AssertedIdentityHostPart">$GWHostPort</field>
</device>
</data>
</doc>
 
Thanks man. I will definitely give it a try after hours and report back.
 
Looking forward to seeing the resolution for this. I also have the same issue since one of the V20 upgrades specifically with Twilio SIP. Hopefully.. I don't need to delete and rebuild the trunk with a custom template every time 3cx pushes and update.... ;)
 
I keeping getting this error when trying to import the XML file.

1764856853436.png
 
Pass it through some xml validator, perhaps a missing bracket or quote somewhere.
 
I did, and it said no errors were found. I have attached the XML file.

It's frustrating that you can no longer export from the provider tab any longer.
 

Attachments

Will be interested to see if that solves the problem as this was one of the things that I could not figure out at all :/
 
@sevenvoip Did you find any solution to this at all?
 

Forum statistics

Threads
111,974
Messages
590,081
Members
164,899
Latest member
mazet