Skip to main content

<Diversion>

TL;DR

Specify the SIP Diversion header to be used for an outbound trunk call from a <Dial> verb.

Need Help? Let's Talk

Join our Discord community - we're here to help.

Description

Specifies that a <DIAL> operation, directed to an outbound trunk, should send a Diversion header with the specified telephone number. The domain for the Diversion header will be the current domain name and an optional reason tag may also be provided - that must be one of the RFC 5806 section 4 approved reason codes.

Example

 <?xml version="1.0" encoding="UTF-8"?>
<Dial>
<Diversion reason="follow-me">+12125555</Diversion>
<Sip>sip:1234@example.com</Sip>
</Dial>

Attributes

The following attributes are supported:

Attribute NameAllowed ValuesDefault Value
reasonunknown, user-busy, no-answer, unavailable, unconditional, time-of-day, do-not-disturb, deflection, follow-me, out-of-service, awayNone

When adding a <Diversion> noun inside the <Dial> verb, if valid - i.e. its text content must be a valid E.164 phone number, including the + prefix - a Diversion SIP header will be set in the outgoing dial - when dialing an outbound trunk.

The format for the value of the Diversion header will be:

Diversion: {phonenumber}@{domain}[;reason={reason}]