1
+ {
2
+ "id" : " https://schema.management.azure.com/schemas/2021-07-22-preview/Microsoft.AlertsManagement.json#" ,
3
+ "$schema" : " http://json-schema.org/draft-04/schema#" ,
4
+ "title" : " Microsoft.AlertsManagement" ,
5
+ "description" : " Microsoft AlertsManagement Resource Types" ,
6
+ "resourceDefinitions" : {
7
+ "prometheusRuleGroups" : {
8
+ "type" : " object" ,
9
+ "properties" : {
10
+ "apiVersion" : {
11
+ "type" : " string" ,
12
+ "enum" : [
13
+ " 2021-07-22-preview"
14
+ ]
15
+ },
16
+ "location" : {
17
+ "type" : " string" ,
18
+ "description" : " The geo-location where the resource lives"
19
+ },
20
+ "name" : {
21
+ "type" : " string" ,
22
+ "description" : " The name of the rule group."
23
+ },
24
+ "properties" : {
25
+ "oneOf" : [
26
+ {
27
+ "$ref" : " #/definitions/PrometheusRuleGroupProperties"
28
+ },
29
+ {
30
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
31
+ }
32
+ ],
33
+ "description" : " An alert rule."
34
+ },
35
+ "tags" : {
36
+ "oneOf" : [
37
+ {
38
+ "type" : " object" ,
39
+ "additionalProperties" : {
40
+ "type" : " string"
41
+ },
42
+ "properties" : {}
43
+ },
44
+ {
45
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
46
+ }
47
+ ],
48
+ "description" : " Resource tags."
49
+ },
50
+ "type" : {
51
+ "type" : " string" ,
52
+ "enum" : [
53
+ " Microsoft.AlertsManagement/prometheusRuleGroups"
54
+ ]
55
+ }
56
+ },
57
+ "required" : [
58
+ " apiVersion" ,
59
+ " location" ,
60
+ " name" ,
61
+ " properties" ,
62
+ " type"
63
+ ],
64
+ "description" : " Microsoft.AlertsManagement/prometheusRuleGroups"
65
+ }
66
+ },
67
+ "definitions" : {
68
+ "PrometheusRule" : {
69
+ "type" : " object" ,
70
+ "properties" : {
71
+ "actions" : {
72
+ "oneOf" : [
73
+ {
74
+ "type" : " array" ,
75
+ "items" : {
76
+ "$ref" : " #/definitions/PrometheusRuleGroupAction"
77
+ }
78
+ },
79
+ {
80
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
81
+ }
82
+ ],
83
+ "description" : " The array of actions that are performed when the alert rule becomes active, and when an alert condition is resolved. Only relevant for alerts."
84
+ },
85
+ "alert" : {
86
+ "type" : " string" ,
87
+ "description" : " the name of the alert rule."
88
+ },
89
+ "annotations" : {
90
+ "oneOf" : [
91
+ {
92
+ "type" : " object" ,
93
+ "additionalProperties" : {
94
+ "type" : " string"
95
+ },
96
+ "properties" : {}
97
+ },
98
+ {
99
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
100
+ }
101
+ ],
102
+ "description" : " annotations for rule group. Only relevant for alerts."
103
+ },
104
+ "enabled" : {
105
+ "oneOf" : [
106
+ {
107
+ "type" : " boolean"
108
+ },
109
+ {
110
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
111
+ }
112
+ ],
113
+ "description" : " the flag that indicates whether the Prometheus rule is enabled."
114
+ },
115
+ "expression" : {
116
+ "type" : " string" ,
117
+ "description" : " the expression to run for the rule."
118
+ },
119
+ "for" : {
120
+ "type" : " string" ,
121
+ "description" : " the amount of time alert must be active before firing. Only relevant for alerts."
122
+ },
123
+ "labels" : {
124
+ "oneOf" : [
125
+ {
126
+ "type" : " object" ,
127
+ "additionalProperties" : {
128
+ "type" : " string"
129
+ },
130
+ "properties" : {}
131
+ },
132
+ {
133
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
134
+ }
135
+ ],
136
+ "description" : " labels for rule group. Only relevant for alerts."
137
+ },
138
+ "record" : {
139
+ "type" : " string" ,
140
+ "description" : " the name of the recording rule."
141
+ },
142
+ "resolveConfiguration" : {
143
+ "oneOf" : [
144
+ {
145
+ "$ref" : " #/definitions/PrometheusRuleResolveConfiguration"
146
+ },
147
+ {
148
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
149
+ }
150
+ ],
151
+ "description" : " Specifies the Prometheus alert rule configuration."
152
+ },
153
+ "severity" : {
154
+ "oneOf" : [
155
+ {
156
+ "type" : " integer"
157
+ },
158
+ {
159
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
160
+ }
161
+ ],
162
+ "description" : " the severity of the alerts fired by the rule. Only relevant for alerts."
163
+ }
164
+ },
165
+ "required" : [
166
+ " expression"
167
+ ]
168
+ },
169
+ "PrometheusRuleGroupAction" : {
170
+ "type" : " object" ,
171
+ "properties" : {
172
+ "actionGroupId" : {
173
+ "type" : " string" ,
174
+ "description" : " The resource id of the action group to use."
175
+ },
176
+ "actionProperties" : {
177
+ "oneOf" : [
178
+ {
179
+ "type" : " object" ,
180
+ "additionalProperties" : {
181
+ "type" : " string"
182
+ },
183
+ "properties" : {}
184
+ },
185
+ {
186
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
187
+ }
188
+ ],
189
+ "description" : " The properties of an action group object."
190
+ }
191
+ },
192
+ "description" : " An alert action. Only relevant for alerts."
193
+ },
194
+ "PrometheusRuleGroupProperties" : {
195
+ "type" : " object" ,
196
+ "properties" : {
197
+ "clusterName" : {
198
+ "type" : " string" ,
199
+ "description" : " the cluster name of the rule group evaluation."
200
+ },
201
+ "description" : {
202
+ "type" : " string" ,
203
+ "description" : " the description of the Prometheus rule group that will be included in the alert email."
204
+ },
205
+ "enabled" : {
206
+ "oneOf" : [
207
+ {
208
+ "type" : " boolean"
209
+ },
210
+ {
211
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
212
+ }
213
+ ],
214
+ "description" : " the flag that indicates whether the Prometheus rule group is enabled."
215
+ },
216
+ "interval" : {
217
+ "type" : " string" ,
218
+ "description" : " the interval in which to run the Prometheus rule group represented in ISO 8601 duration format. Should be between 1 and 15 minutes"
219
+ },
220
+ "rules" : {
221
+ "oneOf" : [
222
+ {
223
+ "type" : " array" ,
224
+ "items" : {
225
+ "$ref" : " #/definitions/PrometheusRule"
226
+ }
227
+ },
228
+ {
229
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
230
+ }
231
+ ],
232
+ "description" : " defines the rules in the Prometheus rule group."
233
+ },
234
+ "scopes" : {
235
+ "oneOf" : [
236
+ {
237
+ "type" : " array" ,
238
+ "items" : {
239
+ "type" : " string"
240
+ }
241
+ },
242
+ {
243
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
244
+ }
245
+ ],
246
+ "description" : " the list of resource id's that this rule group is scoped to."
247
+ }
248
+ },
249
+ "required" : [
250
+ " rules" ,
251
+ " scopes"
252
+ ],
253
+ "description" : " An alert rule."
254
+ },
255
+ "PrometheusRuleResolveConfiguration" : {
256
+ "type" : " object" ,
257
+ "properties" : {
258
+ "autoResolved" : {
259
+ "oneOf" : [
260
+ {
261
+ "type" : " boolean"
262
+ },
263
+ {
264
+ "$ref" : " https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression"
265
+ }
266
+ ],
267
+ "description" : " the flag that indicates whether or not to auto resolve a fired alert."
268
+ },
269
+ "timeToResolve" : {
270
+ "type" : " string" ,
271
+ "description" : " the duration a rule must evaluate as healthy before the fired alert is automatically resolved represented in ISO 8601 duration format. Should be between 1 and 15 minutes"
272
+ }
273
+ },
274
+ "description" : " Specifies the Prometheus alert rule configuration."
275
+ }
276
+ }
277
+ }
0 commit comments