Skip to content

Commit

Permalink
Backfilling Microsoft.Resources and subscriptions Swagger specs up to…
Browse files Browse the repository at this point in the history
… 2019-03-01 API version (#5529)

* Copied 2018-05-01 resources.json spec with examples and 2016-06-01
subscriptions.json with examples to use as baseline for other changes.

* Subscription tenantId was added in 2018-06-01

* registrationPolicy was added to Provider in 2018-07-01

* API changes in 2018-09-01 do not impact swagger

* In 2019-03-01, capabilities property always shows up

* Removed intermediate API versions

* Updated config files

* Removed unreferenced managed identity example because there is no corresponding path in the Microsoft.Resources swagger

* Added missing references to onError deployment PUT examples

* Fixed example validation errors

* Fixed example timestamp format violations
  • Loading branch information
majastrz authored and veronicagg committed Apr 9, 2019
1 parent 6169596 commit c54ce0f
Show file tree
Hide file tree
Showing 15 changed files with 4,258 additions and 51 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"parameters": {
"subscriptionId": "{subscriptionId}",
"resourceGroupName": "myResourceGroup",
"deploymentName": "{deploymentName}",
"deploymentName": "exampleDeploymentName",
"api-version": "2018-02-01",
"parameters": {
"properties": {
Expand All @@ -16,14 +16,30 @@
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timestamp": "2018-02-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "LastSuccessful",
"deploymentName": "{nameOfLastSuccesfulDeployment}"
}
}
}
},
"201": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/{deploymentName}",
"name": "{deploymentName}",
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timeStamp": "{timeStamp}",
"timestamp": "2018-02-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "LastSuccessful",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"parameters": {
"subscriptionId": "{subscriptionId}",
"resourceGroupName": "myResourceGroup",
"deploymentName": "{deploymentName}",
"deploymentName": "exampleDeploymentName",
"api-version": "2018-02-01",
"parameters": {
"properties": {
Expand All @@ -17,14 +17,30 @@
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timestamp": "2018-02-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "SpecificDeployment",
"deploymentName": "{nameOfDeploymentToUse}"
}
}
}
},
"201": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/{deploymentName}",
"name": "{deploymentName}",
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timeStamp": "{timeStamp}",
"timestamp": "2018-02-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "SpecificDeployment",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,14 @@
}
}
},
"x-ms-examples": {
"Create a deployment that will redeploy the last successful deployment on failure": {
"$ref": "./examples/PutDeploymentWithOnErrorDeploymentLastSuccessful.json"
},
"Create a deployment that will redeploy another deployment on failure": {
"$ref": "./examples/PutDeploymentWithOnErrorDeploymentSpecificDeployment.json"
}
},
"x-ms-long-running-operation": true
},
"get": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"parameters": {
"subscriptionId": "{subscriptionId}",
"resourceGroupName": "myResourceGroup",
"deploymentName": "{deploymentName}",
"deploymentName": "exampleDeploymentName",
"api-version": "2018-05-01",
"parameters": {
"properties": {
Expand All @@ -16,14 +16,30 @@
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timestamp": "2018-05-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "LastSuccessful",
"deploymentName": "{nameOfLastSuccesfulDeployment}"
}
}
}
},
"201": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/{deploymentName}",
"name": "{deploymentName}",
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timeStamp": "{timeStamp}",
"timestamp": "2018-05-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "LastSuccessful",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"parameters": {
"subscriptionId": "{subscriptionId}",
"resourceGroupName": "myResourceGroup",
"deploymentName": "{deploymentName}",
"deploymentName": "exampleDeploymentName",
"api-version": "2018-05-01",
"parameters": {
"properties": {
Expand All @@ -17,14 +17,30 @@
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timestamp": "2018-05-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "SpecificDeployment",
"deploymentName": "{nameOfDeploymentToUse}"
}
}
}
},
"201": {
"body": {
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/{deploymentName}",
"name": "{deploymentName}",
"id": "/subscriptions/{subscriptionId}/resourcegroups/myResourceGroup/providers/Microsoft.Resources/deployments/exampleDeploymentName",
"name": "exampleDeploymentName",
"properties": {
"provisioningState": "Accepted",
"correlationId": "{correlationId}",
"timeStamp": "{timeStamp}",
"timestamp": "2018-05-01T00:00:00.0000000Z",
"mode": "Complete",
"onErrorDeployment": {
"type": "SpecificDeployment",
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -521,6 +521,14 @@
}
}
},
"x-ms-examples": {
"Create a deployment that will redeploy the last successful deployment on failure": {
"$ref": "./examples/PutDeploymentWithOnErrorDeploymentLastSuccessful.json"
},
"Create a deployment that will redeploy another deployment on failure": {
"$ref": "./examples/PutDeploymentWithOnErrorDeploymentSpecificDeployment.json"
}
},
"x-ms-long-running-operation": true
},
"get": {
Expand Down
Loading

0 comments on commit c54ce0f

Please sign in to comment.