The Microsoft Teams Connector allows you to integrate myCloudPBX with Microsoft Teams using Direct Routing. This enables Teams users to place and receive external phone calls via the same infrastructure used by traditional myCloudPBX users.
Before you begin, ensure you have the following:
To Configure a new connector for Microsoft Teams, click on the 'PBX Connectors', icon from the PBX Configuration screen.
Here you can see your existing connectors.
Configure as follows:
Connector Type: Microsoft Teams.
Name: This is for your reference.
Country: Sets the default regional settings (e.g. number formatting).
Timezone: Used for logs and time-sensitive operations.
Default Outbound Number: This will be used for the Outbound Caller ID for external calls.
MS Teams Domain: A unique domain allocated for use with Microsoft Teams Direct Routing e.g. example.teams.mycloudpbx.com.au
.
Tip
Remember this unique domain name as you will need it later when configuring the Microsoft end.
Next, we create the users within the myCloudPBX Configuration Portal on the Connector Management Screen. This should match the extension numbers you will create within Microsoft Teams.
The right-hand panel allows you to define which internal users (extensions) are part of the Teams integration:
Adding a User:
116
)To complete the Microsoft Teams Direct Routing setup, you must now verify the Teams domain in Microsoft 365.
Add Domain:
example.teams.mycloudpbx.com.au
.TXT value (MS=msxxxxx)
.Verify Domain:
To activate, we will need to create a single 'Activation User', this user will be tempory and can be removed once setup is complete.
Step 1. From the Admin Center, select Users > Active User > Add a User
Step 2. Enter the following details
Setting | Value |
---|---|
First Name | Teams |
Last Name | Activation |
Display Name | Teams Activation |
Username | Teams Activation |
Domain | Add the domain name provided in prior steps. eg example.teams.mycloudpbx.com.au |
Step 3. Check Automaically create a password.
Step 4. Uncheck Require this user to change their password.
Step 5. Uncheck Send password in email.
Step 6. Assign the User a Microsoft 365 subscription with Microsoft Teams Phone
Log in to Microsoft Teams Admin Center:
Set Up PSTN Gateway:
Click Add and enter your unique Teams URL (eg example.teams.mycloudpbx.com.au
) and Apply
Connect to PowerShell and enter the following:
Import-Module MicrosoftTeams
Connect-MicrosoftTeams
When prompted enter your Microsoft Teams Admin user details.
New-CsOnlineVoiceRoute -Identity example.teams.mycloudpbx.com.au -NumberPattern ".*." -Priority 1 -OnlinePstnUsages example.teams.mycloudpbx.com.au -OnlinePstnGatewayList example.teams.mycloudpbx.com.au
Tip
Replace example.teams.mycloudpbx.com.au with your unique domain.
example.teams.mycloudpbx.com.au
)Assign Voice Routing Policies:
example.teams.mycloudpbx.com.au
to the selected users.Note
Teams activation can take up to 24 hours.
You can check the activation status by selecting Analytics & reports > Usage reports > PSTN and SMS (preview) usage
Note
For myCloudPBX and Microsoft Teams to work together, the Teams user extension numbers must be mapped here .
This tells myCloudPBX to route calls to these users via the Microsoft Teams instance directly.
First, allocate each Teams User with an Extension Number (These should match the users created earlier on the myCloudPBX Connector Configuration screen.
101
)Microsoft Teams uses E.164. We will create a series of normalisation rules to align with the standard telephone number format for end users.
[STATE] myCLoudPBX
. We reccommend creating a dial plan for each State/Territory your users are located in, this will allow for localised dialling for their location.Name | Rule Creation Mode | If Condition | Then Do This |
---|---|---|---|
AU-National | Advanced | ^0([2\|3\|7\|8]{1}[0-9]{8})$ | +61$1 |
AU-Mobile | Advanced | ^0([4\|5]{1}[0-9]{8})$ | +61$1 |
AU-13-1300 | Advanced | ^(13(\d{4}\|00\d{6}))$ | +61$1 |
AU-1800 | Advanced | ^(1800\d{6})$ | +61$1 |
AU-0011 | Advanced | ^0011(\d+)$ | +61$1 |
AU-000 | Advanced | ^(000)$ | $1 |
Create local dial plans for users in a specific state/territory and allocate as required
Name | Rule Creation Mode | If condition | Then do this |
---|---|---|---|
AU-Local-02 | Advanced | ^([2-9]\d{7})$ | +612$1 |
AU-Local-03 | Advanced | ^([2-9]\d{7})$ | +613$1 |
AU-Local-07 | Advanced | ^([2-9]\d{7})$ | +617$1 |
AU-Local-08 | Advanced | ^([2-9]\d{7})$ | +618$1 |
Name | Rule Creation Mode | If condition | Then do this |
---|---|---|---|
NZ-National | Advanced | ^0([2\|3\|4\|6\|7\|9]{1}[0-9]{7})$ | +64$1 |
NZ-0800 | Advanced | ^(0800\d{6,7})$ | +64$1 |
NZ-0508 | Advanced | ^(0508\d{6,7})$ | +64$1 |
NZ-0900 | Advanced | ^(0900\d{6,7})$ | +64$1 |
NZ-Mobile | Advanced | ^0(2\d{7,9})$ | +64$1 |
Name | Rule Creation Mode | If condition | Then do this |
---|---|---|---|
NZ-Local-02 | Advanced | ^([2-9]\d{6})$ | +64$1 |
NZ-Local-03 | Advanced | ^([2-9]\d{6})$ | +64$1 |
NZ-Local-04 | Advanced | ^([2-9]\d{6})$ | +64$1 |
NZ-Local-06 | Advanced | ^([2-9]\d{6})$ | +64$1 |
These dialplan rules allow for additional features within myCloudPBX such as Star Codes.
Name | Rule Creation Mode | If condition | Then do this |
---|---|---|---|
Star Codes | Advanced | ^(\*\d*)$ | +61$1 |
Private Caller ID | Advanced | ^(1831\d*)$ | +61$1 |
Tip
You can create a Policy per country, or bundle them all into one.
Warning
If you use a single policy per country, or bundle them all into one policy, make sure that you have covered the emergency phone numbers for any Country that you are using on the PBX.
Proceed to add an Emergency Routing Policy for each Country you plan to support on the PBX.
Australia
AU 000 myCloudPBX
for the name of the Call routing policy000
for the dial stringNote
This list is not exhaustive of all Countries, please ensure you check which Emergency numbers are relevant to you.
Country | Emergency Phone Numbers |
---|---|
Australia | 000 |
New Zealand | 111 |
USA | 911 |
United Kingdon | 999 |
Set-CsPhoneNumberAssignment -Identity "ben@example.com" `
-PhoneNumber +61370006700 `
-PhoneNumberType DirectRouting
When no Caller ID is sent, myCloudPBX cannot validate the true Caller ID for logging and Call Detail Records (CDRs).
We'll still route the calls out for you, however we won't be able to pin the call down to a specific user and you'll need to review the logs from Microsoft Teams (in the event you need CDRs) instead of within the myCloudPBX Dashboard Reporting.
Whenever we do not receive a valid Caller ID, we will use the Default Caller ID configured on the Connector to ensure success of the call.
To address this, we've introduced a new feature in the myCloudPBX user interface. You can now choose to either send the Caller ID or hide it on a per-user basis.
When hidden, the Caller ID is concealed from the recipient, but it remains visible in the CDRs, enabling accurate tracking and analytics.