How can we help? 👋

Mitel - OS4K: Setup Guide

Introduction

This guide will enable you to configure your OpenScape 4000 (OS4K) to pass calls to the Voice AI system and provide configuration to enable the calls to be returned (if applicable with a contact centre (CC) platform). On OS4K the trunk to Voice AI is a Session Initiation Protocol (SIP) trunk profile on a SIP trunk gateway board (vHG 3500), with a Session Border Controller (SBC) between the board and the Voice AI service. This configuration is done in the OS4K Assistant (the OpenScape 4000 management web application), the gateway board's web interface and the switch, using Administration and Maintenance Order (AMO) commands or the matching Assistant forms.

⚠️

This guide covers the Voice AI trunk only. It assumes the following are already in place: an SBC with a working link to the Voice AI service (see the SBC requirements section below), a dedicated SIP trunk gateway board for Voice AI that shows READY in Gateway Manager (if you do not have one, see Add a SIP trunk gateway board for Voice AI below), and the board's internal IP address reachable from the SBC. Any carrier or Public Switched Telephone Network (PSTN) trunk is configured separately and is not covered here.

⚠️

This guide uses the NatTrkWithRegistration SIP trunk profile. Despite the name, "Use Registrar" stays unticked, so the board does not register: it authenticates with the account and sends calls to the SBC. The profile does not accept SIP REFER, which Voice AI uses to transfer calls back to your phone system, until you tick REFER Allowed (see the profile settings table below). Only one profile can be active on a board.

Add a SIP trunk gateway board for Voice AI

Mitel advises using a separate gateway board for the Voice AI trunk. On an existing OS4K most boards are already in use for other trunks. If you already have a spare SIP trunk gateway board that is not used by anything else, skip to the next section.

You need the following before you start.

Item
Details
A free slot
An unused slot in a unit (the second and third numbers of the PEN). In the Assistant, open Configuration Management → System Data → Maintenance → Board Maintenance and search: free slots show a status of NOGEN, NPR or UNACH. You can also check with the AMO DIS-BCSU.
An IP address for the board
An unused internal (private) IP address on the same network as the OS4K, reachable from the SBC. It is not a public address. If your OS4K runs on a virtual or cloud platform, the address must also be added to the platform's network interface (on AWS, as a secondary private IP address).
A gateway number
An unused number, for example 160.
A channel count
The number of simultaneous calls the trunk can carry. It cannot be changed later without removing and re-adding the board, so allow room to grow. For example, 30.
A function block
A function block (a definition of what the board can do and how many channels it has) that provides SIP trunk channels. Use an existing one, or create one in step 0 below.
A board password
The password for the board's service login.
A trunk group number
An unused trunk group number. Calls are routed to the trunk group, and it holds the board's trunk circuits.
Existing class numbers
The class of trunk (COT), class of parameters (COP) and class of service (COS) numbers that your other native SIP trunks use, and the node number of your OpenScape 4000.

Example: adding the board with AMO commands

Adding the board takes four stages. AMO names such as BCSU, CGWB and GKREG are command names and are typed as shown.

  1. Create the board (AMO BCSU): the switch gets an entry for a new board in a slot. It has no network address yet.
  1. Configure the board (AMO Common Gateway Board, CGWB): the board gets its IP address, then its network, voice and login settings, using a series of CHANGE-CGWB commands.
  1. Register the gateway (AMO GKREG): the board is registered in the switch as a local gateway with its gateway number, so the switch can send calls to it.
  1. Add the trunk circuits (AMOs BUEND and TDCSU): the board gets a trunk group with one trunk circuit for each call, so that calls can be routed to it.

After that you save and restart the board. It then shows READY in Gateway Manager and is ready for the trunk profile and the trunk circuits.

Before you start, save the system with EXE-UPDAT:BP,ALL; and wait for EXEC COMPLETED. Run the commands one at a time and read each response. A refused AMO changes nothing, so you can correct the value and run it again.

⚠️

Values in angle brackets are yours to choose, using the checklist above. The other values are standard settings from Mitel's reference (Sandbox) configuration, and they match published native SIP trunk examples where we could check them. Leave them as shown unless your OS4K administrator advises otherwise.

Notion image

A function block tells the switch what a gateway board can do and how many channels it has. Check whether a suitable one already exists. If not, create one in the Assistant under Configuration Management → System Data → Board → CGW Function Block (CGW stands for Common Gateway): search for a free number, then select New. Or use the AMOs below, which are an example from Mitel's documentation.

ADD-BFDAT:FCTBLK=3,FUNCTION=HG3550,BRDBCHL=BCHL60&BCHL120;
CHANGE-BFDAT:CONFIG=CONT,FCTBLK=3,FUNCTION=HG3550,LINECNT=2,UNITS=3;
CHANGE-BFDAT:CONFIG=OK,FCTBLK=3,ANSW=YES;
Parameter
Value
What it does
FCTBLK
3
The number of the function block. Choose one that is not already used.
FUNCTION
HG3550
The function the block provides: IP trunking, which includes SIP trunks.
BRDBCHL
BCHL60&BCHL120
The largest number of channels a board using this block can have: 60 or 120.
LINECNT, UNITS
2, 3
How many channels the block holds. In Mitel's examples one line of three units gives 30 channels and two lines give 60. Choose enough to cover the channel count you use in step 1.
CONFIG
CONT, then OK
The first CHANGE-BFDAT sets the content of the block. The second, with CONFIG=OK, closes it so that it can be used.

What this creates: a function block that the board in step 1 is linked to.

