Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

S360 Item - Missing Get SubscriptionOperations for 2021-10-01 version. #24395

Merged
merged 10 commits into from
Jul 7, 2023
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"parameters": {
"operationId": "e4b8d068-f574-462a-a76f-6fa0afc613c9",
"api-version": "2021-10-01"
},
"responses": {
"202": {
ms-henglu marked this conversation as resolved.
Show resolved Hide resolved
"headers": {
"Location": "/providers/Microsoft.Subscription/subscriptionOperations/e4b8d068-f574-462a-a76f-6fa0afc613c9?api-version=2021-10-01",
"Retry-After": 8
}
},
"200": {
"body": {
"subscriptionLink": "/subscriptions/4df8d5c2-1b7e-4dd5-bc61-640704bde633"
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,57 @@
}
}
},
"/providers/Microsoft.Subscription/subscriptionOperations/{operationId}": {
"get": {
"description": "Get the status of the pending Microsoft.Subscription API operations.",
"operationId": "SubscriptionOperation_Get",
"x-ms-examples": {
"getPendingSubscriptionOperations": {
"$ref": "./examples/getSubscriptionOperation.json"
}
},
"responses": {
"200": {
"description": "Successful completion of the asynchronous operation",
"schema": {
"$ref": "#/definitions/SubscriptionCreationResult"
}
},
"202": {
ms-henglu marked this conversation as resolved.
Show resolved Hide resolved
"description": "Accepted. Subscription update is in progress.",
"headers": {
"Location": {
"description": "The URL where the status of the asynchronous operation can be checked.",
"type": "string"
},
"Retry-After": {
"description": "The amount of delay to use while the status of the operation is checked. The value is expressed in seconds.",
"type": "integer",
"format": "int64"
}
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse"
}
}
},
"parameters": [
{
"name": "operationId",
"in": "path",
"description": "The operation ID, which can be found from the Location field in the generate recommendation response header.",
"required": true,
"type": "string"
},
{
"$ref": "#/parameters/apiVersionParameter"
}
]
}
},
"/providers/Microsoft.Subscription/operations": {
"get": {
"description": "Lists all of the available Microsoft.Subscription API operations.",
Expand Down Expand Up @@ -573,6 +624,16 @@
}
}
},
"SubscriptionCreationResult": {
"description": "The created subscription object.",
"type": "object",
"properties": {
"subscriptionLink": {
"description": "The link to the new subscription. Use this link to check the status of subscription creation operation.",
"type": "string"
}
}
},
"SubscriptionName": {
"type": "object",
"description": "The new name of the subscription.",
Expand Down
11 changes: 11 additions & 0 deletions specification/subscription/resource-manager/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,17 @@ These settings apply only when `--tag=package-2021-10` is specified on the comma
input-file:
- Microsoft.Subscription/stable/2016-06-01/subscriptions.json
- Microsoft.Subscription/stable/2021-10-01/subscriptions.json
directive:
- where:
- $.paths["/providers/Microsoft.Subscription/subscriptionOperations/{operationId}"]
suppress:
- LroExtension
reason: Avoid Lro changes on this api to return 202.
- where:
- $.paths["/providers/Microsoft.Subscription/subscriptionOperations/{operationId}"]
suppress:
- GetOperation200
reason: This api will return 200 and 202 response.
title: SubscriptionClient
description: The subscription client
```
Expand Down