Skip to content

APIM ARM template generated using Azure CLI dotnet command is giving error while deploying through Azure devops #1392

Description

@payalKumariSA

APIM ARM template deployment failed.

##Description
We updated the API version to 2021-08-01. And then deployed the ARM template but got error saying. Operation refences schema that does not exists.
When we connected with microsoft team they suggested to make the schema name same as TypeName property in the operations referring to the schema.

Steps to reproduce

  1. Enable the API minimum version in the API management service in Azure Portal
  2. Create an API with schema like ErrorMessage, SuccessMessage (without space)
  3. Generated ARM template using below command
    dotnet "C:\Users\f07286\source\repos\azure-api-management-devops-resource-kit-main\azure-api-management-devops-resource-kit-main\src\ArmTemplates\bin\Debug\net6.0\ArmTemplates.dll" extract --sourceApimName sourcse-apim --destinationApimName " " --resourceGroup "rg-sample-apim" --apiName your-api-v2 --fileFolder "C:\order-extract-test" --paramNamedValue "true"
  4. Deploy the ARM template using using devops
    .

this is the template used by our project
orders-api.uat.parameters.json
orders-api-orders-api-v2-api.template.json

Expected behavior

It should deploy the API in the Azure portal

Actual behavior

It fails with the below error.
MicrosoftTeams-image (68)

Why the generated template using APIM extract kit code does not work as it is. Why we need to modify to the schema name to make it work.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions