beautypg.com

Teletronics Enterprise SIP Server User Manual

Page 21

background image

TELETRONICS INTERNATIONAL, INC.

20

Enterprise SIP Server Tutorial – Dial Plan

s-tut-dp1.51-041228

3.10. Filtering based on the Number of Forwards (Number of Hops)

The number of forwards value decreases at every server. The number of forwards value can be
found in the Max-Forwards: header field.

3.10.1. If the number of forwards left is less than 5, refuse the call

Matching Patterns

Deploy Patterns

$request=^INVITE
max-forwards=^[0-5]$

$action=603

3.10.2. If the number of forwards left is between 50 and 99, the value will be set to 10

Matching Patterns

Deploy Patterns

$request=^INVITE
max-forwards=^[5-9].$

max-forwards=10

3.11. Filtering based on Time

The time which the server receives the call can be found in $time. The format is “hh:mm:ss”.

3.11.1. Route all calls from 7 pm to 10 am of the following day to sip:ivr@domain

Matching Patterns

Deploy Patterns

$request=^INVITE
$time=^1[0-8]:
to=sip:(.+)[ >;]*

to=sip:%1

$request=^INVITE

to=sip:ivr@domain

3.11.2. Change the router destination between gw1 and gw2, every 30 minutes

Matching Patterns

Deploy Patterns

$request=^INVITE
$time=^..:[0-2].:..$

$target=gw1

$request=^INVITE

$target=gw2

3.12. Filtering based on Date

The date the server received the call can be found in $date. The format is “yyyy/mm/dd”

3.12.1. If it is the 1st of the month, refuse the call

Matching Patterns

Deploy Patterns

$request=^INVITE
$date=/01$

$action=603