DNIS, or Dialed Number Information Service lets your PBX know which number someone called in on. It's useful if you have multiple phone numbers belonging to different companies or departments handled by the same PBX. DNIS has a negative impact when routing for devices that don't understand DNIS.
DNIS in IVY
DNIS is sent based on the type of connection you use:
- DNIS is sent on calls to SIP Trunks
- DNIS is not sent on calls to Devices.
IVY DNIS formatting
DNIS is sent with a country code, like so:
13036298300 for a domestic US number
442033185511 for a United Kingdom number
DNIS will be sent exactly as listed in your site's Phone numbers:
How does DNIS work?
A normal SIP INVITE looks kind of like this:
U 2009/07/14 10:34:58.896453 184.108.40.206:5060 -> 220.127.116.11:5060
INVITE sip:email@example.com SIP/2.0.
Via: SIP/2.0/UDP 18.104.22.168;rport;branch=z9hG4bKg2XaUm08c9g1D.
From: "TELIAX FAX" <sip:firstname.lastname@example.org>;tag=3DX89NUrNm4SS.
but if we want to know what number they called, we enable DNIS and the INVITE changes to look like this:
U 2009/07/14 10:36:11.733727 22.214.171.124:5060 -> 126.96.36.199:5060
INVITE sip:email@example.com SIP/2.0.
Via: SIP/2.0/UDP 188.8.131.52;rport;branch=z9hG4bK4meSgDB1302tr.
From: "TELIAX FAX" <sip:firstname.lastname@example.org>;tag=ceHmH3r87rr0j.
Do you see the difference? Instead of sending the call to a user, we send it to a number. It's then up to your PBX to decide where to route the call.
If you have an ATA or a softphone, it usually only understands INVITEs sent with a username. If DNIS is enabled, your device may reply with a 404 Not Found and the call will fail.