ADD-BCSU:MTYPE=IPGW,LTG=1,LTU=<unit>,SLOT=<slot>,PARTNO="Q2330-X   ",FCTID=1,LWVAR="0",FCTBLK=<function-block>,BCHLSIP=<channels>,BCHL3550=<channels>,ALARMNO=0,IPMODE=IPV4,DHCPV4=NO,DHCPV6=NO;
Parameter
Value
What it does
MTYPE
IPGW
The type of board: an IP gateway.
LTG, LTU, SLOT
1, <unit>, <slot>
Where the board sits. Together they make up the PEN, for example 1-34-10.
PARTNO
"Q2330-X "
The part number that identifies the board type. Type it exactly as shown, including the spaces after the X.
FCTID, LWVAR
1, "0"
Leave as shown.
FCTBLK
<function-block>
Ties the board to the function block that provides SIP trunk channels.
BCHLSIP, BCHL3550
<channels>
The number of voice channels (simultaneous calls) the board can carry. Set both to the same number. It cannot be changed later without removing and re-adding the board.
ALARMNO
0
No alarm number assigned.
IPMODE, DHCPV4, DHCPV6
IPV4, NO, NO
The board uses IPv4 and a fixed address, not an automatically assigned one.

What this creates: an entry for the board in the switch configuration. The board does not have an IP address yet.

ADD-CGWB:LTU=<unit>,SLOT=<slot>,SMODE=NORMAL,IPADR=<board-ip>,NETMASK=<netmask>;
Parameter
Value
What it does
LTU, SLOT
<unit>, <slot>
Which board this applies to. Use the same values as step 1.
SMODE
NORMAL
The board's operating mode. NORMAL is standard operation.
IPADR
<board-ip>
The internal (private) IP address of the board, on your own network (LAN). It is not a public address. The SBC reaches the board on this address, and the SBC is the part that has the public one.
NETMASK
<netmask>
The subnet mask of the network the board is on.

What this creates: the board's network address. The switch now has an address to reach the board on.

CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=GLOBIF,PATTERN=213,VLAN=NO,VLANID=0,DEFRT=<default-gateway>,TRPRSIP=<channels>,TRPRSIPQ=0,TRPRH323=0,TPRH323A=0,TLSP=4061,DNSIPADR=0.0.0.0,DNSIPAD2=0.0.0.0,USEWANIF=NO,WPUBIP=0.0.0.0,SIPTCPP=5060,SIPTLSP=5061;
Parameter
Value
What it does
TYPE
GLOBIF
Selects the board's global interface settings: its network and SIP settings.
PATTERN
213
Leave as shown. Mitel's published examples use the same value.
VLAN, VLANID
NO, 0
No VLAN tagging on the board's network traffic. Change these only if your network requires a VLAN.
DEFRT
<default-gateway>
The default gateway (router) the board uses to reach other networks.
TRPRSIP
<channels>
The number of voice channels for the SIP trunking protocol. Setting it makes this a native SIP board, which is why the board shows Native SIP as its variant. Use the same number as the voice channels in step 1.
TRPRSIPQ, TRPRH323, TPRH323A
0
The same setting for the other trunking protocols (SIP-Q and H.323). Only one trunking protocol can be used per board, so these stay at zero.
TLSP
4061
Leave as shown.
DNSIPADR, DNSIPAD2
0.0.0.0
No DNS servers entered. The trunk uses IP addresses, so none are needed.
USEWANIF, WPUBIP
NO, 0.0.0.0
No separate WAN interface and no public IP address set on the board. The SBC handles the connection to the outside.
SIPTCPP, SIPTLSP
5060, 5061
The ports the board uses for SIP over TCP and SIP over TLS.

What this creates: the board's network and SIP port settings, and the number of channels it reserves for SIP trunk calls.

CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=SERVIF,LOGINTRM="TRM",PASSW="<board-password>";
Parameter
Value
What it does
LOGINTRM
"TRM"
The user name of the board's service login.
PASSW
"<board-password>"
The password for that login. Choose your own and do not use a default.

What this creates: the service login for the board.

These commands set how the board handles voice audio: the ports it uses, the priority marking on packets, keypad tones, and the list of voice codecs in order of preference. They apply to this board only.

CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,UDPPRTLO=29100,UDPPRTHI=30099,TOSPL="184",TOSSIGNL="104",T38FAX=YES,RFCFMOIP=NO,RFCDTMF=YES,REDRFCTN=YES,PRIO=PRIO1,CODEC=G711A,VAD=NO,RTP="20";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO2,CODEC=G729A,VAD=NO,RTP="20";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO3,CODEC=NONE,VAD=NO,RTP="30";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO4,CODEC=NONE,VAD=NO,RTP="20";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO5,CODEC=NONE,VAD=NO,RTP="20";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO6,CODEC=NONE,VAD=NO,RTP="20";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO7,CODEC=G729AB,VAD=YES,RTP="20";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO8,CODEC=G722,VAD=NO,RTP="20";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=ASC,PRIO=PRIO9,CODEC=OPUS,VAD=NO,RTP="20";

The first command also sets the ports and markings shown here.

Parameter
Value
What it does
UDPPRTLO, UDPPRTHI
29100, 30099
The range of UDP ports the board uses for the voice audio (RTP). Allow this range through any firewall between the board and the SBC.
TOSPL
"184"
The priority marking (Type of Service) on voice packets. 184 is the usual high priority marking for voice.
TOSSIGNL
"104"
The priority marking on call signalling packets.
T38FAX
YES
Allows faxes to be sent over IP using the T.38 method.
RFCFMOIP, RFCDTMF, REDRFCTN
NO, YES, YES
How keypad tones (DTMF) and fax or modem signals are carried. Leave as shown.

