Get-AzApiManagementAuthorizationServer

Gets an API Management authorization server.

Syntax

Get-AzApiManagementAuthorizationServer
   -Context <PsApiManagementContext>
   [-ServerId <String>]
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]
Get-AzApiManagementAuthorizationServer
   [-ServerId <String>]
   -ResourceId <String>
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]

Description

The Get-AzApiManagementAuthorizationServer cmdlet gets all Azure API Management authorization servers or specified authorization server. ClientSecret will not be included into result details. To get client secret, use Get-AzApiManagementAuthorizationServerClientSecret.

Examples

Example 1: Get all authorization servers

PS C:\>$ApiMgmtContext = New-AzApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"
PS C:\>Get-AzApiManagementAuthorizationServer -Context $ApiMgmtContext

This command gets all API Management authorization servers.

Example 2: Get a specified authorization server

PS C:\>$ApiMgmtContext = New-AzApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"
PS C:\>Get-AzApiManagementAuthorizationServer -Context $ApiMgmtContext -ServerId "0123456789"

This command gets the specified authorization server.

Parameters

-Context
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
-ResourceId

Arm Resource Identifier of the authorization server. If specified will try to find authorization server by the identifier. This parameter is required.

Type:String
Position:Named
Default value:None
Accept pipeline input:True
Accept wildcard characters:False
-ServerId
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.PsApiManagementOAuth2AuthorizationServer