Get-AzApiManagementApiVersionSet
Get the details of the API Version Sets
Syntax
Get-AzApiManagementApiVersionSet
-Context <PsApiManagementContext>
[-ApiVersionSetId <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzApiManagementApiVersionSet
-Context <PsApiManagementContext>
[-ApiVersionSetId <String>]
-ResourceId <String>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
The Get-AzApiManagementApiVersionSet cmdlet gets the details of the API Version Sets configured in an API Management context.
Examples
Example 1: Get all API Version Sets
$ApiMgmtContext = New-AzApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"
Get-AzApiManagementApiVersionSet -Context $ApiMgmtContext
ApiVersionSetId : a93316c8-8b88-46cc-8260-380789a5d598
Description :
VersionQueryName :
VersionHeaderName :
DisplayName : Echo API
VersioningScheme : Segment
Id : /subscriptions/subid/resourceGroups/Api-Default-WestUS/providers/Microsoft.ApiManagement/service/contoso/api-version-sets/a916c8-8b88-46cc-8260-380789a5d598
ResourceGroupName : Api-Default-WestUS
ServiceName : contoso
ApiVersionSetId : 4cbdfa34-25f3-4a93-a9b6-76b6eade7562
Description :
VersionQueryName : api-version
VersionHeaderName :
DisplayName : getproduct old
VersioningScheme : Query
Id : /subscriptions/subid/resourceGroups/Api-Default-WestUS/providers/Microsoft.ApiManagement/service/contoso/api-version-sets/4cbdfa34-25f3-4a93-a9b6-76b6eade7562
ResourceGroupName : Api-Default-WestUS
ServiceName : contoso
ApiVersionSetId : 8c441e0e-a0cd-47d8-8d88-f944a83b41bd
Description :
VersionQueryName :
VersionHeaderName : Api-Version
DisplayName : ordersapi
VersioningScheme : Header
Id : /subscriptions/subid/resourceGroups/Api-Default-WestUS/providers/Microsoft.ApiManagement/service/contoso/api-version-sets/8c441e0e-a0cd-47d8-8d88-f944a83b41bd
ResourceGroupName : Api-Default-WestUS
ServiceName : contoso
This command gets all of the API Version sets for the specified context.
Example 2: Get a API Version Set by ID
$ApiMgmtContext = New-AzApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"
Get-AzApiManagementApiVersionSet -Context $ApiMgmtContext -ApiVersionSetId $ApiVersionSetId
ApiVersionSetId : 8c441e0e-a0cd-47d8-8d88-f944a83b41bd
Description :
VersionQueryName :
VersionHeaderName : Api-Version
DisplayName : ordersapi
VersioningScheme : Header
Id : /subscriptions/subid/resourceGroups/Api-Default-WestUS/providers/Microsoft.ApiManagement/service/contoso/api-version-sets/8c441e0e-a0cd-47d8-8d88-f944a83b41bd
ResourceGroupName : Api-Default-WestUS
ServiceName : contoso
This command gets the API Version Set with the specified ID.
Parameters
-ApiVersionSetId
API identifier to look for. If specified will try to get the API by the Id.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Context
Instance of PsApiManagementContext. This parameter is required.
Type: | PsApiManagementContext |
Position: | Named |
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: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ResourceId
Arm Resource Identifier of the ApiVersionSet. If specified will try to find apiVersionSet by the identifier. This parameter is required.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |