Test-CsTrunkConfiguration
Validates a trunk configuration against a phone number. This cmdlet was introduced in Lync Server 2010.
Syntax
Default (Default)
Test-CsTrunkConfiguration
-DialedNumber <PhoneNumber>
-TrunkConfiguration <TrunkConfiguration>
[-CallingNumber <PhoneNumber>]
[<CommonParameters>]
Description
Use this cmdlet to verify that a trunking configuration performs as expected against a dialed phone number. Each configuration contains specific settings defining the relationship and capabilities between the Mediation Server and the public switched telephone network (PSTN) gateway, IP-public branch exchange (PBX), or Session Border Controller (SBC) at the service provider. These settings configure such things as whether media bypass is enabled on this trunk, whether real-time transport control protocol (RTCP) packets are sent under certain conditions, and whether to require secure real-time protocol (SRTP) encryption.
Examples
Example 1
$tc = Get-CsTrunkConfiguration -Identity Site:Redmond
Test-CsTrunkConfiguration -DialedNumber 4255551212 -TrunkConfiguration $tc
This example runs a test against the trunk configuration defined for the Redmond site.
The first line in this example calls the Get-CsTrunkConfiguration
cmdlet to retrieve the configuration for the Redmond site (the configuration with the Identity site:Redmond).
The trunk configuration object retrieved is assigned to the variable $tc.
In line 2 we call the Test-CsTrunkConfiguration
cmdlet, passing the phone number to test to the DialedNumber parameter, and the trunk configuration we retrieved in line 1 (stored in $tc) to the TrunkConfiguration parameter.
Parameters
-CallingNumber
Applicable: Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
When specified, returns the matched outbound translation rules for the specified phone number. For example:
-CallingNumber "tel:+14255551219"
Parameter properties
Type: | PhoneNumber |
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 |
-DialedNumber
Applicable: Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
The phone number against which to test the configuration.
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 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
A reference to a trunk configuration object against which to run the test.
Trunk configuration objects can be retrieved by calling the Get-CsTrunkConfiguration
cmdlet.
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
Microsoft.Rtc.Management.WritableConfig.Settings.TrunkConfiguration.TrunkConfiguration
Accepts pipelined input of a trunk configuration object.
Outputs
Microsoft.Rtc.Management.Voice.TrunkConfigurationTestResult
Returns a value of type Microsoft.Rtc.Management.Voice.TrunkConfigurationTestResult.