Get-AzureRmEventHubAuthorizationRule
Gets the details of an authorization rule, or gets a list of authorization rules.
Warning
The AzureRM PowerShell module has been officially deprecated as of February 29, 2024. Users are advised to migrate from AzureRM to the Az PowerShell module to ensure continued support and updates.
Although the AzureRM module may still function, it's no longer maintained or supported, placing any continued use at the user's discretion and risk. Please refer to our migration resources for guidance on transitioning to the Az module.
Syntax
Get-AzureRmEventHubAuthorizationRule
[-ResourceGroupName] <String>
[-Namespace] <String>
[[-Name] <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzureRmEventHubAuthorizationRule
[-ResourceGroupName] <String>
[-Namespace] <String>
[-Eventhub] <String>
[[-Name] <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzureRmEventHubAuthorizationRule
[-ResourceGroupName] <String>
[-Namespace] <String>
[-AliasName] <String>
[[-Name] <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
The Get-AzureRmEventHubAuthorizationRule cmdlet gets either the details of an authorization rule, or a list of all authorization rules for a specified Event Hub. If the name of an authorization rule is provided, the details of that single authorization rule are returned. If the name of an authorization rule is not provided, a list of all authorization rules for the specified Event Hub is returned. If (Disaster Recovery) Alias name provided, the details of authorization rule of the Namespace for Alias configured is returned.
Examples
Example 1.0 - AuthorizationRule for namespace
PS C:\> Get-AzureRmEventHubAuthorizationRule -ResourceGroupName MyResourceGroupName -NamespaceName MyNamespaceName -Name MyAuthRuleName
Gets the authorization rule `MyAuthRuleName` in the namespace `MyNamespaceName`.
Example 1.1 - AuthorizationRules for namespace
PS C:\> Get-AzureRmEventHubAuthorizationRule -ResourceGroupName MyResourceGroupName -NamespaceName MyNamespaceName -EventHubName MyEventHubName
Gets a list of all authorization rules in the namespace `MyNamespaceName`.
Example 2.0 - AuthorizationRule for EventHub
PS C:\> Get-AzureRmEventHubAuthorizationRule -ResourceGroupName MyResourceGroupName -NamespaceName MyNamespaceName -EventHubName MyEventHubName -Name MyAuthRuleName
Gets the authorization rule `MyAuthRuleName` in the Event Hub `MyEventHubName`, which is scoped by the namespace `MyNamespaceName`.
Example 2.1 - AuthorizationRules for EventHub
PS C:\> Get-AzureRmEventHubAuthorizationRule -ResourceGroupName MyResourceGroupName -NamespaceName MyNamespaceName -EventHubName MyEventHubName
Gets list authorization rules in the Event Hub `MyEventHubName`, which is scoped by the namespace `MyNamespaceName`.
Example 3.0 - AuthorizationRule for Alias (GeoRecovery Configuration)
PS C:\> Get-AzureRmEventHubAuthorizationRule -ResourceGroupName MyResourceGroupName -NamespaceName MyNamespaceName -AliasName MyAliasNameName -Name MyAuthRuleName
Gets the authorization rule `MyAuthRuleName` in the namespace `MyNamespaceName`.
Example 3.1 -AuthorizationRules for Alias (GeoRecovery Configuration)
PS C:\> Get-AzureRmEventHubAuthorizationRule -ResourceGroupName MyResourceGroupName -NamespaceName MyNamespaceName -AliasName MyAliasNameName
Gets a list of all authorization rule `MyAuthRuleName` in the namespace `MyNamespaceName`.
Parameters
-AliasName
Alias Name
Type: | String |
Position: | 2 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-DefaultProfile
The credentials, account, tenant, and subscription used for communication with Azure.
Type: | IAzureContextContainer |
Aliases: | AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Eventhub
Eventhub Name
Type: | String |
Aliases: | EventHubName |
Position: | 2 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Name
AuthorizationRule Name
Type: | String |
Aliases: | AuthorizationRuleName |
Position: | 3 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Namespace
Namespace Name
Type: | String |
Aliases: | NamespaceName |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-ResourceGroupName
Resource Group Name
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |