From 18cf9cf02112893a9477a451d69a3fd74c46818b Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Tue, 13 Apr 2021 00:51:46 +0000 Subject: [PATCH] CodeGen from PR 13897 in Azure/azure-rest-api-specs Merge 5a1cfbe01a01840502b126eee6e0cb5c7cc961ef into b3577207350270e9ae3b3e22c91b1730c602f276 --- .../2019-08-01/tenantDeploymentTemplate.json | 18 ++ schemas/2020-10-01/Microsoft.Management.json | 273 ++++++++++++++++++ schemas/2021-04-01/Microsoft.Management.json | 273 ++++++++++++++++++ 3 files changed, 564 insertions(+) create mode 100644 schemas/2020-10-01/Microsoft.Management.json create mode 100644 schemas/2021-04-01/Microsoft.Management.json diff --git a/schemas/2019-08-01/tenantDeploymentTemplate.json b/schemas/2019-08-01/tenantDeploymentTemplate.json index 7cb34f7628..2ce7581765 100644 --- a/schemas/2019-08-01/tenantDeploymentTemplate.json +++ b/schemas/2019-08-01/tenantDeploymentTemplate.json @@ -227,6 +227,24 @@ { "$ref": "https://schema.management.azure.com/schemas/2020-05-01/Microsoft.Management.json#/tenant_resourceDefinitions/managementGroups_subscriptions" }, + { + "$ref": "https://schema.management.azure.com/schemas/2020-10-01/Microsoft.Management.json#/tenant_resourceDefinitions/managementGroups" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2020-10-01/Microsoft.Management.json#/tenant_resourceDefinitions/managementGroups_settings" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2020-10-01/Microsoft.Management.json#/tenant_resourceDefinitions/managementGroups_subscriptions" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2021-04-01/Microsoft.Management.json#/tenant_resourceDefinitions/managementGroups" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2021-04-01/Microsoft.Management.json#/tenant_resourceDefinitions/managementGroups_settings" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2021-04-01/Microsoft.Management.json#/tenant_resourceDefinitions/managementGroups_subscriptions" + }, { "$ref": "https://schema.management.azure.com/schemas/2018-02-01/Microsoft.ManagementPartner.json#/tenant_resourceDefinitions/partners" }, diff --git a/schemas/2020-10-01/Microsoft.Management.json b/schemas/2020-10-01/Microsoft.Management.json new file mode 100644 index 0000000000..29ac2c0139 --- /dev/null +++ b/schemas/2020-10-01/Microsoft.Management.json @@ -0,0 +1,273 @@ +{ + "id": "https://schema.management.azure.com/schemas/2020-10-01/Microsoft.Management.json#", + "$schema": "http://json-schema.org/draft-04/schema#", + "title": "Microsoft.Management", + "description": "Microsoft Management Resource Types", + "resourceDefinitions": {}, + "tenant_resourceDefinitions": { + "managementGroups": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2020-10-01" + ] + }, + "name": { + "type": "string", + "description": "Management Group ID." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/CreateManagementGroupProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The generic properties of a management group used during creation." + }, + "resources": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/managementGroups_subscriptions_childResource" + }, + { + "$ref": "#/definitions/managementGroups_settings_childResource" + } + ] + } + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Management/managementGroups" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Management/managementGroups" + }, + "managementGroups_settings": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2020-10-01" + ] + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^.*/default$" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ] + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/CreateOrUpdateSettingsProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The properties of the request to create or update Management Group settings" + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Management/managementGroups/settings" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Management/managementGroups/settings" + }, + "managementGroups_subscriptions": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2020-10-01" + ] + }, + "name": { + "type": "string", + "description": "Subscription ID." + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Management/managementGroups/subscriptions" + ] + } + }, + "required": [ + "apiVersion", + "name", + "type" + ], + "description": "Microsoft.Management/managementGroups/subscriptions" + } + }, + "definitions": { + "CreateManagementGroupDetails": { + "type": "object", + "properties": { + "parent": { + "oneOf": [ + { + "$ref": "#/definitions/CreateParentGroupInfo" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "(Optional) The ID of the parent management group used during creation." + } + }, + "description": "The details of a management group used during creation." + }, + "CreateManagementGroupProperties": { + "type": "object", + "properties": { + "details": { + "oneOf": [ + { + "$ref": "#/definitions/CreateManagementGroupDetails" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The details of a management group used during creation." + }, + "displayName": { + "type": "string", + "description": "The friendly name of the management group. If no value is passed then this field will be set to the groupId." + } + }, + "description": "The generic properties of a management group used during creation." + }, + "CreateOrUpdateSettingsProperties": { + "type": "object", + "properties": { + "defaultManagementGroup": { + "type": "string", + "description": "Settings that sets the default Management Group under which new subscriptions get added in this tenant. For example, /providers/Microsoft.Management/managementGroups/defaultGroup" + }, + "requireAuthorizationForGroupCreation": { + "oneOf": [ + { + "type": "boolean" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Indicates whether RBAC access is required upon group creation under the root Management Group. If set to true, user will require Microsoft.Management/managementGroups/write action on the root Management Group scope in order to create new Groups directly under the root. This will prevent new users from creating new Management Groups, unless they are given access." + } + }, + "description": "The properties of the request to create or update Management Group settings" + }, + "CreateParentGroupInfo": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The fully qualified ID for the parent management group. For example, /providers/Microsoft.Management/managementGroups/0000000-0000-0000-0000-000000000000" + } + }, + "description": "(Optional) The ID of the parent management group used during creation." + }, + "managementGroups_settings_childResource": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2020-10-01" + ] + }, + "name": { + "type": "string", + "enum": [ + "default" + ] + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/CreateOrUpdateSettingsProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The properties of the request to create or update Management Group settings" + }, + "type": { + "type": "string", + "enum": [ + "settings" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Management/managementGroups/settings" + }, + "managementGroups_subscriptions_childResource": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2020-10-01" + ] + }, + "name": { + "type": "string", + "description": "Subscription ID." + }, + "type": { + "type": "string", + "enum": [ + "subscriptions" + ] + } + }, + "required": [ + "apiVersion", + "name", + "type" + ], + "description": "Microsoft.Management/managementGroups/subscriptions" + } + } +} \ No newline at end of file diff --git a/schemas/2021-04-01/Microsoft.Management.json b/schemas/2021-04-01/Microsoft.Management.json new file mode 100644 index 0000000000..292a5c5aca --- /dev/null +++ b/schemas/2021-04-01/Microsoft.Management.json @@ -0,0 +1,273 @@ +{ + "id": "https://schema.management.azure.com/schemas/2021-04-01/Microsoft.Management.json#", + "$schema": "http://json-schema.org/draft-04/schema#", + "title": "Microsoft.Management", + "description": "Microsoft Management Resource Types", + "resourceDefinitions": {}, + "tenant_resourceDefinitions": { + "managementGroups": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2021-04-01" + ] + }, + "name": { + "type": "string", + "description": "Management Group ID." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/CreateManagementGroupProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The generic properties of a management group used during creation." + }, + "resources": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/managementGroups_subscriptions_childResource" + }, + { + "$ref": "#/definitions/managementGroups_settings_childResource" + } + ] + } + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Management/managementGroups" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Management/managementGroups" + }, + "managementGroups_settings": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2021-04-01" + ] + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^.*/default$" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ] + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/CreateOrUpdateSettingsProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The properties of the request to create or update Management Group settings" + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Management/managementGroups/settings" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Management/managementGroups/settings" + }, + "managementGroups_subscriptions": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2021-04-01" + ] + }, + "name": { + "type": "string", + "description": "Subscription ID." + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Management/managementGroups/subscriptions" + ] + } + }, + "required": [ + "apiVersion", + "name", + "type" + ], + "description": "Microsoft.Management/managementGroups/subscriptions" + } + }, + "definitions": { + "CreateManagementGroupDetails": { + "type": "object", + "properties": { + "parent": { + "oneOf": [ + { + "$ref": "#/definitions/CreateParentGroupInfo" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "(Optional) The ID of the parent management group used during creation." + } + }, + "description": "The details of a management group used during creation." + }, + "CreateManagementGroupProperties": { + "type": "object", + "properties": { + "details": { + "oneOf": [ + { + "$ref": "#/definitions/CreateManagementGroupDetails" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The details of a management group used during creation." + }, + "displayName": { + "type": "string", + "description": "The friendly name of the management group. If no value is passed then this field will be set to the groupId." + } + }, + "description": "The generic properties of a management group used during creation." + }, + "CreateOrUpdateSettingsProperties": { + "type": "object", + "properties": { + "defaultManagementGroup": { + "type": "string", + "description": "Settings that sets the default Management Group under which new subscriptions get added in this tenant. For example, /providers/Microsoft.Management/managementGroups/defaultGroup" + }, + "requireAuthorizationForGroupCreation": { + "oneOf": [ + { + "type": "boolean" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Indicates whether RBAC access is required upon group creation under the root Management Group. If set to true, user will require Microsoft.Management/managementGroups/write action on the root Management Group scope in order to create new Groups directly under the root. This will prevent new users from creating new Management Groups, unless they are given access." + } + }, + "description": "The properties of the request to create or update Management Group settings" + }, + "CreateParentGroupInfo": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The fully qualified ID for the parent management group. For example, /providers/Microsoft.Management/managementGroups/0000000-0000-0000-0000-000000000000" + } + }, + "description": "(Optional) The ID of the parent management group used during creation." + }, + "managementGroups_settings_childResource": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2021-04-01" + ] + }, + "name": { + "type": "string", + "enum": [ + "default" + ] + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/CreateOrUpdateSettingsProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The properties of the request to create or update Management Group settings" + }, + "type": { + "type": "string", + "enum": [ + "settings" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.Management/managementGroups/settings" + }, + "managementGroups_subscriptions_childResource": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2021-04-01" + ] + }, + "name": { + "type": "string", + "description": "Subscription ID." + }, + "type": { + "type": "string", + "enum": [ + "subscriptions" + ] + } + }, + "required": [ + "apiVersion", + "name", + "type" + ], + "description": "Microsoft.Management/managementGroups/subscriptions" + } + } +} \ No newline at end of file