The codec list is the order in which the board offers voice codecs. The other end of the call (here, the SBC) picks one it accepts, so the order matters. Packet size is the amount of audio in each packet, in milliseconds.

Priority
Codec
Voice activity detection
Packet size
What it is
PRIO1
G711A
NO
20
First choice. G.711 A-law is also the codec used on the Voice AI side (see SBC requirements).
PRIO2
G729A
NO
20
Second choice. A compressed codec that uses less bandwidth.
PRIO3 to PRIO6
NONE
NO
30, 20, 20, 20
Unused. NONE leaves the slot empty.
PRIO7
G729AB
YES
20
A compressed codec that also stops sending audio during silence, which is why voice activity detection is on.
PRIO8
G722
NO
20
A wideband (higher quality) codec.
PRIO9
OPUS
NO
20
A flexible wideband codec.

What this creates: the board's voice settings: a port range for audio, priority markings, and a codec list with G.711 A-law first.

CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=MGNTDATA,UIMODE=CLASSIC;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=DMCDATA,DMCCONN=0,SMP=NO,SMP4OSV=NO;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=WBMDATA,LOGINWBM="<web-login-1>",ROLE=ENGR;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=WBMDATA,LOGINWBM="<web-login-2>",ROLE=SU;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=WBMDATA,LOGINWBM="<web-login-3>",ROLE=ADMIN;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=WBMDATA,LOGINWBM="<web-login-4>",ROLE=READONLY;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=GWDATA,GWID1="PRIMARYRASMANAGERID";
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=LEGKDATA,GWNO=<gateway-number>,GWDIRNO=<gateway-direct-number>,REGEXTGK=NO;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=SIPTRERH,GWAUTREQ=NO;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=SIPTRSSA,SIPREG=NO,REGIP1=0.0.0.0,PORTTCP1=5060,PORTTLS1=5061,REGTIME=300,REGIP2=0.0.0.0,PORTTCP2=5060,PORTTLS2=5061;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=DLSDATA,DLSPORT=18443,DLSACPAS=YES;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=JB,AVGDLYV=40,MAXDLYV=120,MINDLYV=20,PACKLOSS=4,AVGDLYD=60,MAXDLYD=200,JBMODE=2;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=IPCONF,IPMODE=IPV4,DHCPV4=NO,DHCPV6=NO;
CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=MANLANIF,MIPADR=0.0.0.0,MNETMASK=0.0.0.0,MVLAN=NO,MVLANID=0,MDEFRT=0.0.0.0;
Setting (TYPE)
Values
What it does
MGNTDATA
UIMODE=CLASSIC
The style of the board's web interface (the classic layout).
DMCDATA
DMCCONN=0, SMP=NO, SMP4OSV=NO
Settings for Direct Media Connect (DMC), which lets voice travel directly between two endpoints instead of through the gateway. DMCCONN is the number of such connections. Mitel's OpenScape SBC guide requires DMC to be disabled for a SIP trunk that goes through the SBC, and Mitel recommends switching DMC and SMP off on a dedicated SIP trunk board. The values shown do this.
WBMDATA (four commands)
LOGINWBM, ROLE
Creates the logins for the board's web interface at four access levels (ENGR, SU, ADMIN and READONLY). Choose your own login names.
GWDATA
GWID1="PRIMARYRASMANAGERID"
Leave as shown. Mitel's published examples use the same value.
LEGKDATA
GWNO, GWDIRNO, REGEXTGK=NO
Gives the board its gateway number (GWNO) and a direct number (GWDIRNO), and says it does not register with an external gatekeeper. In the Mitel reference configuration the direct number is 10000 plus the gateway number, for example 10160 for gateway number 160.
SIPTRERH
GWAUTREQ=NO
The board does not require authentication from the system at the other end. Mitel's published examples use the same value.
SIPTRSSA
SIPREG=NO and zeroed registrar addresses
No registration is set up at this level. The trunk's account and proxy are set in the board's web interface instead (see below).
DLSDATA
DLSPORT=18443, DLSACPAS=YES
The port the board uses to connect to the OpenScape Deployment Service. Leave as shown.
JB
AVGDLYV, MAXDLYV, MINDLYV, PACKLOSS, AVGDLYD, MAXDLYD, JBMODE
Jitter buffer settings, which smooth out voice packets that arrive unevenly. Leave as shown.
IPCONF
IPMODE=IPV4, DHCPV4=NO, DHCPV6=NO
The board uses IPv4 and a fixed address.
MANLANIF
all zeros, MVLAN=NO
A separate management network interface. Not used here, so it is left empty.

What this creates: the board's management logins, its gateway number, and its remaining standard settings.

ADD-GKREG:GWNO=<gateway-number>,GWATTR=INTGW&HG3550V2&SIP,DIPLNUM=0,DPLN=0,LAUTH=1,PORT=0;
Parameter
Value
What it does
GWNO
<gateway-number>
The gateway number of the board. It must match the GWNO in step 6.
GWATTR
INTGW&HG3550V2&SIP
The attributes of the gateway: a local gateway, using the HG 3550 version 2 function, carrying SIP.
DIPLNUM, DPLN
0, 0
The dial plan the gateway uses (dial plan 0).
LAUTH, PORT
1, 0
Leave as shown.

What this creates: the registration of the board in the switch as a local gateway, so that trunk circuits can be added to it.

