Edit

Share via


Get-AzEventHub

Gets the details of a single Event Hub, or gets a list of Event Hubs.

Syntax

Default (Default)

Get-AzEventHub
    [-ResourceGroupName] <String>
    [-Namespace] <String>
    [[-Name] <String>]
    [-MaxCount <Int32>]
    [-DefaultProfile <IAzureContextContainer>]
    [<CommonParameters>]

Description

The Get-AzEventHub cmdlet returns either the details of an Event Hub, or a list of all Event Hubs in the current namespace. If the Event Hub name is provided, the details of a single Event Hub are returned. If an Event Hub name is not provided, a list of all Event Hubs in the specified namespace is returned.

Examples

Example 1 - specified EventHub

PS C:\> Get-AzEventHub -ResourceGroupName MyResourceGroupName -NamespaceName MyNamespaceName -EventHubName MyEventHubName

Returns the details of the Event Hub `MyEventHubName`.

Example 2 - List of EventHub in specified Namespace

PS C:\> Get-AzEventHub -ResourceGroup MyResourceGroupName -NamespaceName MyNamespaceName

Returns a list of Event Hubs in the namespace `MyNamespaceName`.

Parameters

-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

-MaxCount

Determine the maximum number of EventHubs to return.

Parameter properties

Type:

Nullable<T>[Int32]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

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

-Name

EventHub Name

Parameter properties

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

Parameter sets

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

-Namespace

Namespace Name

Parameter properties

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

Parameter sets

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

-ResourceGroupName

Resource Group Name

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

PSEventHubAttributes