Topic Last Modified: 2013-08-13

Retrieves a hosted voice mail policy. This cmdlet was introduced in Lync Server 2010.

Syntax

Get-CsHostedVoicemailPolicy [-Identity <XdsIdentity>] <COMMON PARAMETERS>
Get-CsHostedVoicemailPolicy [-Filter <String>] <COMMON PARAMETERS>
COMMON PARAMETERS: [-LocalStore <SwitchParameter>] [-Tenant <Guid>]

Examples

EXAMPLE 1

This command returns all defined hosted voice mail policies for the Lync Server implementation.

Copy Code
Get-CsHostedVoicemailPolicy

EXAMPLE 2

This command returns the policy settings for the per-user hosted voice mail policy ExRedmond.

Copy Code
Get-CsHostedVoicemailPolicy -Identity ExRedmond

EXAMPLE 3

This command returns the policy settings for all per-user hosted voice mail policies (policies beginning with the tag scope).

Copy Code
Get-CsHostedVoicemailPolicy -Filter tag:*

EXAMPLE 4

This command returns the hosted voice mail policy for the Lync Online tenant with the tenant ID 73d355dd-ce5d-4ab9-bf49-7b822c18dd98.

Copy Code
Get-CsHostedVoicemailPolicy -Tenant "73d355dd-ce5d-4ab9-bf49-7b822c18dd98"

Detailed Description

This cmdlet retrieves a policy that specifies how to route unanswered calls to a user to a hosted Exchange Unified Messaging (UM) service.

A user must be enabled for Exchange UM hosted voice mail for this policy to take effect. You can call the Get-CsUser cmdlet and check the HostedVoiceMail property to determine whether a user is enabled for hosted voice mail. (A value of True means the user is enabled.)

Who can run this cmdlet: By default, members of the following groups are authorized to run the Get-CsHostedVoicemailPolicy cmdlet locally: RTCUniversalUserAdmins, RTCUniversalServerAdmins. To return a list of all the role-based access control (RBAC) roles this cmdlet has been assigned to (including any custom RBAC roles you have created yourself), run the following command from the Windows PowerShell prompt:

Get-CsAdminRole | Where-Object {$_.Cmdlets –match "Get-CsHostedVoicemailPolicy"}

Copy Code

Parameters

Parameter Required Type Description

Filter

Optional

System.String

This parameter allows you to do a wildcard search on the Identity of the hosted voice mail policy. This will retrieve all instances of a hosted voice mail policy where the Identity matches the wildcard pattern specified in the Filter value.

Identity

Optional

Microsoft.Rtc.Management.Xds.XdsIdentity

The unique identifier for the hosted voice mail policy you want to retrieve. The Identity includes the scope (in the case of global), the scope and site (for a site policy, such as site:Redmond), or the policy name (for a per-user policy, such as HVUserPolicy).

LocalStore

Optional

System.Management.Automation.SwitchParameter

Retrieves the hosted voice mail policy from the local replica of the Central Management store, rather than the Central Management store itself.

Tenant

Optional

System.Guid

Globally unique identifier (GUID) of the Lync Online tenant account whose voicemail policy is to be retrieved.

For example:

–Tenant "38aad667-af54-4397-aaa7-e94c79ec2308"

You can return the tenant ID for each of your tenants by running this command:

Get-CsTenant | Select-Object DisplayName, TenantID

If you are using a remote session of Windows PowerShell and are connected only to Lync Online you do not have to include the Tenant parameter. Instead, the tenant ID will automatically be filled in for you based on your connection information. The Tenant parameter is primarily for use in a hybrid deployment.

Input Types

None.

Return Types

This cmdlet returns an object of type Microsoft.Rtc.Management.WritableConfig.Policy.Voice.HostedVoicemailPolicy

See Also