A trunk group is a numbered bundle of trunk circuits, and each trunk circuit carries one call at a time. Calls are routed to the trunk group, so the board needs one circuit for each channel you gave it in step 1.

ADD-BUEND:TGRP=<trunk-group>,NO=<channels>,TRACENO=0,TDDRFLAG=OFF,CHARCON=NEUTRAL;
ADD-TDCSU:OPT=NEW,PEN=<group>-<unit>-<slot>-0,COTNO=<cot>,COPNO=<cop>,DPLN=0,ITR=0,COS=<cos>,LCOSV=1,LCOSD=1,CCT="NATIVE SIP  ",DESTNO=50,PROTVAR="ECMAV2",SEGMENT=8,DEDSVC=NONE,TRTBL=GDTR,SIDANI=N,ATNTYP=CO,CBMATTR=NONE,TCHARG=N,SUPPRESS=0,TRACOUNT=<channels-plus-one>,SATCOUNT=MANY,NNO=<node-number>,ALARMNO=0,FIDX=1,CARRIER=1,ZONE=EMPTY,COTX=<cot>,FWDX=5,CHIMAP=N,UUSCCX=16,UUSCCY=8,FNIDX=1,NWMUXTIM=10,CLASSMRK=EC&G711&G729A,TGRP=<trunk-group>,SRCHMODE=ASC,INS=Y,SECLEVEL=TRADITIO,HMUSIC=0,CALLTIM=60,WARNTIM=60,DEV=HG3550CO,BCHAN=1&&<channels>,BCNEG=N,BCGR=1,LWPP=0,LWLT=0,LWPS=0,LWR1=0,LWR2=1,DMCALLWD=N,GWPROT=NONE;
Command and parameter
Value
What it does
ADD-BUEND, TGRP
<trunk-group>
The number of the trunk group. Choose one that no other trunk group uses. The same number goes in the trunk circuits below and in the route later.
ADD-BUEND, NO
<channels>
The number of trunk circuits in the group, one for each simultaneous call. Use the same number as the voice channels in step 1.
ADD-TDCSU, OPT
NEW
Adds new trunk circuits.
PEN
<group>-<unit>-<slot>-0
The address of the board (see the PEN in step 1) followed by the first circuit number, 0. In this command the slot is written with three digits, for example 011.
COTNO, COTX
<cot>
The class of trunk, which sets how the switch treats calls on these circuits. It must already exist. Use the same value as your other native SIP trunks.
COPNO
<cop>
The class of parameters for the circuits. Use the same value as your other native SIP trunks.
COS
<cos>
The class of service, which sets what calls on these circuits may do.
NNO
<node-number>
The node number of your OpenScape 4000.
TGRP
<trunk-group>
The trunk group that the circuits belong to. It must match ADD-BUEND.
CCT
"NATIVE SIP "
The type of circuit: a native SIP trunk. Type it exactly as shown, including the spaces.
DEV
HG3550CO
The device type for native SIP trunks on this gateway board.
BCHAN
1&&<channels>
The channels of the board that these circuits use: channel 1 up to the number of channels.
TRACOUNT
<channels-plus-one>
One more than the number of channels.
SECLEVEL
TRADITIO
The media security level: traditional, which means no encryption between the board and the SBC. The SBC encrypts the audio towards the Voice AI service. Choose a secure level only if you also match it in the SBC media profile.
CLASSMRK
EC&G711&G729A
The features and codecs the circuits allow: echo cancellation, G.711 and G.729A.
SRCHMODE
ASC
The order in which the switch picks a free circuit: lowest first.
INS
Y
The circuits are in service.
DMCALLWD
N
Direct Media Connect is not allowed on these circuits, as in step 6.
All other parameters
as shown
Standard values. Leave as shown.

What this creates: a trunk group with one trunk circuit for each channel of the board, ready to be routed to. Continue with Finish below, which saves and restarts the board.

  1. Save again with EXE-UPDAT:BP,ALL; and wait for EXEC COMPLETED.
  1. Restart the board with RES-BSSU:PEN,,<unit>,<slot>; so that it picks up the new settings. The AMO prints this command when it finishes.
  1. In the Assistant, open Expert Mode → Gateway Manager and check that the new board shows READY.

Open the gateway board's web interface

In the Assistant, go to Expert Mode → Gateway Manager and find the SIP trunk gateway board in the list (it shows type vHG3500 and the functionality IP TRUNK, SIP). In its Remote access column select the WBM (Web-Based Management) icon. The board's web interface opens, titled vHG 3500.

Notion image
💡

Note the board's Port Equipment Number (PEN), which Gateway Manager shows as three numbers (group, unit and slot, for example 1-34-10), and its internal IP address. You will need the PEN again when you add the trunk circuits in the switch, and the IP address when you add the board to the SBC.

Add the Voice AI SIP Trunk Profile

Check the SIP Trunk Profile Parameter settings

In the board's web interface go to Configuration → Voice Gateway → SIP Trunk Profile Parameter and check the settings using the following table as guidance. Select Apply if you change anything.

Notion image
Option
Suggested Value
Details
SIP Protocol Variant for IP Networking
Native SIP (shown, not editable here)
Shows how this board uses SIP. Native SIP is standard SIP, which is what the Voice AI service uses. SIP-Q is a Mitel-specific version used to connect OpenScape systems to each other.
Use Profiles for Trunks via Native SIP
Ticked
Makes the board use the SIP Trunk Profiles (such as NatTrkWithRegistration) for Native SIP trunks. The page says it should only be switched off for test purposes.
Enable SIP Peer Filtering
Unticked (default)
Participate at SIP Load Balancing
Unticked (default)
The page says this is only possible for Native SIP trunks without registration. The Voice AI trunk uses a profile with an account, so it does not apply here.

