Editar

Compartir a través de


Set-CsRoutingConfiguration

Modifies a list of voice routes. This cmdlet was introduced in Lync Server 2010.

Syntax

Set-CsRoutingConfiguration
   [[-Identity] <XdsIdentity>]
   [-Route <PSListModifier>]
   [-Force]
   [-WhatIf]
   [-Confirm]
   [-CallViaWorkCallerId <String>]
   [-EnableLocationBasedRouting <Boolean>]
   [<CommonParameters>]
Set-CsRoutingConfiguration
   [-Instance <PSObject>]
   [-Route <PSListModifier>]
   [-Force]
   [-WhatIf]
   [-Confirm]
   [-CallViaWorkCallerId <String>]
   [-EnableLocationBasedRouting <Boolean>]
   [<CommonParameters>]

Description

Voice routes contain instructions that tell Skype for Business Server how to route calls from Enterprise Voice users to phone numbers on the public switched telephone network (PSTN) or a private branch exchange (PBX). With this cmdlet you can modify the settings of any voice route defined within a Skype for Business Server deployment.

The use of this cmdlet is not recommended. To modify routing configurations, modify the individual voice routes by calling the Set-CsVoiceRoute cmdlet.

Examples

-------------------------- Example 1 --------------------------

$a = Get-CsRoutingConfiguration

$b = $a.Route | Where-Object {$_.Name -match "LocalRoute"}

$b.SuppressCallerId = $False

Set-CsRoutingConfiguration -Instance $a

It takes several steps to modify a voice route within a routing configuration. In this example, we start by retrieving the routing configuration object by calling the Get-CsRoutingConfiguration cmdlet. We assign the object retrieved (there will be only one) to the variable $a.

In line 2 of this example we retrieve the contents of the Route property from variable $a, which is a collection of voice route objects. We then pipe that collection to the Where-Object cmdlet, where we search the collection for all voice route objects with a Name matching the string LocalRoute. We assign that object to the variable $b.

Next, we modify the LocalRoute voice route object by assigning the value $False to the property SuppressCallerId. By updating that object we've updated the object in variable $a. However, that object is still only in memory. As a final step, we need to save those changes by passing $a to the Instance parameter of the Set-CsRoutingConfiguration cmdlet.

This is not the recommended way of modifying a routing configuration. To modify a routing configuration, simply change the individual voice routes with the Set-CsVoiceRoute cmdlet, as shown here:

Set-CsVoiceRoute -Identity LocalRoute -SuppressCallerId $False

That one line will accomplish the same task shown in Example 1.

Parameters

-CallViaWorkCallerId

The number the system will display for the callback portion of an external call. External calls first connect the user making the call by calling a specified number (typically the user's desk phone), once connected to the user, the system dials the outside number. The CallViaWorkCallerId parameter specifies the number that will be displayed during the first leg, or callback segment, of the call via work external call. For more information, see New-CsCallViaWorkPolicy.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Skype for Business Server 2015, Skype for Business Server 2019

-Confirm

Prompts you for confirmation before executing the command.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-EnableLocationBasedRouting

When set to True, voice routing will be managed by taking into account the location of both the user placing the call and the user receiving the call. The default value is False.

Type:Boolean
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Skype for Business Server 2015, Skype for Business Server 2019

-Force

Suppresses any confirmation prompts that would otherwise be displayed before making changes.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-Identity

The scope of the routing configuration. This must be Global.

Type:XdsIdentity
Position:2
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-Instance

A routing configuration (Microsoft.Rtc.Management.WritablConfig.Policy.Voice.PstnRoutingSettings) object. An object of this type can be retrieved by calling the Get-CsRoutingConfiguration cmdlet.

Type:PSObject
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-Route

A list of all voice routes (Microsoft.Rtc.Management.WritableConfig.Policy.Voice.Route objects) defined for the Skype for Business Server deployment.

You should modify individual voice route objects by using the Set-CsVoiceRoute cmdlet. That is the recommended way of modifying routes in this list.

Type:PSListModifier
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

-WhatIf

Describes what would happen if you executed the command without actually executing the command.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019

Inputs

Microsoft.Rtc.WritableConfig.Management.Policy.Voice.PSTNRoutingSettings object. Accepts pipelined input of a routing configuration object.

Outputs

The Set-CsRoutingConfiguration cmdlet does not return a value or object. Instead, the cmdlet configures instances of the Microsoft.Rtc.Management.WritableConfig.Policy.Voice.PstnRoutingSettings object.