Exotel Virtual SIP Trunking – FQDN-based
This support article explains how to configure Exotel’s Virtual SIP Trunking (vSIP) using Fully Qualified Domain Name (FQDN) based trunking instead of fixed IPs. It details how the FQDN-based approach works, when it should be used, and why it offers benefits in enterprise-grade SIP deployments.
1. Product Overview
Exotel’s FQDN-based Virtual SIP Trunking allows customers to use DNS-resolvable hostnames (e.g., trunk.customer.com) instead of static IPs to establish SIP trunking with Exotel's PoPs. This method enables greater flexibility and reliability, especially for deployments on cloud infrastructure or load-balanced SIP setups.
2. What is an FQDN-based Trunk?
An FQDN (Fully Qualified Domain Name) is a domain name that maps dynamically to one or more IPs. In this model:
- Your SIP gateway/SBC is reachable via a DNS-resolvable FQDN
- Exotel performs DNS resolution during SIP call setup
- No static IP whitelisting is required from customer side
Exotel supports both static FQDN and dynamic DNS-based FQDN approaches.
3. When to Use FQDN Instead of Static IP
Scenario | Recommendation |
|---|---|
SIP infra hosted on cloud (AWS, Azure, GCP) | Use FQDN |
Customer SBC has load balancer or HA proxy | Use FQDN |
IP addresses change due to autoscaling/load shifting | Use FQDN |
On-prem setup with fixed static IPs | Use static IP |
FQDN is best suited when your IP address is not guaranteed to remain fixed or you have redundant/public-facing SIP endpoints.
4. How It Works
- Customer provides an FQDN that resolves to their SBC/public SIP gateway.
- Exotel adds this FQDN in the trunk configuration.
- During each SIP call, Exotel queries DNS to resolve the IP.
- Call is routed based on the returned A/AAAA record(s).
Note: Exotel performs DNS resolution on each call attempt to support failover and dynamic environments.
Note – vSIP Throttling
Exotel enforces a default vSIP rate-limit of 20 calls per minute (CPM) per trunk to safeguard carrier capacity and call quality.
If your traffic profile requires a higher burst rate, raise a request via your CSM or Support ticket. The capacity-planning team will review historical traffic, carrier limits, and QoS requirements and can increase the throttling threshold accordingly.
5. Configuration Requirements
On Customer Side
- Expose SIP server using a public FQDN (e.g., sip.companydomain.com)
- Ensure DNS A or AAAA records point to valid, routable IP(s)
- SIP server must be reachable on TCP or TLS as applicable
- Support G.711 codecs and standard RTP port ranges
On Exotel Side (done by Exotel Ops)
- Default:Trunk is configured with FQDN instead of IP
- Default:DNS lookups are enabled in trunk routing logic
- Default:Media IP range is kept open as per standard PoP setup
6. SIP Trunk Parameters (via FQDN)
Sample Configuration (Asterisk)
[general]
externip = <your_public_ip>
localnet = 192.168.0.0/16
[exotelvsip-fqdn]
type = friend
context = incoming
fromdomain = <accountsid>.pstn.exotel.com
host = sip.customerdomain.com
port = 5070 ; or 443 for TLS
transport = tcp ; or tls if using encrypted trunk
disallow = all
allow = alaw
allow = ulaw
nat = force_rport
insecure = port
canreinvite = no
sendrpid = yes
trustrpid = yes
relaxdtmf = yes
encryption = yes ; only if using TLS with SRTP
SIP Parameters Summary
Parameter | Example |
|---|---|
SIP Peer FQDN | sip.customerdomain.com |
Port | 5070 (TCP) / 443 (TLS) |
Transport | TCP or TLS |
Media IP Range | 10000–40000 (UDP) |
DNS Record Type | A (IPv4) / AAAA (IPv6) |
Parameter | Example |
|---|---|
SIP Peer FQDN | sip.customerdomain.com |
Port | 5070 (TCP) / 443 (TLS) |
Transport | TCP or TLS |
Media IP Range | 10000–40000 (UDP) |
DNS Record Type | A (IPv4) / AAAA (IPv6) |
7. Advantages of FQDN-based Approach
- No need for IP whitelisting: Reduces manual ACL changes
- Supports redundancy: Load balancer IPs can be rotated behind the same FQDN
- Cloud-friendly: Ideal for cloud-native SIP deployments
- Failover-friendly: Multiple A-records supported for active/passive routing
8. Best Practices
- TTL for DNS entries should be low (e.g., 30s–60s) for fast failover
- Use reliable DNS hosting with high availability
- Ensure SIP firewall rules allow calls from Exotel media IPs
- Avoid using CNAME records for SIP endpoints (use A/AAAA directly)
8.1 SIP Message Format and Header Behavior
SIP Message Format (FQDN Mode – TCP Transport)
A. INVITE from Exotel to Customer via FQDN (Inbound)
This is how Exotel delivers a call to your SBC or PBX using a public DNS hostname instead of a static IP.
Sample INVITE (Inbound via FQDN)
Sip
INVITE sip:[email protected]:5070;transport=tcp SIP/2.0
Via: SIP/2.0/TCP <Exotel Edge Domain>;branch=...
From: "+91AAAAAAAAAA" <sip:[email protected]>
To: sip:[email protected]
Call-ID: abcd1234efgh@<Exotel Edge Domain>
CSeq: 102 INVITE
Contact: sip:+91AAAAAAAAAA@<exotel-media-ip>:port;transport=tcp
X-Exotel-CallSid: <auto-generated-by-exotel>
X-Exotel-LegSid: <leg-id>
X-Exotel-TrunkSid: <trunk-id>
P-Asserted-Identity: sip:+91AAAAAAAAAA@<Exotel Edge Domain>
P-Early-Media: supported
Content-Type: application/sdp
Content-Length: ...
Inbound SIP Header Reference (Exotel → Customer via FQDN)
Header | Mandatory | Description |
|---|---|---|
Request URI | Yes | Your registered Exophone and SIP FQDN |
Via | Yes | Exotel’s signaling IP + transport (TCP) |
From | Yes | Caller CLI (could be real, masked, or Exophone) |
To | Yes | Your PBX’s FQDN URI target |
Call-ID | Yes | Dialog identifier for SIP trace correlation |
CSeq | Yes | Command sequence, starts with INVITE |
Contact | Yes | Exotel’s signaling contact (for BYE, ACK, etc.) |
Content-Type | Yes | application/sdp |
Content-Length | Yes | SDP payload length |
Max-Forwards | Yes | Loop control |
X-Exotel-CallSid | Yes | Exotel’s global call ID — key for webhook/CDR correlation |
X-Exotel-LegSid | Yes | Call leg identifier |
X-Exotel-TrunkSid | Yes | Identifies the virtual SIP trunk provisioned to you |
P-Asserted-Identity | Yes | Validated CLI presented by Exotel |
P-Early-Media | Optional | Indicates early RTP media (if Exotel connects media pre-200 OK) |
Key take-aways for FQDN mode
- DNS resolution – Exotel resolves your FQDN on every call; keep TTL ≤ 60s for rapid fail-over.
- Certificates (TLS) – For secure trunks, your SBC’s cert CN/SAN should match the FQDN Exotel is dialling.
- Logging – Always capture X-Exotel-CallSid + Call-ID to join SIP pcaps with Exotel dashboards.
9. Troubleshooting
Issue | Cause | Fix |
|---|---|---|
Call fails to reach SBC | FQDN not resolving or DNS TTL delay | Use dig/nslookup to verify resolution |
One-way audio | Media ports blocked | Open UDP 10000–40000 |
Repeated 408 errors | DNS record TTL mismatch | Reduce DNS TTL and ensure IP is reachable |
10. Support
For FQDN-based trunk configuration:
- Share your FQDN and port with your Exotel account manager
- Exotel will provision the trunk using DNS-based routing
- Test connectivity using SIPp, sngrep, or call traces
For help:
- Contact support.exotel.com with FQDN, DNS setup, and logs