Select the profile and add the account

Then open Configuration → Voice Gateway → SIP Trunk Profiles and select the profile NatTrkWithRegistration. Add an account under the profile for the Voice AI credentials first: press the + sign next to the profile in the tree, select Add Account/Authentication (see Account for the Trunk credentials below). Then select the profile itself and complete the profile settings using the following table as guidance. We recommend putting Voice AI in the User Notes field for ease of identification.

Notion image
Option
Suggested Value
Details
User Notes
Voice AI
A label to identify this trunk.
Activate Trunk Profile
Ticked
The profile does nothing until this is ticked and applied.
Account/Authentication Required
Ticked
The Voice AI trunk user name and password are entered as an account under this profile (see below).
Remote Domain Name
{sip-domain}
The SIP domain name provided for your Voice AI trunk, the same one you enter on the SBC. Fill this field in.
IP Transport Protocol
TCP
Used for outgoing call set-up towards the SBC. The TLS leg to the Voice AI service is on the SBC.
Default PAI (P-Asserted-Identity)
blank (default)
RTP Security Mode
insecure (plain RTP). Shown here and set by SECLEVEL in the trunk circuits.
How the voice audio (carried by Real-time Transport Protocol, RTP) is protected between the board and the SBC. On a native SIP trunk the security mode is shown here and is set by SECLEVEL in the trunk circuit settings (TRADITIO is the standard, unencrypted setting). Encrypted audio uses Secure RTP (SRTP), with the keys exchanged using Session Description Protocol Security Descriptions (SDES). The audio towards the Voice AI service is encrypted by the SBC. With the circuits set to TRADITIO, the board offers plain RTP and the SBC's Best Effort SRTP core side profile accepts it. If you set a secure level on the circuits instead, match the SBC media profile.
Use Registrar
Unticked
The Voice AI trunk does not register. Calls are routed to the SBC.
Registrar: IP Address / Host name
{sbc-ip-address}
Fill this in even though Use Registrar is unticked. Mitel's OpenScape SBC guide says the Registrar and Proxy address and port are both replaced with the SBC's LAN address and listen port.
Proxy: IP Address / Host name
{sbc-ip-address}
The SBC address that the board can reach (its core side, not the WAN address). The board rejects incoming calls (403 Forbidden) from any address that is not configured in the profile, so the SBC address must be entered here or as the Outbound Proxy.
Proxy: Specify Port
Ticked
Proxy: TCP/UDP Port
{sbc-port}
The core realm port you give the Voice AI remote endpoint on the SBC, for example 50012. The SBC uses this port to tell which endpoint a call is for, so it must not be used by anything else.
Proxy: TLS Port
{sbc-port}
Same value as the TCP/UDP port.
Outbound Proxy
blank (default)
REFER Allowed (RFC 3515)
Ticked
Further down the profile page, below UPDATE Allowed. Lets the board accept a SIP REFER, the message Voice AI sends to ask your phone system to transfer a call. Unticked, the board answers the REFER with 405 Method Not Allowed and the transfer fails. The profile page warns that Mitel recommends changing the default profile parameters only after consulting Mitel support (the page calls it GPS), and that support for modified profiles is limited.

Select Apply. The profile in the tree should show a green marker once it is active.

⚠️

This guide follows Mitel's OpenScape SBC guide, which replaces the Registrar and Proxy address and port with the SBC's LAN address and listen port. Mitel's IP Solutions guide describes another layout, with the provider's details in Registrar and Proxy and the SBC in the Outbound Proxy section. Use that layout only if this one does not work for you.

Account for the Trunk credentials

Account/Authentication Required is ticked in this profile, so the board will not let you apply or activate it until an account exists. It shows the message "Please create first an account" if you try. In the tree, press the + sign next to NatTrkWithRegistration and select Add Account/Authentication. Complete the form using the following table as guidance.

Option
Suggested Value
Details
Account Name
siptrunkuser
This is provided with your Voice AI service. Some older accounts will have a different user name.
Authorization name
siptrunkuser
The same value as the account name.
Provider Name
NatTrkWithRegistration (read only)
New Password
{password}
The password provided for your Voice AI SIP trunk.
Confirm Password
{password}
Confirm the value from the previous field.

Select Apply.

Back up the board's configuration

Everything you enter in the board's web interface, including this trunk profile and its account, is lost if the board is replaced, reset or has its loadware upgraded, unless it has been backed up. The trunk then cannot reconnect by itself. Set up both of the following.

First, back up to the Assistant. In the Assistant, use Backup & Restore. The board needs to know where the Assistant and the backup server are. Use this AMO command, with the values from Mitel's example:

CHANGE-CGWB:MTYPE=CGW,LTU=<unit>,SLOT=<slot>,TYPE=MGNTDATA,MGNTIP=<assistant-ip>,MGNTPN=8000,BUSIP=<backup-server-ip>,BUSPN=443;
Parameter
Value
What it does
MGNTIP, MGNTPN
<assistant-ip>, 8000
The IP address of the OpenScape 4000 Assistant and the port the board uses to reach it.
BUSIP, BUSPN
<backup-server-ip>, 443
The IP address of the backup server and its port. In Mitel's example this is the same address as the Assistant.

The two port values are not restored after a board reset, so they have to be entered again if the board is reset.

Second, save to the board's own flash memory. In the board's web interface go to Maintenance → Actions, double-click Automatic Actions and run Saving Local Configuration for Upgrade. If the backup server cannot be reached, the board restores its settings from this copy.

