Test-CsInterTrunkRouting
Verifies the route and the PSTN usage used when routing a phone call made from a specified SIP trunk. This cmdlet was introduced in Lync Server 2013.
Syntax
Default (Default)
Test-CsInterTrunkRouting
-TargetNumber <PhoneNumber>
-TrunkConfiguration <TrunkConfiguration>
[-Force]
[-RouteSettings <PstnRoutingSettings>]
[<CommonParameters>]
Description
The Test-CsInterTrunkRouting
verifies that calls can be routed from one SIP to another.
To do this, the cmdlet is given a phone number and a trunk configuration; Test-CsInterTrunkRouting
will then report back matching routes and matching PSTN usages for the specified number.
Note that calls can be routed between trunks only if the trunks have a number pattern that matches the specified phone number and only if the trunks share at least one PSTN usage.
Skype for Business Server Control Panel: The functions carried out by the Test-CsInterTrunkRouting
cmdlet are not available in the Skype for Business Server Control Panel.
Examples
Example 1
$trunk = Get-CsTrunkConfiguration -Identity "site:Redmond"
Test-CsInterTrunkRouting -TargetNumber "tel:+12065551219" -TrunkConfiguration $trunk
The commands shown in Example 1 return the matching routes and matching phone usages that enable users to call the phone number 1-206-555-1219 using the trunk configuration settings for the Redmond site.
Parameters
-Force
Applicable: Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
Suppresses the display of any non-fatal error message that might arise when running the command.
Parameter properties
Type: | SwitchParameter |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-RouteSettings
Applicable: Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
Object reference that enables you to specify a collection of voice routing configuration settings when calling Test-CsInterTrunkRouting
.
To create this object reference, use a command similar to this:
$route = Get-CsRoutingConfiguration -Identity "global"
Parameter properties
Type: | PstnRoutingSettings |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-TargetNumber
Applicable: Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
PSTN telephone number to be called when conducting the test. The target phone number should specified using the E.164 format, which means that the number will look something like this:
-TargetNumber "tel:+12065551219"
The phone number should include the "tel:" prefix followed by a plus sign (+), the country/region calling code (1), the area code (206) and the phone number (5551219). Do not use dashes, parentheses, or any other characters when specifying the phone number.
Parameter properties
Type: | PhoneNumber |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | True |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-TrunkConfiguration
Applicable: Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
Object reference to the trunk configuration being tested. To create this object reference, use a command similar to this:
$trunk = Get-CsTrunkConfiguration -Identity "site:Redmond"
Parameter properties
Type: | TrunkConfiguration |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | True |
Value from pipeline: | True |
Value from pipeline by property name: | True |
Value from remaining arguments: | False |
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
Inputs
None
Test-CsInterTrunkRouting
does not accept pipelined input.
Outputs
Microsoft.Rtc.Management.Voice.InterTrunkRoutingTestResult
Test-CsInterTrunkRouting
returns instances of the Microsoft.Rtc.Management.Voice.InterTrunkRoutingTestResult object.