azure-rest-api-specs-1/specification/marketplaceordering/resource-manager
meirloichter d82babc9bd
[S360 fix] Add details field to ErrorResponse (#22910)
merge with breaking change approved
2023-03-09 15:50:36 +08:00
..
Microsoft.MarketplaceOrdering/stable [S360 fix] Add details field to ErrorResponse (#22910) 2023-03-09 15:50:36 +08:00
readme.az.md add readme.cli.md for marketplaceordering (#12484) 2021-05-18 14:29:14 +08:00
readme.cli.md add readme.cli.md for marketplaceordering (#12484) 2021-05-18 14:29:14 +08:00
readme.go.md Track2 modify readme.go.md 6 (#16949) 2021-12-07 10:49:24 +08:00
readme.md Migrate to net track2 for some resource-manager readmes batch 3 (#21241) 2022-10-28 17:12:34 +08:00
readme.nodejs.md
readme.python.md update readme.python.md (#18250) 2022-03-16 15:37:04 +08:00
readme.ruby.md
readme.typescript.md update-typescript.md (#17182) 2022-01-06 08:28:20 +08:00

readme.md

Marketplace Agreements API

see https://aka.ms/autorest

The underlying APIs are available to users who would like to write their own REST calls. These APIs would allow the user to accept the terms at a subscription, offer and SKU level. These apis are invoked in the context of azure subscription.


GetAzureRmMarketplaceTerms

Request

This api returns the latest terms for a given Subscription, Publisher, Product and Name.

Reply

200 OK. Agreement Terms in response body.

SaveAzureRmMarketplaceTerms

Request

This api sends the license information retrieved by the first API along with Accepted flag which confirms that the terms are accepted(true) or not accepted(false).

Reply

  1. 200 OK. The request was successfully processed and the terms were accepted or acceptance revoked as per the request body.
  2. 400 Bad/Malformed request. E.g. Signature doesnt match, please retrieve terms again and request acceptance.
  3. 403 Forbidden. E.g. The caller does not have permission to accept terms for given subscription. (only a reader).
  4. 404 E.g. The Publisher/Offer/Plan tuple is not a valid virtual machine.

Getting Started

To build the SDK for Marketplace Agreements, simply Install AutoRest and in this folder, run:

autorest

To see additional help and options, run:

autorest --help


Configuration

Basic Information

These are the global settings for the Marketplace Agreements API.

openapi-type: arm
tag: package-2021-01-01

Tag: package-2021-01-01

These settings apply only when --tag=package-2021-01-01 is specified on the command line.

input-file:
- Microsoft.MarketplaceOrdering/stable/2021-01-01/Agreements.json

Tag: package-2015-06-01

These settings apply only when --tag=package-2015-06-01 is specified on the command line.

input-file:
- Microsoft.MarketplaceOrdering/stable/2015-06-01/Agreements.json
directive:
  # suppress each RPC 3016 error
- where: $.definitions.UnsupportedMediaTypeErrorResponse.properties.Message
  suppress: R3016
  reason: This requires a change in code thats in production for several years

Code Generation

Swagger to SDK

This section describes what SDK should be generated by the automatic system. This is not used by Autorest itself.

swagger-to-sdk:
  - repo: azure-sdk-for-net-track2
  - repo: azure-sdk-for-python-track2
  - repo: azure-sdk-for-go
  - repo: azure-sdk-for-js
  - repo: azure-sdk-for-node
  - repo: azure-sdk-for-ruby
    after_scripts:
      - bundle install && rake arm:regen_all_profiles['azure_mgmt_marketplace_ordering']
  - repo: azure-resource-manager-schemas
  - repo: azure-powershell

C#

These settings apply only when --csharp is specified on the command line. Please also specify --csharp-sdks-folder=<path to "SDKs" directory of your azure-sdk-for-net clone>.

csharp:
  azure-arm: true
  license-header: MICROSOFT_MIT_NO_VERSION
  namespace: Microsoft.Azure.Management.MarketplaceOrdering
  output-folder: $(csharp-sdks-folder)/marketplaceordering/Microsoft.Azure.Management.MarketplaceOrdering/src/Generated
  clear-output-folder: true

Python

See configuration in readme.python.md

Node.js

directive:
  - from: swagger-document
    where: $.definitions.AgreementProperties.properties.retrieveDatetime
    transform: delete $.format

TypeScript

directive:
  - from: swagger-document
    where: $.definitions.AgreementProperties.properties.retrieveDatetime
    transform: delete $.format

Go

See configuration in readme.go.md

Java

These settings apply only when --java is specified on the command line. Please also specify --azure-libraries-for-java-folder=<path to the root directory of your azure-libraries-for-java clone>.

azure-arm: true
fluent: true
namespace: com.microsoft.azure.management.marketplaceordering
license-header: MICROSOFT_MIT_NO_CODEGEN
payload-flattening-threshold: 1
output-folder: $(azure-libraries-for-java-folder)/azure-mgmt-marketplaceordering

Java multi-api

batch:
  - tag: package-2015-06-01

Tag: package-2015-06-01 and java

These settings apply only when --tag=package-2015-06-01 --java is specified on the command line. Please also specify --azure-libraries-for-java=<path to the root directory of your azure-sdk-for-java clone>.

java:
  namespace: com.microsoft.azure.management.marketplaceagreementsapi.v2015_06_01
  output-folder: $(azure-libraries-for-java-folder)/sdk/marketplaceagreementsapi/mgmt-v2015_06_01
regenerate-manager: true
generate-interface: true