From ede1cee0f8ba6f5ed30dd56b4084f2364564baeb Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Wed, 29 Mar 2023 15:35:33 +0000 Subject: [PATCH] CodeGen from PR 23142 in Azure/azure-rest-api-specs Merge c5ee0a45f9259060a036177d29d3b264005ef739 into 855e88fcf04c07753bf822e693e4616c4ea67d90 --- .../subscriptionDeploymentTemplate.json | 6 + .../managementGroupDeploymentTemplate.json | 3 + .../Microsoft.Resources.json | 554 ++++++++++++++++++ schemas/common/autogeneratedResources.json | 3 + 4 files changed, 566 insertions(+) create mode 100644 schemas/2022-08-01-preview/Microsoft.Resources.json diff --git a/schemas/2018-05-01/subscriptionDeploymentTemplate.json b/schemas/2018-05-01/subscriptionDeploymentTemplate.json index 2d48a7d457..cf121f65c4 100644 --- a/schemas/2018-05-01/subscriptionDeploymentTemplate.json +++ b/schemas/2018-05-01/subscriptionDeploymentTemplate.json @@ -1352,6 +1352,12 @@ { "$ref": "https://schema.management.azure.com/schemas/2022-02-01/Microsoft.Resources.json#/subscription_resourceDefinitions/resourceGroups" }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-08-01-preview/Microsoft.Resources.json#/subscription_resourceDefinitions/deploymentStacks" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-08-01-preview/Microsoft.Resources.json#/subscription_resourceDefinitions/resourceGroups" + }, { "$ref": "https://schema.management.azure.com/schemas/2022-09-01/Microsoft.Resources.json#/subscription_resourceDefinitions/deployments" }, diff --git a/schemas/2019-08-01/managementGroupDeploymentTemplate.json b/schemas/2019-08-01/managementGroupDeploymentTemplate.json index 621f826b49..3f9431e875 100644 --- a/schemas/2019-08-01/managementGroupDeploymentTemplate.json +++ b/schemas/2019-08-01/managementGroupDeploymentTemplate.json @@ -851,6 +851,9 @@ { "$ref": "https://schema.management.azure.com/schemas/2021-04-01/Microsoft.Resources.json#/unknown_resourceDefinitions/tags" }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-08-01-preview/Microsoft.Resources.json#/managementGroup_resourceDefinitions/deploymentStacks" + }, { "$ref": "https://schema.management.azure.com/schemas/2022-09-01/Microsoft.Resources.json#/managementGroup_resourceDefinitions/deployments" }, diff --git a/schemas/2022-08-01-preview/Microsoft.Resources.json b/schemas/2022-08-01-preview/Microsoft.Resources.json new file mode 100644 index 0000000000..1105f88fc1 --- /dev/null +++ b/schemas/2022-08-01-preview/Microsoft.Resources.json @@ -0,0 +1,554 @@ +{ + "id": "https://schema.management.azure.com/schemas/2022-08-01-preview/Microsoft.Resources.json#", + "$schema": "http://json-schema.org/draft-04/schema#", + "title": "Microsoft.Resources", + "description": "Microsoft Resources Resource Types", + "resourceDefinitions": { + "deploymentStacks": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-08-01-preview" + ] + }, + "location": { + "type": "string", + "description": "The location of the deployment stack. It cannot be changed after creation. It must be one of the supported Azure locations." + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "minLength": 1, + "maxLength": 90 + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Name of the deployment stack." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/DeploymentStackProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Deployment stack properties." + }, + "tags": { + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "properties": {} + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Deployment stack resource tags." + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Resources/deploymentStacks" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Resources/deploymentStacks" + } + }, + "subscription_resourceDefinitions": { + "deploymentStacks": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-08-01-preview" + ] + }, + "location": { + "type": "string", + "description": "The location of the deployment stack. It cannot be changed after creation. It must be one of the supported Azure locations." + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "minLength": 1, + "maxLength": 90 + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Name of the deployment stack." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/DeploymentStackProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Deployment stack properties." + }, + "tags": { + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "properties": {} + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Deployment stack resource tags." + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Resources/deploymentStacks" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Resources/deploymentStacks" + }, + "resourceGroups": { + "type": "object", + "properties": { + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "maxLength": 90, + "description": "the resource group name" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Resources/resourceGroups" + ] + }, + "apiVersion": { + "type": "string", + "enum": [ + "2022-08-01-preview" + ] + }, + "location": { + "type": "string", + "description": "the resource group location" + }, + "tags": { + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The resource group tags." + } + }, + "required": [ + "name", + "type", + "apiVersion", + "location" + ], + "description": "Microsoft.Resources/resourceGroups" + } + }, + "managementGroup_resourceDefinitions": { + "deploymentStacks": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-08-01-preview" + ] + }, + "location": { + "type": "string", + "description": "The location of the deployment stack. It cannot be changed after creation. It must be one of the supported Azure locations." + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "minLength": 1, + "maxLength": 90 + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Name of the deployment stack." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/DeploymentStackProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Deployment stack properties." + }, + "tags": { + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "properties": {} + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Deployment stack resource tags." + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Resources/deploymentStacks" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Resources/deploymentStacks" + } + }, + "definitions": { + "DenySettings": { + "type": "object", + "properties": { + "applyToChildScopes": { + "oneOf": [ + { + "type": "boolean" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "DenySettings will be applied to child scopes." + }, + "excludedActions": { + "oneOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "List of role-based management operations that are excluded from the denySettings. Up to 200 actions are permitted. If the denySetting mode is set to 'denyWriteAndDelete', then the following actions are automatically appended to 'excludedActions': '*/read' and 'Microsoft.Authorization/locks/delete'. If the denySetting mode is set to 'denyDelete', then the following actions are automatically appended to 'excludedActions': 'Microsoft.Authorization/locks/delete'. Duplicate actions will be removed." + }, + "excludedPrincipals": { + "oneOf": [ + { + "type": "array", + "items": { + "type": "string" + } + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "List of AAD principal IDs excluded from the lock. Up to 5 principals are permitted." + }, + "mode": { + "oneOf": [ + { + "type": "string", + "enum": [ + "denyDelete", + "denyWriteAndDelete", + "none" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "denySettings Mode." + } + }, + "description": "Defines how resources deployed by the deployment stack are locked." + }, + "DeploymentStackProperties": { + "type": "object", + "properties": { + "actionOnUnmanage": { + "oneOf": [ + { + "$ref": "#/definitions/DeploymentStackPropertiesActionOnUnmanage" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Defines the behavior of resources that are not managed immediately after the stack is updated." + }, + "debugSetting": { + "oneOf": [ + { + "$ref": "#/definitions/DeploymentStacksDebugSetting" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The debug setting." + }, + "denySettings": { + "oneOf": [ + { + "$ref": "#/definitions/DenySettings" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Defines how resources deployed by the deployment stack are locked." + }, + "deploymentScope": { + "type": "string", + "description": "The scope at which the initial deployment should be created. If a scope is not specified, it will default to the scope of the deployment stack. Valid scopes are: management group (format: '/providers/Microsoft.Management/managementGroups/{managementGroupId}'), subscription (format: '/subscriptions/{subscriptionId}'), resource group (format: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}')." + }, + "description": { + "type": "string", + "maxLength": 4096, + "description": "Deployment stack description." + }, + "error": { + "oneOf": [ + { + "$ref": "#/definitions/ErrorResponse" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.)." + }, + "parameters": { + "type": "object", + "properties": {}, + "description": "Name and value pairs that define the deployment parameters for the template. Use this element when providing the parameter values directly in the request, rather than linking to an existing parameter file. Use either the parametersLink property or the parameters property, but not both. It can be a JObject or a well formed JSON string." + }, + "parametersLink": { + "oneOf": [ + { + "$ref": "#/definitions/DeploymentStacksParametersLink" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Entity representing the reference to the deployment parameters." + }, + "template": { + "type": "object", + "properties": {}, + "description": "The template content. You use this element when you want to pass the template syntax directly in the request rather than link to an existing template. It can be a JObject or well-formed JSON string. Use either the templateLink property or the template property, but not both." + }, + "templateLink": { + "oneOf": [ + { + "$ref": "#/definitions/DeploymentStacksTemplateLink" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Entity representing the reference to the template." + } + }, + "required": [ + "actionOnUnmanage" + ], + "description": "Deployment stack properties." + }, + "DeploymentStackPropertiesActionOnUnmanage": { + "type": "object", + "properties": { + "managementGroups": { + "oneOf": [ + { + "type": "string", + "enum": [ + "delete", + "detach" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ] + }, + "resourceGroups": { + "oneOf": [ + { + "type": "string", + "enum": [ + "delete", + "detach" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ] + }, + "resources": { + "oneOf": [ + { + "type": "string", + "enum": [ + "delete", + "detach" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ] + } + }, + "required": [ + "resources" + ], + "description": "Defines the behavior of resources that are not managed immediately after the stack is updated." + }, + "DeploymentStacksDebugSetting": { + "type": "object", + "properties": { + "detailLevel": { + "type": "string", + "description": "Specifies the type of information to log for debugging. The permitted values are none, requestContent, responseContent, or both requestContent and responseContent separated by a comma. The default is none. When setting this value, carefully consider the type of information that is being passed in during deployment. By logging information about the request or response, sensitive data that is retrieved through the deployment operations could potentially be exposed." + } + }, + "description": "The debug setting." + }, + "DeploymentStacksParametersLink": { + "type": "object", + "properties": { + "contentVersion": { + "type": "string", + "description": "If included, must match the ContentVersion in the template." + }, + "uri": { + "type": "string", + "description": "The URI of the parameters file." + } + }, + "required": [ + "uri" + ], + "description": "Entity representing the reference to the deployment parameters." + }, + "DeploymentStacksTemplateLink": { + "type": "object", + "properties": { + "contentVersion": { + "type": "string", + "description": "If included, must match the ContentVersion in the template." + }, + "id": { + "type": "string", + "description": "The resource id of a Template Spec. Use either the id or uri property, but not both." + }, + "queryString": { + "type": "string", + "description": "The query string (for example, a SAS token) to be used with the templateLink URI." + }, + "relativePath": { + "type": "string", + "description": "The relativePath property can be used to deploy a linked template at a location relative to the parent. If the parent template was linked with a TemplateSpec, this will reference an artifact in the TemplateSpec. If the parent was linked with a URI, the child deployment will be a combination of the parent and relativePath URIs" + }, + "uri": { + "type": "string", + "description": "The URI of the template to deploy. Use either the uri or id property, but not both." + } + }, + "description": "Entity representing the reference to the template." + }, + "ErrorDetail": { + "type": "object", + "properties": {}, + "description": "The error detail." + }, + "ErrorResponse": { + "type": "object", + "properties": { + "error": { + "oneOf": [ + { + "$ref": "#/definitions/ErrorDetail" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The error detail." + } + }, + "description": "Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.)." + } + } +} \ No newline at end of file diff --git a/schemas/common/autogeneratedResources.json b/schemas/common/autogeneratedResources.json index 7159adef3e..27b3ee4b00 100644 --- a/schemas/common/autogeneratedResources.json +++ b/schemas/common/autogeneratedResources.json @@ -26155,6 +26155,9 @@ { "$ref": "https://schema.management.azure.com/schemas/2022-02-01/Microsoft.Resources.json#/resourceDefinitions/templateSpecs_versions" }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-08-01-preview/Microsoft.Resources.json#/resourceDefinitions/deploymentStacks" + }, { "$ref": "https://schema.management.azure.com/schemas/2022-09-01/Microsoft.Resources.json#/resourceDefinitions/deployments" },