Skip to content

Commit b664590

Browse files
SDKAutoOchi
andcommitted
CodeGen from PR 16687 in Azure/azure-rest-api-specs
A new API version 2021-10-01 on MS.Subscription (#16687) * Copied the last item from private repo and renamed to 2021-10-01 * Updated the version to 2021-10-01 * Error response is updated. It is required by OpenAPI Validation Tools(linter) * http status response on post method is updated to 201 from 202; required by OpenAPI Validation Tools(linter) * description is added in #definitions.Operation.properties.display; required by OpenAPI Validation Tools(linter) * updated error response to match it previous * systemData properties are added; required by Swagger validation on the PR * updated readme.md for the new version * removed a file getSubscriptionOperation.json as long as it is not referenced; required by Swagger Avocado on the PR * Modified style by npm prettier * executed npm run prettier; required by prettier check on PR * added type:object; required by swagger LintDiff * added type:object; required by swagger LintDiff * reverted back the post response of acceptOwnership to 202 * http status response on post method is updated to 201 from 202; required by OpenAPI Validation Tools(linter) * reverted back the post response of acceptOwnership to 202 Co-authored-by: Ochi <[email protected]>
1 parent 2d92207 commit b664590

File tree

2 files changed

+202
-0
lines changed

2 files changed

+202
-0
lines changed

schemas/2019-08-01/tenantDeploymentTemplate.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -784,6 +784,12 @@
784784
{
785785
"$ref": "https://schema.management.azure.com/schemas/2020-09-01/Microsoft.Subscription.json#/tenant_resourceDefinitions/aliases"
786786
},
787+
{
788+
"$ref": "https://schema.management.azure.com/schemas/2021-10-01/Microsoft.Subscription.json#/tenant_resourceDefinitions/aliases"
789+
},
790+
{
791+
"$ref": "https://schema.management.azure.com/schemas/2021-10-01/Microsoft.Subscription.json#/tenant_resourceDefinitions/policies"
792+
},
787793
{
788794
"$ref": "https://schema.management.azure.com/schemas/2015-08-01/Microsoft.Web.json#/tenant_resourceDefinitions/publishingUsers"
789795
},
Lines changed: 196 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,196 @@
1+
{
2+
"id": "https://schema.management.azure.com/schemas/2021-10-01/Microsoft.Subscription.json#",
3+
"$schema": "http://json-schema.org/draft-04/schema#",
4+
"title": "Microsoft.Subscription",
5+
"description": "Microsoft Subscription Resource Types",
6+
"resourceDefinitions": {},
7+
"tenant_resourceDefinitions": {
8+
"aliases": {
9+
"type": "object",
10+
"properties": {
11+
"apiVersion": {
12+
"type": "string",
13+
"enum": [
14+
"2021-10-01"
15+
]
16+
},
17+
"name": {
18+
"type": "string",
19+
"description": "AliasName is the name for the subscription creation request. Note that this is not the same as subscription name and this doesn’t have any other lifecycle need beyond the request for subscription creation."
20+
},
21+
"properties": {
22+
"oneOf": [
23+
{
24+
"$ref": "#/definitions/PutAliasRequestProperties"
25+
},
26+
{
27+
"$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
28+
}
29+
],
30+
"description": "Put subscription properties."
31+
},
32+
"type": {
33+
"type": "string",
34+
"enum": [
35+
"Microsoft.Subscription/aliases"
36+
]
37+
}
38+
},
39+
"required": [
40+
"apiVersion",
41+
"name",
42+
"properties",
43+
"type"
44+
],
45+
"description": "Microsoft.Subscription/aliases"
46+
},
47+
"policies": {
48+
"type": "object",
49+
"properties": {
50+
"apiVersion": {
51+
"type": "string",
52+
"enum": [
53+
"2021-10-01"
54+
]
55+
},
56+
"blockSubscriptionsIntoTenant": {
57+
"oneOf": [
58+
{
59+
"type": "boolean"
60+
},
61+
{
62+
"$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
63+
}
64+
],
65+
"description": "Blocks the entering of subscriptions into user's tenant."
66+
},
67+
"blockSubscriptionsLeavingTenant": {
68+
"oneOf": [
69+
{
70+
"type": "boolean"
71+
},
72+
{
73+
"$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
74+
}
75+
],
76+
"description": "Blocks the leaving of subscriptions from user's tenant."
77+
},
78+
"exemptedPrincipals": {
79+
"oneOf": [
80+
{
81+
"type": "array",
82+
"items": {
83+
"type": "string",
84+
"pattern": "^[0-9a-fA-F]{8}(-[0-9a-fA-F]{4}){3}-[0-9a-fA-F]{12}$"
85+
}
86+
},
87+
{
88+
"$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
89+
}
90+
],
91+
"description": "List of user objectIds that are exempted from the set subscription tenant policies for the user's tenant."
92+
},
93+
"name": {
94+
"type": "string",
95+
"enum": [
96+
"default"
97+
]
98+
},
99+
"type": {
100+
"type": "string",
101+
"enum": [
102+
"Microsoft.Subscription/policies"
103+
]
104+
}
105+
},
106+
"required": [
107+
"apiVersion",
108+
"name",
109+
"type"
110+
],
111+
"description": "Microsoft.Subscription/policies"
112+
}
113+
},
114+
"definitions": {
115+
"PutAliasRequestAdditionalProperties": {
116+
"type": "object",
117+
"properties": {
118+
"managementGroupId": {
119+
"type": "string",
120+
"description": "Management group Id for the subscription."
121+
},
122+
"subscriptionOwnerId": {
123+
"type": "string",
124+
"description": "Owner Id of the subscription"
125+
},
126+
"subscriptionTenantId": {
127+
"type": "string",
128+
"description": "Tenant Id of the subscription"
129+
},
130+
"tags": {
131+
"oneOf": [
132+
{
133+
"type": "object",
134+
"additionalProperties": {
135+
"type": "string"
136+
},
137+
"properties": {}
138+
},
139+
{
140+
"$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
141+
}
142+
],
143+
"description": "Tags for the subscription"
144+
}
145+
},
146+
"description": "Put subscription additional properties."
147+
},
148+
"PutAliasRequestProperties": {
149+
"type": "object",
150+
"properties": {
151+
"additionalProperties": {
152+
"oneOf": [
153+
{
154+
"$ref": "#/definitions/PutAliasRequestAdditionalProperties"
155+
},
156+
{
157+
"$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
158+
}
159+
],
160+
"description": "Put subscription additional properties."
161+
},
162+
"billingScope": {
163+
"type": "string",
164+
"description": "Billing scope of the subscription.\nFor CustomerLed and FieldLed - /billingAccounts/{billingAccountName}/billingProfiles/{billingProfileName}/invoiceSections/{invoiceSectionName}\nFor PartnerLed - /billingAccounts/{billingAccountName}/customers/{customerName}\nFor Legacy EA - /billingAccounts/{billingAccountName}/enrollmentAccounts/{enrollmentAccountName}"
165+
},
166+
"displayName": {
167+
"type": "string",
168+
"description": "The friendly name of the subscription."
169+
},
170+
"resellerId": {
171+
"type": "string",
172+
"description": "Reseller Id"
173+
},
174+
"subscriptionId": {
175+
"type": "string",
176+
"description": "This parameter can be used to create alias for existing subscription Id"
177+
},
178+
"workload": {
179+
"oneOf": [
180+
{
181+
"type": "string",
182+
"enum": [
183+
"Production",
184+
"DevTest"
185+
]
186+
},
187+
{
188+
"$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
189+
}
190+
]
191+
}
192+
},
193+
"description": "Put subscription properties."
194+
}
195+
}
196+
}

0 commit comments

Comments
 (0)