Skip to content

Commit 37966a6

Browse files
thomasp98296Thomas Pham
andauthored
Task 15001443: Remove identity field from the ActionGroup swagger as it had wrong type, and it is unused (#19823)
* Task 15001443: Bug 14937463: Should throw a bad request with bad resourceId * Revert "Task 15001443: Bug 14937463: Should throw a bad request with bad resourceId" This reverts commit 4cfc489. * Remove unused property * Revert * Revert "Revert" This reverts commit b5ef90d. * Remove outdated api * Also remove kind * Remove kind Co-authored-by: Thomas Pham <[email protected]>
1 parent 23abda7 commit 37966a6

11 files changed

+1071
-106
lines changed

specification/monitor/resource-manager/Microsoft.Insights/stable/2019-03-01/actionGroups_API.json

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -352,16 +352,6 @@
352352
"readOnly": true,
353353
"description": "Azure resource type"
354354
},
355-
"kind": {
356-
"type": "string",
357-
"readOnly": true,
358-
"description": "Azure resource kind"
359-
},
360-
"identity": {
361-
"type": "string",
362-
"readOnly": true,
363-
"description": "Azure resource identity"
364-
},
365355
"location": {
366356
"type": "string",
367357
"description": "Resource location",

specification/monitor/resource-manager/Microsoft.Insights/stable/2019-06-01/actionGroups_API.json

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -352,16 +352,6 @@
352352
"readOnly": true,
353353
"description": "Azure resource type"
354354
},
355-
"kind": {
356-
"type": "string",
357-
"readOnly": true,
358-
"description": "Azure resource kind"
359-
},
360-
"identity": {
361-
"type": "string",
362-
"readOnly": true,
363-
"description": "Azure resource identity"
364-
},
365355
"location": {
366356
"type": "string",
367357
"description": "Resource location",

specification/monitor/resource-manager/Microsoft.Insights/stable/2021-09-01/actionGroups_API.json

Lines changed: 225 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@
219219
"description": "Send test notifications to a set of provided receivers",
220220
"operationId": "ActionGroups_PostTestNotifications",
221221
"x-ms-examples": {
222-
"List action groups": {
222+
"Create notifications at subscription level": {
223223
"$ref": "./examples/postTestNotifications.json"
224224
}
225225
},
@@ -242,9 +242,137 @@
242242
],
243243
"responses": {
244244
"202": {
245+
"description": "The notification request accepted",
246+
"headers": {
247+
"location": {
248+
"type": "string",
249+
"description": "The location header that has the polling uri."
250+
}
251+
}
252+
},
253+
"200": {
254+
"description": "The notification succeeded",
255+
"schema": {
256+
"$ref": "#/definitions/TestNotificationDetailsResponse"
257+
}
258+
},
259+
"default": {
260+
"description": "An error occurred while sending the test notifications",
261+
"schema": {
262+
"$ref": "#/definitions/ErrorResponse"
263+
}
264+
}
265+
}
266+
}
267+
},
268+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/createNotifications": {
269+
"post": {
270+
"x-ms-long-running-operation": true,
271+
"x-ms-long-running-operation-options": {
272+
"final-state-via": "location"
273+
},
274+
"description": "Send test notifications to a set of provided receivers",
275+
"operationId": "ActionGroups_CreateNotificationsAtResourceGroupLevel",
276+
"x-ms-examples": {
277+
"Create notifications at resource group level": {
278+
"$ref": "./examples/postTestNotificationsAtResourceGroupLevel.json"
279+
}
280+
},
281+
"parameters": [
282+
{
283+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter"
284+
},
285+
{
286+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter"
287+
},
288+
{
289+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter"
290+
},
291+
{
292+
"name": "notificationRequest",
293+
"in": "body",
294+
"required": true,
295+
"schema": {
296+
"$ref": "#/definitions/NotificationRequestBody"
297+
},
298+
"description": "The notification request body which includes the contact details"
299+
}
300+
],
301+
"responses": {
302+
"202": {
303+
"description": "The notification request accepted",
304+
"headers": {
305+
"location": {
306+
"type": "string",
307+
"description": "The location header that has the polling uri."
308+
}
309+
}
310+
},
311+
"200": {
312+
"description": "The notification succeeded",
313+
"schema": {
314+
"$ref": "#/definitions/TestNotificationDetailsResponse"
315+
}
316+
},
317+
"default": {
318+
"description": "An error occurred while sending the test notifications",
319+
"schema": {
320+
"$ref": "#/definitions/ErrorResponse"
321+
}
322+
}
323+
}
324+
}
325+
},
326+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/actionGroups/{actionGroupName}/createNotifications": {
327+
"post": {
328+
"x-ms-long-running-operation": true,
329+
"x-ms-long-running-operation-options": {
330+
"final-state-via": "location"
331+
},
332+
"description": "Send test notifications to a set of provided receivers",
333+
"operationId": "ActionGroups_CreateNotificationsAtActionGroupResourceLevel",
334+
"x-ms-examples": {
335+
"Create notifications at resource group level": {
336+
"$ref": "./examples/postTestNotificationsAtActionGroupResourceLevel.json"
337+
}
338+
},
339+
"parameters": [
340+
{
341+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter"
342+
},
343+
{
344+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter"
345+
},
346+
{
347+
"$ref": "#/parameters/ActionGroupNameParameter"
348+
},
349+
{
350+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter"
351+
},
352+
{
353+
"name": "notificationRequest",
354+
"in": "body",
355+
"required": true,
356+
"schema": {
357+
"$ref": "#/definitions/NotificationRequestBody"
358+
},
359+
"description": "The notification request body which includes the contact details"
360+
}
361+
],
362+
"responses": {
363+
"202": {
364+
"description": "The notification request accepted",
365+
"headers": {
366+
"location": {
367+
"type": "string",
368+
"description": "The location header that has the polling uri."
369+
}
370+
}
371+
},
372+
"200": {
245373
"description": "The notification succeeded",
246374
"schema": {
247-
"$ref": "#/definitions/TestNotificationResponse"
375+
"$ref": "#/definitions/TestNotificationDetailsResponse"
248376
}
249377
},
250378
"default": {
@@ -261,7 +389,7 @@
261389
"description": "Get the test notifications by the notification id",
262390
"operationId": "ActionGroups_GetTestNotifications",
263391
"x-ms-examples": {
264-
"Get notification details": {
392+
"Get notification details at subscription level": {
265393
"$ref": "./examples/getTestNotifications.json"
266394
}
267395
},
@@ -292,12 +420,93 @@
292420
}
293421
}
294422
},
423+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/notificationStatus/{notificationId}": {
424+
"get": {
425+
"description": "Get the test notifications by the notification id",
426+
"operationId": "ActionGroups_GetTestNotificationsAtResourceGroupLevel",
427+
"x-ms-examples": {
428+
"Get notification details at resource group level": {
429+
"$ref": "./examples/getTestNotificationsAtResourceGroupLevel.json"
430+
}
431+
},
432+
"parameters": [
433+
{
434+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter"
435+
},
436+
{
437+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter"
438+
},
439+
{
440+
"$ref": "#/parameters/NotificationIdParameter"
441+
},
442+
{
443+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter"
444+
}
445+
],
446+
"responses": {
447+
"200": {
448+
"description": "The notification details",
449+
"schema": {
450+
"$ref": "#/definitions/TestNotificationDetailsResponse"
451+
}
452+
},
453+
"default": {
454+
"description": "An error occurred while sending the test notifications",
455+
"schema": {
456+
"$ref": "#/definitions/ErrorResponse"
457+
}
458+
}
459+
}
460+
}
461+
},
462+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/actionGroups/{actionGroupName}/notificationStatus/{notificationId}": {
463+
"get": {
464+
"description": "Get the test notifications by the notification id",
465+
"operationId": "ActionGroups_GetTestNotificationsAtActionGroupResourceLevel",
466+
"x-ms-examples": {
467+
"Get notification details at resource group level": {
468+
"$ref": "./examples/getTestNotificationsAtActionGroupResourceLevel.json"
469+
}
470+
},
471+
"parameters": [
472+
{
473+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/SubscriptionIdParameter"
474+
},
475+
{
476+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter"
477+
},
478+
{
479+
"$ref": "#/parameters/ActionGroupNameParameter"
480+
},
481+
{
482+
"$ref": "#/parameters/NotificationIdParameter"
483+
},
484+
{
485+
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter"
486+
}
487+
],
488+
"responses": {
489+
"200": {
490+
"description": "The notification details",
491+
"schema": {
492+
"$ref": "#/definitions/TestNotificationDetailsResponse"
493+
}
494+
},
495+
"default": {
496+
"description": "An error occurred while sending the test notifications",
497+
"schema": {
498+
"$ref": "#/definitions/ErrorResponse"
499+
}
500+
}
501+
}
502+
}
503+
},
295504
"/subscriptions/{subscriptionId}/providers/Microsoft.Insights/actionGroups": {
296505
"get": {
297506
"description": "Get a list of all action groups in a subscription.",
298507
"operationId": "ActionGroups_ListBySubscriptionId",
299508
"x-ms-examples": {
300-
"List action groups": {
509+
"List action groups at subscription level": {
301510
"$ref": "./examples/listActionGroups.json"
302511
}
303512
},
@@ -333,7 +542,7 @@
333542
"description": "Get a list of all action groups in a resource group.",
334543
"operationId": "ActionGroups_ListByResourceGroup",
335544
"x-ms-examples": {
336-
"List action groups": {
545+
"List action groups at resource group level": {
337546
"$ref": "./examples/listActionGroups.json"
338547
}
339548
},
@@ -435,16 +644,6 @@
435644
"readOnly": true,
436645
"description": "Azure resource type"
437646
},
438-
"kind": {
439-
"type": "string",
440-
"readOnly": true,
441-
"description": "Azure resource kind"
442-
},
443-
"identity": {
444-
"type": "string",
445-
"readOnly": true,
446-
"description": "Azure resource identity"
447-
},
448647
"location": {
449648
"type": "string",
450649
"description": "Resource location",
@@ -468,62 +667,39 @@
468667
"x-ms-azure-resource": true,
469668
"description": "An azure resource object"
470669
},
471-
"TestNotificationResponse": {
472-
"description": "The response when test notification succeeded",
473-
"type": "object",
474-
"properties": {
475-
"notificationId": {
476-
"type": "string",
477-
"description": "The notification id"
478-
},
479-
"correlationId": {
480-
"type": "string",
481-
"description": "The correlation id"
482-
},
483-
"createdTime": {
484-
"type": "string",
485-
"description": "The created time"
486-
}
487-
},
488-
"required": [
489-
"notificationId",
490-
"correlationId",
491-
"createdTime"
492-
]
493-
},
494670
"TestNotificationDetailsResponse": {
495671
"description": "The details of the test notification results.",
496672
"type": "object",
497673
"properties": {
498-
"Context": {
674+
"context": {
499675
"type": "object",
500676
"$ref": "#/definitions/Context"
501677
},
502-
"State": {
678+
"state": {
503679
"type": "string",
504680
"description": "The overall state"
505681
},
506-
"CompletedTime": {
682+
"completedTime": {
507683
"type": "string",
508684
"description": "The completed time"
509685
},
510-
"CreatedTime": {
686+
"createdTime": {
511687
"type": "string",
512688
"description": "The created time"
513689
},
514-
"ActionDetails": {
690+
"actionDetails": {
691+
"x-ms-identifiers": [
692+
"name"
693+
],
515694
"type": "array",
516695
"items": {
517696
"$ref": "#/definitions/ActionDetail"
518697
},
519-
"x-ms-identifiers": [
520-
"Name"
521-
],
522698
"description": "The list of action detail"
523699
}
524700
},
525701
"required": [
526-
"State"
702+
"state"
527703
]
528704
},
529705
"ActionDetail": {
@@ -560,11 +736,11 @@
560736
"description": "The context info",
561737
"type": "object",
562738
"properties": {
563-
"NotificationSource": {
739+
"notificationSource": {
564740
"type": "string",
565741
"description": "The source of the notification request"
566742
},
567-
"ContextType": {
743+
"contextType": {
568744
"type": "string",
569745
"description": "The context id type"
570746
}

0 commit comments

Comments
 (0)