Get-AzApiManagementGatewayHostnameConfiguration

Gets all or specific hostname configuration for the existing Gateway.

Syntax

Get-AzApiManagementGatewayHostnameConfiguration
   -Context <PsApiManagementContext>
   -GatewayId <String>
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]
Get-AzApiManagementGatewayHostnameConfiguration
   -Context <PsApiManagementContext>
   -GatewayId <String>
   -GatewayHostnameConfigurationId <String>
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]

Description

The Get-AzApiManagementGatewayHostnameConfiguration cmdlet gets all or specific hostname configuration for the existing Gateway.

Examples

Example 1: Get all hostname configurations for the gateway

PS C:\>$apimContext = New-AzApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"
PS C:\>Get-AzApiManagementGatewayHostnameConfiguration -Context $apimContext  -GatewayId "0123456789"

This command gets all hostname configurations for a "0123456789" gateway.

Example 2: Get a hostname configuration for the gateway

PS C:\>$apimContext = New-AzApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"
PS C:\>Get-AzApiManagementGatewayHostnameConfiguration -Context $apimContext -GatewayId "0123456789" -GatewayHostnameConfigurationId "123"

This command gets "123" hostname configuration for a "0123456789" gateway.

Parameters

-Context

Instance of PsApiManagementContext. This parameter is required.

Type:PsApiManagementContext
Position:Named
Default value:None
Accept pipeline input:True
Accept wildcard characters:False
-DefaultProfile

The credentials, account, tenant, and subscription used for communication with Azure.

Type:Microsoft.Azure.Commands.Common.Authentication.Abstractions.Core.IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-GatewayHostnameConfigurationId

Hostname Configuration identifier. This parameter is optional.

Type:String
Position:Named
Default value:None
Accept pipeline input:True
Accept wildcard characters:False
-GatewayId

Gateway identifier. This parameter is required.

Type:String
Position:Named
Default value:None
Accept pipeline input:True
Accept wildcard characters:False

Inputs

PsApiManagementContext

String

Outputs

Microsoft.Azure.Commands.ApiManagement.ServiceManagement.Models.PsApiManagementGatewayHostnameConfiguration