Skip to content

Latest commit

 

History

History
170 lines (129 loc) · 4.77 KB

Get-AzApiManagementApiSchema.md

File metadata and controls

170 lines (129 loc) · 4.77 KB
external help file Module Name online version schema
Microsoft.Azure.PowerShell.Cmdlets.ApiManagement.ServiceManagement.dll-Help.xml
Az.ApiManagement
2.0.0

Get-AzApiManagementApiSchema

SYNOPSIS

Get the details of the API Schema

SYNTAX

ContextParameterSet (Default)

Get-AzApiManagementApiSchema -Context <PsApiManagementContext> -ApiId <String> [-SchemaId <String>]
 [-DefaultProfile <IAzureContextContainer>] [<CommonParameters>]

ResourceIdParameterSet

Get-AzApiManagementApiSchema -ResourceId <String> [-DefaultProfile <IAzureContextContainer>]
 [<CommonParameters>]

DESCRIPTION

The Get-AzApiManagementApiSchema cmdlet gets the details of the API Schema

EXAMPLES

Example 1: Get the details of all the Api Schema of an Api

$context = New-AzApiManagementContext -ResourceId /subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.ApiManagement/service/sdktestapim4163
Get-AzApiManagementApiSchema -Context $context -ApiId wsdlapitest
SchemaId           : 2a03e1b4-1826-4e59-b372-4711f575db28
Api Id             : wsdlapitest
Schema ContentType : xsdschema
Schema Document    : <s:schema elementFormDefault="qualified"....

SchemaId           : b6e5497d-f65a-4851-9f5b-b5684cdae688
Api Id             : wsdlapitest
Schema ContentType : xsdschema
Schema Document    : <?xml version=""1.0"" encoding=""UTF-8""....

This command gets all the API schemas associated with an Api swagger-petstore-extensive for particular ApiManagement Context.

Example 2: Get the specific schema associated with an Api

$context = New-AzApiManagementContext -ResourceId /subscriptions/subid/resourceGroups/resourceGroupName/providers/Microsoft.ApiManagement/service/sdktestapim4163
Get-AzApiManagementApiSchema -Context $context -ApiId swagger-petstore-extensive -SchemaId 5cc9cf67e6ed3b1154e638bd
SchemaId           : 5cc9cf67e6ed3b1154e638bd
Api Id             : swagger-petstore-extensive
Schema ContentType : swaggerdefinition
Schema Document    : {
                       "definitions": {
                         "pet": {
                        ....

This command gets the API schema 5cc9cf67e6ed3b1154e638bd associated with an Api swagger-petstore-extensive for particular ApiManagement Context.

PARAMETERS

-ApiId

API identifier to look for. If specified will try to get the API by the Id.

Type: System.String
Parameter Sets: ContextParameterSet
Aliases:

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

-Context

Instance of PsApiManagementContext. This parameter is required.

Type: Microsoft.Azure.Commands.ApiManagement.ServiceManagement.Models.PsApiManagementContext
Parameter Sets: ContextParameterSet
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByValue)
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
Parameter Sets: (All)
Aliases: AzContext, AzureRmContext, AzureCredential

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ResourceId

Arm Resource Identifier of a Api Schema. If specified will try to find api schema by the identifier. This parameter is required.

Type: System.String
Parameter Sets: ResourceIdParameterSet
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-SchemaId

The identifier of the Schema.

Type: System.String
Parameter Sets: ContextParameterSet
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

Microsoft.Azure.Commands.ApiManagement.ServiceManagement.Models.PsApiManagementContext

System.String

OUTPUTS

Microsoft.Azure.Commands.ApiManagement.ServiceManagement.Models.PsApiManagementApiSchema

NOTES

RELATED LINKS

New-AzApiManagementApiSchema

Remove-AzApiManagementApiSchema

Set-AzApiManagementApiSchema