Skip to content

Commit e52b8f1

Browse files
chore: update alerting swagger spec
1 parent ae9460b commit e52b8f1

File tree

3 files changed

+57
-40
lines changed

3 files changed

+57
-40
lines changed

pkg/services/ngalert/api/tooling/api.json

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,9 @@
165165
},
166166
"AlertRuleEditorSettings": {
167167
"properties": {
168+
"simplified_notifications_section": {
169+
"type": "boolean"
170+
},
168171
"simplified_query_and_expressions_section": {
169172
"type": "boolean"
170173
}
@@ -755,7 +758,7 @@
755758
"type": "string"
756759
},
757760
"ErrorSource": {
758-
"$ref": "#/definitions/ErrorSource"
761+
"$ref": "#/definitions/Source"
759762
},
760763
"Frames": {
761764
"$ref": "#/definitions/Frames"
@@ -965,10 +968,6 @@
965968
},
966969
"type": "object"
967970
},
968-
"ErrorSource": {
969-
"description": "ErrorSource type defines the source of the error",
970-
"type": "string"
971-
},
972971
"ErrorType": {
973972
"title": "ErrorType models the different API error types.",
974973
"type": "string"
@@ -3606,6 +3605,9 @@
36063605
},
36073606
"RuleDiscovery": {
36083607
"properties": {
3608+
"groupNextToken": {
3609+
"type": "string"
3610+
},
36093611
"groups": {
36103612
"items": {
36113613
"$ref": "#/definitions/RuleGroup"
@@ -3975,6 +3977,10 @@
39753977
"SmtpNotEnabled": {
39763978
"$ref": "#/definitions/ResponseDetails"
39773979
},
3980+
"Source": {
3981+
"title": "Source type defines the status source.",
3982+
"type": "string"
3983+
},
39783984
"Span": {
39793985
"properties": {
39803986
"Length": {
@@ -4803,6 +4809,7 @@
48034809
"type": "object"
48044810
},
48054811
"gettableAlerts": {
4812+
"description": "GettableAlerts gettable alerts",
48064813
"items": {
48074814
"$ref": "#/definitions/gettableAlert",
48084815
"type": "object"
@@ -6240,7 +6247,7 @@
62406247
}
62416248
}
62426249
},
6243-
"summary": "Get all notification templates.",
6250+
"summary": "Get all notification template groups.",
62446251
"tags": [
62456252
"provisioning"
62466253
]
@@ -6251,7 +6258,7 @@
62516258
"operationId": "RouteDeleteTemplate",
62526259
"parameters": [
62536260
{
6254-
"description": "Template name",
6261+
"description": "Template group name",
62556262
"in": "path",
62566263
"name": "name",
62576264
"required": true,
@@ -6275,7 +6282,7 @@
62756282
}
62766283
}
62776284
},
6278-
"summary": "Delete a template.",
6285+
"summary": "Delete a notification template group.",
62796286
"tags": [
62806287
"provisioning"
62816288
]
@@ -6284,7 +6291,7 @@
62846291
"operationId": "RouteGetTemplate",
62856292
"parameters": [
62866293
{
6287-
"description": "Template Name",
6294+
"description": "Template group name",
62886295
"in": "path",
62896296
"name": "name",
62906297
"required": true,
@@ -6305,7 +6312,7 @@
63056312
}
63066313
}
63076314
},
6308-
"summary": "Get a notification template.",
6315+
"summary": "Get a notification template group.",
63096316
"tags": [
63106317
"provisioning"
63116318
]
@@ -6317,7 +6324,7 @@
63176324
"operationId": "RoutePutTemplate",
63186325
"parameters": [
63196326
{
6320-
"description": "Template Name",
6327+
"description": "Template group name",
63216328
"in": "path",
63226329
"name": "name",
63236330
"required": true,
@@ -6356,7 +6363,7 @@
63566363
}
63576364
}
63586365
},
6359-
"summary": "Updates an existing notification template.",
6366+
"summary": "Updates an existing notification template group.",
63606367
"tags": [
63616368
"provisioning"
63626369
]

pkg/services/ngalert/api/tooling/post.json

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,9 @@
165165
},
166166
"AlertRuleEditorSettings": {
167167
"properties": {
168+
"simplified_notifications_section": {
169+
"type": "boolean"
170+
},
168171
"simplified_query_and_expressions_section": {
169172
"type": "boolean"
170173
}
@@ -755,7 +758,7 @@
755758
"type": "string"
756759
},
757760
"ErrorSource": {
758-
"$ref": "#/definitions/ErrorSource"
761+
"$ref": "#/definitions/Source"
759762
},
760763
"Frames": {
761764
"$ref": "#/definitions/Frames"
@@ -965,10 +968,6 @@
965968
},
966969
"type": "object"
967970
},
968-
"ErrorSource": {
969-
"description": "ErrorSource type defines the source of the error",
970-
"type": "string"
971-
},
972971
"ErrorType": {
973972
"title": "ErrorType models the different API error types.",
974973
"type": "string"
@@ -3606,6 +3605,9 @@
36063605
},
36073606
"RuleDiscovery": {
36083607
"properties": {
3608+
"groupNextToken": {
3609+
"type": "string"
3610+
},
36093611
"groups": {
36103612
"items": {
36113613
"$ref": "#/definitions/RuleGroup"
@@ -3975,6 +3977,10 @@
39753977
"SmtpNotEnabled": {
39763978
"$ref": "#/definitions/ResponseDetails"
39773979
},
3980+
"Source": {
3981+
"title": "Source type defines the status source.",
3982+
"type": "string"
3983+
},
39783984
"Span": {
39793985
"properties": {
39803986
"Length": {
@@ -4641,6 +4647,7 @@
46414647
"type": "object"
46424648
},
46434649
"alertGroups": {
4650+
"description": "AlertGroups alert groups",
46444651
"items": {
46454652
"$ref": "#/definitions/alertGroup",
46464653
"type": "object"
@@ -4802,7 +4809,6 @@
48024809
"type": "object"
48034810
},
48044811
"gettableAlerts": {
4805-
"description": "GettableAlerts gettable alerts",
48064812
"items": {
48074813
"$ref": "#/definitions/gettableAlert",
48084814
"type": "object"
@@ -4927,7 +4933,6 @@
49274933
"type": "object"
49284934
},
49294935
"gettableSilences": {
4930-
"description": "GettableSilences gettable silences",
49314936
"items": {
49324937
"$ref": "#/definitions/gettableSilence",
49334938
"type": "object"
@@ -8452,7 +8457,7 @@
84528457
}
84538458
}
84548459
},
8455-
"summary": "Get all notification templates.",
8460+
"summary": "Get all notification template groups.",
84568461
"tags": [
84578462
"provisioning"
84588463
]
@@ -8463,7 +8468,7 @@
84638468
"operationId": "RouteDeleteTemplate",
84648469
"parameters": [
84658470
{
8466-
"description": "Template name",
8471+
"description": "Template group name",
84678472
"in": "path",
84688473
"name": "name",
84698474
"required": true,
@@ -8487,7 +8492,7 @@
84878492
}
84888493
}
84898494
},
8490-
"summary": "Delete a template.",
8495+
"summary": "Delete a notification template group.",
84918496
"tags": [
84928497
"provisioning"
84938498
]
@@ -8496,7 +8501,7 @@
84968501
"operationId": "RouteGetTemplate",
84978502
"parameters": [
84988503
{
8499-
"description": "Template Name",
8504+
"description": "Template group name",
85008505
"in": "path",
85018506
"name": "name",
85028507
"required": true,
@@ -8517,7 +8522,7 @@
85178522
}
85188523
}
85198524
},
8520-
"summary": "Get a notification template.",
8525+
"summary": "Get a notification template group.",
85218526
"tags": [
85228527
"provisioning"
85238528
]
@@ -8529,7 +8534,7 @@
85298534
"operationId": "RoutePutTemplate",
85308535
"parameters": [
85318536
{
8532-
"description": "Template Name",
8537+
"description": "Template group name",
85338538
"in": "path",
85348539
"name": "name",
85358540
"required": true,
@@ -8568,7 +8573,7 @@
85688573
}
85698574
}
85708575
},
8571-
"summary": "Updates an existing notification template.",
8576+
"summary": "Updates an existing notification template group.",
85728577
"tags": [
85738578
"provisioning"
85748579
]

pkg/services/ngalert/api/tooling/spec.json

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3306,7 +3306,7 @@
33063306
"provisioning",
33073307
"stable"
33083308
],
3309-
"summary": "Get all notification templates.",
3309+
"summary": "Get all notification template groups.",
33103310
"operationId": "RouteGetTemplates",
33113311
"responses": {
33123312
"200": {
@@ -3324,12 +3324,12 @@
33243324
"provisioning",
33253325
"stable"
33263326
],
3327-
"summary": "Get a notification template.",
3327+
"summary": "Get a notification template group.",
33283328
"operationId": "RouteGetTemplate",
33293329
"parameters": [
33303330
{
33313331
"type": "string",
3332-
"description": "Template Name",
3332+
"description": "Template group name",
33333333
"name": "name",
33343334
"in": "path",
33353335
"required": true
@@ -3358,12 +3358,12 @@
33583358
"provisioning",
33593359
"stable"
33603360
],
3361-
"summary": "Updates an existing notification template.",
3361+
"summary": "Updates an existing notification template group.",
33623362
"operationId": "RoutePutTemplate",
33633363
"parameters": [
33643364
{
33653365
"type": "string",
3366-
"description": "Template Name",
3366+
"description": "Template group name",
33673367
"name": "name",
33683368
"in": "path",
33693369
"required": true
@@ -3407,12 +3407,12 @@
34073407
"provisioning",
34083408
"stable"
34093409
],
3410-
"summary": "Delete a template.",
3410+
"summary": "Delete a notification template group.",
34113411
"operationId": "RouteDeleteTemplate",
34123412
"parameters": [
34133413
{
34143414
"type": "string",
3415-
"description": "Template name",
3415+
"description": "Template group name",
34163416
"name": "name",
34173417
"in": "path",
34183418
"required": true
@@ -3797,6 +3797,9 @@
37973797
"AlertRuleEditorSettings": {
37983798
"type": "object",
37993799
"properties": {
3800+
"simplified_notifications_section": {
3801+
"type": "boolean"
3802+
},
38003803
"simplified_query_and_expressions_section": {
38013804
"type": "boolean"
38023805
}
@@ -4388,7 +4391,7 @@
43884391
"type": "string"
43894392
},
43904393
"ErrorSource": {
4391-
"$ref": "#/definitions/ErrorSource"
4394+
"$ref": "#/definitions/Source"
43924395
},
43934396
"Frames": {
43944397
"$ref": "#/definitions/Frames"
@@ -4597,10 +4600,6 @@
45974600
}
45984601
}
45994602
},
4600-
"ErrorSource": {
4601-
"description": "ErrorSource type defines the source of the error",
4602-
"type": "string"
4603-
},
46044603
"ErrorType": {
46054604
"type": "string",
46064605
"title": "ErrorType models the different API error types."
@@ -7243,6 +7242,9 @@
72437242
"groups"
72447243
],
72457244
"properties": {
7245+
"groupNextToken": {
7246+
"type": "string"
7247+
},
72467248
"groups": {
72477249
"type": "array",
72487250
"items": {
@@ -7608,6 +7610,10 @@
76087610
"SmtpNotEnabled": {
76097611
"$ref": "#/definitions/ResponseDetails"
76107612
},
7613+
"Source": {
7614+
"type": "string",
7615+
"title": "Source type defines the status source."
7616+
},
76117617
"Span": {
76127618
"type": "object",
76137619
"title": "A Span defines a continuous sequence of buckets.",
@@ -8274,6 +8280,7 @@
82748280
}
82758281
},
82768282
"alertGroups": {
8283+
"description": "AlertGroups alert groups",
82778284
"type": "array",
82788285
"items": {
82798286
"type": "object",
@@ -8435,7 +8442,6 @@
84358442
}
84368443
},
84378444
"gettableAlerts": {
8438-
"description": "GettableAlerts gettable alerts",
84398445
"type": "array",
84408446
"items": {
84418447
"type": "object",
@@ -8560,7 +8566,6 @@
85608566
}
85618567
},
85628568
"gettableSilences": {
8563-
"description": "GettableSilences gettable silences",
85648569
"type": "array",
85658570
"items": {
85668571
"type": "object",

0 commit comments

Comments
 (0)