Route calls to the Voice AI trunk

Calls reach the trunk through Least Cost Routing (LCR), which matches the digits dialled against patterns and sends the call to a route. This takes five AMOs, run in this order. Values in angle brackets are yours to choose. Run the commands one at a time and read each response.

ADD-WABE:CD=<dial-code>,DAR=TIE;
ADD-RICHT:MODE=LRTENEW,LRTE=<route>,LSVC=ALL,NAME="VOICE AI       ",TGRP=<trunk-group>,DNNO=<node-number>,ROUTOPT=NO,ROUTATT=NO,EMCYRTT=NO,PDNNO=<primary-node-number>,CHARCON=NEUTRAL,CONFTONE=NO,RERINGRP=NO,NOPRCFWD=NO,NITO=NO,CLNAMEDL=NO,FWDSWTCH=NO,LINFEMER=NO,NOINTRTE=NO;
ADD-LODR:ODR=<rule>,CMD=ECHO,FIELD=1;
ADD-LODR:ODR=<rule>,CMD=ECHOALL;
ADD-LODR:ODR=<rule>,CMD=NPI,NPI=UNKNOWN,TON=UNKNOWN;
ADD-LODR:ODR=<rule>,CMD=END;
ADD-LDAT:LROUTE=<route>,LSVC=ALL,LVAL=1,TGRP=<trunk-group>,ODR=<rule>,LAUTH=1,CARRIER=1,ZONE=EMPTY,LATTR=NONE,DNNO=<node-number>,VCCYC=4;
ADD-LDPLN:LCRCONF=LCRPATT,DIPLNUM=0,LDP="<dial-code>"-"Z",DPLN=0&1&2&3&4&5&6&7&8&9&10&11&12&13&14&15,LROUTE=<route>,LAUTH=1,PINDP=N;
EXE-UPDAT:BP,ALL;
Command and parameter
Value
What it does
ADD-WABE, CD
<dial-code>
The first digits that mark a call for Voice AI, for example the leading digits of the numbers you use to reach Voice AI. It adds the code to the switch's digit analysis.
ADD-WABE, DAR
TIE
The digit analysis result: the call is treated as a trunk call and passed on to least cost routing.
ADD-RICHT, MODE
LRTENEW
Creates a new LCR route.
ADD-RICHT, LRTE
<route>
The number of the route. Choose one that no other route uses.
ADD-RICHT, TGRP
<trunk-group>
The trunk group from step 8. This is what links the route to the board.
DNNO, PDNNO
<node-number>, <primary-node-number>
The node that the route leads to, which is your own OpenScape 4000. Use the same values as your other SIP routes.
NAME
"VOICE AI "
A label for the route. Type it exactly as shown, including the spaces.
ADD-LODR, ODR
<rule>
The number of the output rule, which controls how the digits are sent on. Choose one that no other rule uses.
CMD
ECHO, ECHOALL, NPI, END
The four lines of the rule: send the first field of the dialled number, send all the remaining digits, mark the number type as unknown, and end the rule. The result is that the dialled digits are passed on unchanged.
ADD-LDAT, LROUTE
<route>
The LCR route this data belongs to. It must be the same number as LRTE in ADD-RICHT, or the command is refused.
TGRP, ODR
<trunk-group>, <rule>
The trunk group to send the call to, and the output rule to apply.
ADD-LDPLN, LDP
"<dial-code>"-"Z"
The dial pattern: the dial code followed by any digits. The code must already exist in ADD-WABE, or the command is refused.
LROUTE
<route>
The route that calls matching the pattern use.
DIPLNUM, DPLN
0, 0&1&...&15
The dial plan, and the dial plan groups the pattern applies to: all of them.
EXE-UPDAT
BP,ALL
Saves the configuration. Wait for EXEC COMPLETED.
All other parameters
as shown
Standard values. Leave as shown.

What this creates: a route to the Voice AI trunk group, and a dial pattern that sends every call beginning with the dial code to it, with the digits passed on unchanged.

The route has been tested with a call arriving on a carrier trunk. A call dialled from an extension on your system should use it in the same way, so check it with a test call.

SBC requirements

The Session Border Controller (SBC) sits between the gateway board and the Voice AI Trunk. Any SBC that can terminate TCP from the board and TLS towards the trunk will work, so follow your SBC vendor's documentation for the exact screens. The SBC needs the following.

Item
Value
Details
OS4K side: peer
{board-ip-address}
The gateway board's internal IP address (the one set in step 2 of adding the board), entered as a clustered server on the SBC (Comm System Type set to Clustered), together with the board that carries your other trunks. Voice AI uses its own board, so the SBC connects to at least two boards. If the board is not listed, the platform's transfer (SIP REFER) and hang-up (SIP BYE) messages are sent to the wrong board and fail. SIP port 5060, transport TCP.
OS4K side: registration
Allow Register from SERVER ticked
In VoIP → SIP Server Settings. Mitel's guide says to tick it when the board's trunk profile uses an account, as in this guide.
OS4K side: listening port
{sbc-port}
Must match the proxy port in the trunk profile above.
Voice AI side: remote domain
{sip-domain}
Your Voice AI SIP trunk domain.
Voice AI side: port and transport
5061, TLS
Server authentication: the SBC validates the Voice AI service's certificate. It needs the certificate authority's certificate that signed it, and checks the certificate's name against the address you give, so use the domain name and not an IP address.
Media
Secure Real-time Transport Protocol (SRTP) with Session Description Protocol Security Descriptions (SDES) key exchange, and the G.711 A-law voice codec (a standard way of encoding voice)
Use the same crypto mode on the OS4K side so the profile above matches.
Routing
Dialled prefix to the Voice AI remote endpoint
Calls from OS4K for the Voice AI numbers must be routed to the Voice AI endpoint.
Voice AI side: identity
The Voice AI domain in the Request-URI and To headers
The domain {sip-domain} must appear in the call set-up towards the Voice AI service. On a Mitel OpenScape SBC this is the SIP service address in the service provider profile, used in the Request-URI and To headers.
Voice AI side: credentials
Passed through to the board
If the Voice AI service challenges a call for credentials, Mitel's guide describes the SBC passing the challenge to the system behind it, which answers it. Here that is the board, using the account in its trunk profile, so the account is not set on the SBC.
⚠️

