Get-​Azure​Rm​Relay​Key

Gets the primary and secondary connection strings for the given Relay entities (Namespace/WcfRelay/HybridConnection).

Syntax

Get-AzureRmRelayKey
   [-ResourceGroupName] <String>
   [[-Namespace] <String>]
   [-HybridConnection] <String>
   [-Name] <String>
   [<CommonParameters>]
Get-AzureRmRelayKey
   [-ResourceGroupName] <String>
   [-Namespace] <String>
   [-Name] <String>
   [<CommonParameters>]
Get-AzureRmRelayKey
   [-ResourceGroupName] <String>
   [[-Namespace] <String>]
   [-WcfRelay] <String>
   [-Name] <String>
   [<CommonParameters>]

Description

The Get-AzureRmRelayKey cmdlet returns the primary and secondary connection strings for the given Relay entities (Namespace/WcfRelay/HybridConnection).

Examples

Example 1 - Namespace

PS C:\> Get-AzureRmRelayKey -ResourceGroupName Default-ServiceBus-WestUS -Namespace TestNameSpace-Relay1 -Name AuthoRule1

Example 2 - WcfRelay

PS C:\> Get-AzureRmRelayKey -ResourceGroupName Default-ServiceBus-WestUS -Namespace TestNameSpace-Relay1  -WcfRelay TestWCFRelay1 -Name AuthoRule1

Example 3 - HybridConnection

PS C:\> Get-AzureRmRelayKey -ResourceGroupName Default-ServiceBus-WestUS -Namespace TestNameSpace-Relay1 -HybridConnection TestHybridConnection -Name AuthoRule1

Primary and secondary connection string to the specified Relay entities (Namespace/WcfRelay/HybridConnection).

Required Parameters

-HybridConnection

HybridConnection Name.

Type:String
Position:2
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Name

AuthorizationRule Name.

Type:String
Position:3
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Namespace

Namespace Name.

Type:String
Position:1
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-ResourceGroupName

Resource Group Name.

Type:String
Position:0
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-WcfRelay

WcfRelay Name.

Type:String
Position:2
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Inputs

-ResourceGroupName

System.String

Inputs

-NamespaceName

System.String

Inputs

-HybridConnectionsName

System.String

Inputs

-WcfRelayName

System.String

Inputs

-Name

System.String

Outputs

Microsoft.Azure.Commands.Relay.Models.AuthorizationRuleKeysAttributes

Outputs

Example 1 - Namespace

PrimaryConnectionString : Endpoint=sb://testnamespace-relay1.servicebus.windows.net/;SharedAccessKeyName=AuthoRule1;SharedAccessKey=############################################ SecondaryConnectionString : Endpoint=sb://testnamespace-relay1.servicebus.windows.net/;SharedAccessKeyName=AuthoRule1;SharedAccessKey=############################################ PrimaryKey : ############################################ SecondaryKey : ############################################ KeyName : AuthoRule1

Outputs

Example 2 - WcfRelay

PrimaryConnectionString : Endpoint=sb://testnamespace-relay1.servicebus.windows.net/;SharedAccessKeyName=AuthoRule1;SharedAccessKey=############################################;EntityPath=TestWCFRelay1 SecondaryConnectionString : Endpoint=sb://testnamespace-relay1.servicebus.windows.net/;SharedAccessKeyName=AuthoRule1;SharedAccessKey=############################################;EntityPath=TestWCFRelay1 PrimaryKey : ############################################ SecondaryKey : ############################################ KeyName : AuthoRule1

Outputs

Example 3 - HybridConnection

PrimaryConnectionString : Endpoint=sb://testnamespace-relay1.servicebus.windows.net/;SharedAccessKeyName=AuthoRule1;SharedAccessKey=############################################;EntityPath=TestHybridConnection SecondaryConnectionString : Endpoint=sb://testnamespace-relay1.servicebus.windows.net/;SharedAccessKeyName=AuthoRule1;SharedAccessKey=############################################;EntityPath=TestHybridConnection PrimaryKey : ############################################ SecondaryKey : ############################################ KeyName : AuthoRule1