Home
/
Learn
/
Voice AI integrations and setup
/
SIP Trunking: How to Keep Your Existing Phone Number
Integration
5
 MIN READ

SIP Trunking: How to Keep Your Existing Phone Number

SIP trunking lets you keep your existing phone number and route its calls to Athena. Set up origination, import the number, and test it on Twilio or Telnyx.

ON THIS PAGE

SIP trunking lets you keep your existing business phone number with the carrier you already use and route its calls to a voice agent over the internet, so nothing about the number changes for your customers. With Athena, you point your carrier's SIP trunk at Athena's SIP server, import the number into the Athena dashboard, and bind an agent to it. You do not port the number, and the carrier keeps billing you for it as before.

Athena supports two methods. Elastic SIP trunking is the recommended one and works with most carriers. Dial to SIP URI is the fallback for carriers or phone systems that cannot do elastic trunking.

What is SIP trunking, and how does it keep your number?

SIP (Session Initiation Protocol) is the signaling standard most internet phone systems use to set up and end calls. A SIP trunk is a virtual line between your carrier and another system. Your number stays assigned to your carrier; the trunk decides where calls to that number go.

A trunk has two directions, configured in two places:

  • Origination (inbound): calls flowing from your carrier into Athena. In your carrier's trunk settings, set the origination SIP URI to Athena's SIP server.
  • Termination (outbound): calls flowing from Athena out through your carrier. Your carrier gives you a termination SIP URI for the trunk, and you enter it in Athena when you import the number.

Athena has no termination URI of its own. Your Athena SIP address is its only SIP address, and it is used on your carrier's side as the origination target.

SIP trunking vs porting vs a new Athena number

You have three ways to put an agent on a phone line. The right one depends on whether you want to keep your carrier relationship.

  • Elastic SIP trunking: Where the number lives: Stays with your carrier. Best when: You want to keep the number, carrier and rates.
  • Dial to SIP URI: Where the number lives: Stays in your own phone system. Best when: Your carrier cannot do elastic trunking.
  • Port the number: Where the number lives: Moves to a new carrier. Best when: You are changing carriers anyway.
  • Athena-managed number: Where the number lives: Bought in Athena (US and Canada). Best when: You need a new number quickly.

Point your carrier's SIP trunk at Athena

Before you import anything, make sure your carrier's trunk can reach Athena and accept traffic back from it. Most carriers require you to allowlist the far end.

  • Set the trunk's origination URI to your Athena SIP address
  • Allowlist signaling from 18.98.16.120/30
  • Allowlist 3.42.144.0/23 and 153.57.128.0/18 (all regions)
  • Allowlist 143.223.88.0/21 and 161.115.160.0/19 (certain US traffic)
  • Open RTP/RTCP on UDP ports 10000 to 65535
  • Offer the PCMU, PCMA or G.722 codec
  • Note your termination URI and any trunk username and password

Athena supports TCP (recommended), UDP, TLS and mTLS. To force a transport on inbound calls, append it to the URI, for example sip:<your-athena-sip-address>;transport=tcp. Media encryption with SRTP requires TLS transport. mTLS is configured on request through Athena support. The custom telephony docs list the current IP blocks and supported SRTP crypto suites.

Import the number into Athena and test the connection

In the Athena dashboard, open Phone Numbers, click +, and choose Connect to your number via SIP trunking. Enter:

  • The phone number in E.164 format.
  • Your carrier's Termination URI.
  • Outbound Transport.
  • SIP Trunk User Name and SIP Trunk Password, if your carrier uses credential authentication instead of an IP allowlist.

Click Test SIP Connection before saving. Athena sends a SIP OPTIONS request to your termination URI without placing a call. A 401 or 407 means the credentials are missing or wrong, a 403 usually means your carrier's IP allowlist is blocking Athena, and no response points to the host, port, transport or a firewall.

A passing SIP test does not prove calls work. Test SIP Connection only checks that your termination URI answers an OPTIONS request. Place a real inbound call and a real outbound call before you move production numbers.

Click Save, then bind an inbound agent, an outbound agent or both. A number only takes calls in a direction once an agent is bound to it. You can also import numbers programmatically through the Import Number API.

Setup notes for Twilio, Telnyx and Vonage

The pattern is the same everywhere, but each carrier names things differently:

  • Twilio: create an Elastic SIP Trunk, use a localized termination URI near your region (format: your-trunk-domain.pstn.edge.twilio.com, for example my-athena-trunk.pstn.ashburn.twilio.com), allowlist 18.98.16.120/30 or add credentials, and set origination to your Athena SIP address. To dial abroad, enable the country under Voice Geographic Permissions for Elastic SIP Trunking.
  • Telnyx: create an FQDN trunk pointing at your Athena SIP address with an SRV record, use credential authentication, choose +E.164 number format, the G722, G711U and G711A codecs, and TCP. Telnyx requires an X-Telnyx-Username header on outbound calls, which you add as a custom SIP header in Athena.
  • Vonage: in the SIP section choose "Something else" as the provider type, note the termination URI, username and password, and set origination to your Athena SIP address.

Running a contact center platform instead of a plain carrier? Athena documents dedicated paths for Five9, Genesys Cloud, Avaya and Amazon Connect. Five9 uses a pre-built trunk, and you import the pseudo number Five9 provisions, not the customer-facing number.

What if your carrier cannot do elastic SIP trunking?

Use the dial to SIP URI method. Your own system receives the call, calls Athena's Register Phone Call API to get a call ID, and dials the call to sip:{call_id}@<your-athena-sip-address>. The dial must happen within 5 minutes of registering, or the call disconnects with a registered_call_timeout reason.

The trade-off is control. Athena cannot transfer or end the call on your carrier, because it never sees the number, so you build transfers yourself and trigger them with a custom function. The per-number inbound webhook also does not apply, since you pass call context when you register the call.

Keep transfers and caller context working over the trunk

Transfers work over an elastic SIP trunk. For a cold transfer using SIP REFER, your carrier must allow SIP REFER and PSTN transfer on the trunk; on Twilio this is a trunk setting. How call transfers work between voice agents and human teams explains when to use cold or warm transfers.

Your phone system can also pass context in. Athena turns inbound SIP headers starting with X-, plus Diversion, History-Info, User-to-User and P-Asserted-Identity, into dynamic variables the agent can use. For per-call decisions, set an Inbound Webhook URL on the number to choose the agent or set variables before the call connects. If all concurrency slots are busy for about 40 seconds, Athena forwards the call to the number's fallback number when one is set.

Once calls are flowing on your own number, the agent can greet callers from your CRM; see how to connect Athena to HubSpot. A common first deployment is an AI answering service on the main line customers already know. For outbound calling, the outbound voice AI phone number checklist covers caller ID, spam labels and the IT steps.

For outbound calls from your number, verified phone numbers and branded caller ID help people recognize who is calling, and a VoIP answering service is a common first inbound use.

Set up a test number on your trunk first, then move production numbers once inbound and outbound calls both check out. Open the Athena dashboard to import your first number.