If your SBC is a Mitel OpenScape SBC, add the board under VoIP → SIP Server Settings → Clustered servers, and build the Voice AI link from a Media Profile, a Remote Endpoint, the Remote Endpoint Configuration and a Remote Location Domain. Applying changes on the OpenScape SBC restarts its SIP server, which ends any calls in progress.

Map the route to a Voice AI bot

Each dial code that routes to the Voice AI trunk needs to be mapped to a Voice AI bot. In the Voice AI platform, go to Settings → Voice Routing and select Create Voice Route.

Notion image

Make a test call through your route, then open the call log in Settings. The To column shows the exact SIP address, including any parameters, that your OpenScape 4000 dialled into the Voice AI service. Copy this value into the Endpoint field exactly as it appears.

Notion image
Option
Suggested Value
Details
Label
e.g. OS4K Route 1000
A friendly name for internal identification
Endpoint
Full SIP address from the call log
Copy the To value verbatim
Type
Voice AI Config
Voice AI Bot
{botName}
The bot to handle calls on this route

Select Save. Repeat for each dial code you use. You can map several routes to the same bot.

Return calls to your phone system (SIP REFER)

Voice AI can return a call to your OpenScape 4000 with a SIP REFER, which asks your phone system to transfer the caller to an extension. This is the simplest way to hand a call back. It suits deployments where the Voice AI console is not surfaced in your contact centre platform, and it is a good way to test the transfer connection.

Before you use it, check the following.

  1. REFER Allowed is ticked in the board's SIP trunk profile (see the profile settings table above). Without it the board refuses the transfer with 405 Method Not Allowed.
  1. The Voice AI board is listed as a clustered server on the SBC (see SBC requirements). Without it the transfer message is sent to the wrong board and fails.

In your Voice Bot, add a Transfer Tool and configure it as follows:

Option
Value
Details
Transfer Type
SIP Refer
Issues a SIP REFER to transfer the call
Destination
sip:{extension}@{sbc-address}:{sbc-tls-port};transport=tls
The user name is the OpenScape 4000 extension to transfer to. The address is the public DNS name of your SBC, and the port is the port on your SBC that the Voice AI platform connects to, for example 65061. If your Voice AI service provides an extra parameter for your trunk, such as a region, add it after transport=tls.
Prompt
e.g. "Use this to transfer to the agent queue"
Tells the AI when to invoke this transfer
Voice Assist Config
Leave blank
Adding a Voice Assist Config switches the transfer type to SIP Dial, which is covered separately in the Interaction Parking guides
Notion image

Make a test call to the bot and ask it to transfer you. The extension should ring.

Using the originating address as the destination

The Destination above is written out in full, so it works whatever the SIP From header of the incoming call contains. The Voice AI platform also accepts sip:{extension}@__ORIGINATOR__. This returns the call to the address after the @ in the From header of the call that came in. For example, if the call came from sip:1000@pbx.example.com, the transfer goes back to pbx.example.com.

This only works when the From header holds everything the platform needs to reach your SBC:

  • The SBC's public address, not a local (private) one.
  • The SBC's TLS port, if you do not use the default port.

If the From header carries a local address, or leaves out the port, the platform cannot deliver the transfer. In testing, the From header sent through the OpenScape SBC carried the SBC's public address without the port, so use the full destination above unless your SBC puts the port in the From header.

To check, take a network capture on the SBC and read the From header of the call into the Voice AI platform. To make the SBC use its public address, see the public address requirement in the OpenScape SBC guide.

📎

If you have a contact centre platform linked to your OpenScape 4000, you can use Interaction Parking to bring the call's details across. See the Interaction Parking guides in this collection.

References

The commands and settings in this guide come from the Mitel documents below. Page and chapter numbers refer to the PDF guides. Each AMO has its own chapter in Volume 1: AMO Descriptions, and typing ? at an AMO prompt shows the help for that parameter.

