Edit

Share via


Get-AzNotificationHubsNamespaceListKey

Gets the primary and secondary connection strings associated with a notification hub namespace authorization rule.

Syntax

Default (Default)

Get-AzNotificationHubsNamespaceListKey
    [-ResourceGroup] <String>
    [-Namespace] <String>
    [-AuthorizationRule] <String>
    [-DefaultProfile <IAzureContextContainer>]
    [<CommonParameters>]

Description

The Get-AzNotificationHubsNamespaceListKey cmdlet returns the primary and secondary connection strings for a Shared Access Signature (SAS) authorization rule assigned to a notification hub namespace. Authorization rules manage user rights to a notification hub namespace. Each rule includes a primary and a secondary connection string.

Examples

Example 1: Get the primary and secondary connection strings for an authorization rule

Get-AzNotificationHubsNamespaceListKey -Namespace "ContosoNamespace" -ResourceGroup "ContosoNotificationsGroup" -AuthorizationRule "ListenRule"

This command returns the primary and secondary connection strings for the authorization rule named ListenRule assigned to the ContosoNamespace namespace. When you run this command you must include the name of the resource group that the namespace is assigned to.

Parameters

-AuthorizationRule

Specifies the name of a SAS authentication rule. These rules determine the type of access that users have to the notification hub.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:2
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with azure

Parameter properties

Type:IAzureContextContainer
Default value:None
Supports wildcards:False
DontShow:False
Aliases:AzContext, AzureRmContext, AzureCredential

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Namespace

Specifies the namespace containing the connection strings that this cmdlet gets.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:1
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-ResourceGroup

Specifies the resource group to which the namespace is assigned. Resource groups organize items such as namespaces, notification hubs, and authorization rules in ways that help simply inventory management and Azure administration.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:0
Mandatory:True
Value from pipeline:False
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

String

Outputs

Microsoft.Azure.Management.NotificationHubs.Models.ResourceListKeys