Used for
Mitel document
Where to look
Adding the gateway board: function block, board, address and settings, and registering the gateway
Chapter 14.3, SIP Trunking, and chapter 14.5, Configuration of SIP Service Provider and SIP Carrier. The HTML edition (V10) also describes configuring the HG 3500 board with BFDAT, BCSU and CGWB and registering the gateway with GKREG
Steps 2 to 6: the ADD-CGWB and CHANGE-CGWB commands
The parameter descriptions for each TYPE
Step 8: the trunk group and the trunk circuits
BUEND creates the trunk group and TDCSU assigns circuits to it. The BUEND interrelationships page gives the order: BUEND, TDCSU, RICHT, LDAT
Routing: the dial code, the route, the output rule, the route data and the dial pattern
The LDPLN interrelationships page gives the order the AMOs are run in: WABE, COSSU, RICHT, LODR, LDAT, LDPLN. LODR and LDPLN have their own chapters in the same volume
Saving the configuration with EXE-UPDAT:BP,ALL;
Functions of the AMO: EXEC-UPDAT
The SIP trunk profile and account, REFER Allowed, one profile per board, and backing up the board's configuration
OpenScape 4000 V11, Volume 4: IP Solutions (linked above)
Chapters 14.3 and 14.5
The SBC side: clustered servers, remote endpoint, service provider profile, media profile and credentials
SBC using OpenScape 4000 as SIP Server, pages 264 to 275. Service provider profiles, pages 130 to 143. Remote endpoints, pages 144 to 152. Media, pages 96 to 100
Switching off Direct Media Connect for a trunk that goes through the SBC
OpenScape SBC V11 Configuration Guide, and OpenScape 4000 V11 IP Solutions
SBC guide: SBC using OpenScape 4000 as SIP Server (the SBC does not support UPDATE with SDP, so DMC must be off). IP Solutions: the DMC recommendations for a dedicated SIP trunk board
The standard values marked "leave as shown"
Mitel's OpenScape 4000 Sandbox reference configuration (the configuration tool and its README), provided by Mitel
Where we could check them, the same values appear in the carrier examples in IP Solutions chapter 14.5

The OpenScape 4000 documentation is listed in the OpenScape 4000 index of the Mitel Document Center.

Glossary of terms

Plain-English meanings of the abbreviations and technical terms used in this guide.

Term
Stands for
What it means
AI
Artificial Intelligence
Software that can understand and respond to people. In this guide, it is the Voice AI bot that answers your calls.
AMO
Administration and Maintenance Order
A command typed into the OS4K phone system to configure it. Most AMOs can also be done through forms in the Assistant.
BUEND
(a command name)
The AMO that creates a trunk group.
CC
Contact Centre
A team and system that handles customer calls, with agents, queues and reporting.
CGWB
Common Gateway Board
The AMO (command) used to set the IP address and settings of a gateway board.
DMC
Direct Media Connect
A feature that lets voice travel directly between two endpoints instead of passing through the gateway board.
DTMF
Dual-Tone Multi-Frequency
The tones made by pressing the keys on a phone keypad.
G.711 A-law
(a standard name, not an abbreviation)
A common way of turning voice into digital data for a call. A-law is the version used in Europe and much of the world.
IP
Internet Protocol
The addressing system networks use. An IP address is the number that identifies a device on the network, for example 192.168.10.25.
LCR
Least Cost Routing
The OS4K feature that picks a route for a dialled number by matching its digits against patterns.
LDAT
(a command name)
The AMO that holds the data of an LCR route: which trunk group to use and how the digits are sent.
LDPLN
(a command name)
The AMO that holds the LCR dial patterns, each pointing to a route.
LODR
(a command name)
The AMO that defines output rules: how the dialled digits are rewritten before they are sent.
OS4K
OpenScape 4000
The Mitel phone system (also called a PBX) that this guide configures.
PAI
P-Asserted-Identity
A piece of information sent with a call that says who the caller is, for example the number shown to the person receiving the call.
PEN
Port Equipment Number
The address of a board inside the OS4K, written as three numbers (group, unit and slot), for example 1-34-10.
PSTN
Public Switched Telephone Network
The ordinary public phone network that you call landlines and mobiles over.
RFC
Request for Comments
A numbered document that defines an internet standard. RFC 3515 defines SIP REFER and appears in the name of a setting on the board.
RICHT
(a command name)
The AMO that creates routes.
RTP
Real-time Transport Protocol
The way the voice audio itself is carried during a call.
SBC
Session Border Controller
A device that sits between your phone system and an outside network (here, the Voice AI service). It protects your system and makes sure the two sides can understand each other.
SDES
Session Description Protocol Security Descriptions
A method for the two ends of a call to agree the encryption keys for the call audio.
SIP
Session Initiation Protocol
The standard way of starting, managing and ending calls over an IP network. A SIP trunk is a connection that carries many calls using SIP.
SIP BYE
(a SIP message type)
A SIP message that ends a call.
SIP REFER
(a SIP message type)
A SIP message that asks the other side to start a new call, used to transfer a call. Voice AI uses it to return a call to your phone system.
SIP-Q
(a Mitel name for QSIG over SIP)
A Mitel-specific version of SIP, which carries the older QSIG phone-system signalling inside SIP, used to connect OpenScape systems to each other. It is not used for the Voice AI connection.
SRTP
Secure Real-time Transport Protocol
The encrypted version of RTP, so nobody listening on the network can hear the call.
TCP
Transmission Control Protocol
A way of sending data that checks it arrived. It sets up a connection first, then sends the call messages over it.
TDCSU
(a command name)
The AMO that creates trunk circuits, one for each call, on a board.
TLS
Transport Layer Security
Encryption that protects a connection, the same technology that protects secure websites. It is used between the SBC and the Voice AI service.
UDP
User Datagram Protocol
A faster way of sending data that does not set up a connection or check delivery. It is the alternative to TCP.
VAD
Voice Activity Detection
A feature that stops sending audio during silence, to save bandwidth.
vHG 3500
(a model name)
The model name of the gateway board type in the OS4K that carries the SIP trunks.
VoIP
Voice over Internet Protocol
Making phone calls over an IP network, not over traditional phone lines.
WABE
(a command name)
The AMO that holds dial codes. It tells the switch what to do with the first digits dialled.
WBM
Web-Based Management
The web page built into a gateway board that you use to configure it.
 
Did this answer your question?
😞
😐
🤩