diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/AlertProcessingRules.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/AlertProcessingRules.json deleted file mode 100644 index 061fdf3f1ea1..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/AlertProcessingRules.json +++ /dev/null @@ -1,871 +0,0 @@ -{ - "swagger": "2.0", - "info": { - "version": "2023-05-01-preview", - "title": "Azure Alerts Management Service Resource Provider", - "description": "APIs for Azure alert processing rules CRUD operations." - }, - "host": "management.azure.com", - "schemes": [ - "https" - ], - "consumes": [ - "application/json" - ], - "produces": [ - "application/json" - ], - "securityDefinitions": { - "azure_auth": { - "type": "oauth2", - "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", - "flow": "implicit", - "description": "Azure Active Directory OAuth2 Flow", - "scopes": { - "user_impersonation": "impersonate your user account" - } - } - }, - "paths": { - "/subscriptions/{subscriptionId}/providers/Microsoft.AlertsManagement/actionRules": { - "get": { - "description": "List all alert processing rules in a subscription.", - "operationId": "AlertProcessingRules_ListBySubscription", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Return the list of alert processing rules.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRulesList" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "GetAlertProcessingRulesSubscriptionWide": { - "$ref": "./examples/AlertProcessingRules_List_Subscription.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AlertsManagement/actionRules": { - "get": { - "operationId": "AlertProcessingRules_ListByResourceGroup", - "description": "List all alert processing rules in a resource group.", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Return the list of alert processing rules.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRulesList" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "GetAlertProcessingRulesResourceGroupWide": { - "$ref": "./examples/AlertProcessingRules_List_ResourceGroup.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AlertsManagement/actionRules/{alertProcessingRuleName}": { - "get": { - "description": "Get an alert processing rule by name.", - "operationId": "AlertProcessingRules_GetByName", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name of the alert processing rule that needs to be fetched.", - "required": true, - "type": "string" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Returns the specific alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "GetAlertProcessingRuleById": { - "$ref": "./examples/AlertProcessingRules_GetById.json" - } - } - }, - "put": { - "operationId": "AlertProcessingRules_CreateOrUpdate", - "description": "Create or update an alert processing rule.", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name of the alert processing rule that needs to be created/updated.", - "required": true, - "type": "string" - }, - { - "name": "alertProcessingRule", - "in": "body", - "description": "Alert processing rule to be created/updated.", - "required": true, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Returns the updated alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "201": { - "description": "Created. Returns the created alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "Create or update a rule that adds an action group to all alerts in a subscription": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json" - }, - "Create or update a rule that adds two action groups to all Sev0 and Sev1 alerts in two resource groups": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json" - }, - "Create or update a rule that removes all action groups from alerts on a specific VM during a one-off maintenance window (1800-2000 at a specific date, Pacific Standard Time)": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json" - }, - "Create or update a rule that removes all action groups from all alerts on any VM in two resource groups during a recurring maintenance window (2200-0400 every Sat and Sun, India Standard Time)": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json" - }, - "Create or update a rule that removes all action groups outside business hours (Mon-Fri 09:00-17:00, Eastern Standard Time)": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json" - }, - "Create or update a rule that removes all action groups from all alerts in a subscription coming from a specific alert rule": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json" - }, - "Create or update a rule that adds alerts correlation": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_add_correlation.json" - } - } - }, - "delete": { - "description": "Delete an alert processing rule.", - "operationId": "AlertProcessingRules_Delete", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name of the alert processing rule that needs to be deleted.", - "required": true, - "type": "string" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successful request to delete an alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - } - }, - "204": { - "description": "No content: the request was successful, but the response is empty.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "DeleteAlertProcessingRule": { - "$ref": "./examples/AlertProcessingRules_Delete.json" - } - } - }, - "patch": { - "description": "Enable, disable, or update tags for an alert processing rule.", - "operationId": "AlertProcessingRules_Update", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name that needs to be updated.", - "required": true, - "type": "string" - }, - { - "name": "alertProcessingRulePatch", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/PatchObject" - }, - "description": "Parameters supplied to the operation." - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Returns the created/updated alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "PatchAlertProcessingRule": { - "$ref": "./examples/AlertProcessingRules_Patch.json" - } - } - } - } - }, - "parameters": { - "subscriptionId": { - "name": "subscriptionId", - "in": "path", - "required": true, - "type": "string", - "description": "The ID of the target subscription.", - "minLength": 1 - }, - "resourceGroupName": { - "name": "resourceGroupName", - "description": "Resource group name where the resource is created.", - "type": "string", - "in": "path", - "required": true, - "x-ms-parameter-location": "method" - } - }, - "definitions": { - "errorResponse": { - "description": "An error response from the service.", - "properties": { - "error": { - "$ref": "#/definitions/errorResponseBody" - } - } - }, - "errorResponseBody": { - "description": "Details of error response.", - "properties": { - "code": { - "type": "string", - "description": "Error code, intended to be consumed programmatically." - }, - "message": { - "type": "string", - "description": "Description of the error, intended for display in user interface." - }, - "target": { - "type": "string", - "description": "Target of the particular error, for example name of the property." - }, - "details": { - "type": "array", - "description": "A list of additional details about the error.", - "items": { - "$ref": "#/definitions/errorResponseBody" - } - } - } - }, - "Resource": { - "x-ms-azure-resource": true, - "description": "An azure resource object", - "properties": { - "id": { - "type": "string", - "readOnly": true, - "description": "Azure resource Id" - }, - "type": { - "type": "string", - "readOnly": true, - "description": "Azure resource type" - }, - "name": { - "type": "string", - "readOnly": true, - "description": "Azure resource name" - } - } - }, - "ManagedResource": { - "description": "An azure managed resource object.", - "allOf": [ - { - "$ref": "#/definitions/Resource" - } - ], - "properties": { - "location": { - "type": "string", - "description": "Resource location", - "x-ms-mutability": [ - "create", - "read" - ] - }, - "tags": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "Resource tags" - } - }, - "required": [ - "location" - ] - }, - "Scopes": { - "type": "array", - "description": "List of ARM IDs which will be the target of the given alert processing rule.", - "items": { - "type": "string" - } - }, - "Condition": { - "type": "object", - "description": "Condition to trigger an alert processing rule.", - "properties": { - "field": { - "type": "string", - "description": "Field for a given condition.", - "enum": [ - "Severity", - "MonitorService", - "MonitorCondition", - "SignalType", - "TargetResourceType", - "TargetResource", - "TargetResourceGroup", - "AlertRuleId", - "AlertRuleName", - "Description", - "AlertContext" - ], - "x-ms-enum": { - "name": "Field", - "modelAsString": true - } - }, - "operator": { - "type": "string", - "description": "Operator for a given condition.", - "enum": [ - "Equals", - "NotEquals", - "Contains", - "DoesNotContain" - ], - "x-ms-enum": { - "name": "Operator", - "modelAsString": true - } - }, - "values": { - "type": "array", - "description": "List of values to match for a given condition.", - "items": { - "type": "string" - } - } - } - }, - "Conditions": { - "type": "array", - "description": "Conditions in alert instance to be matched for a given alert processing rule. Default value is all. Multiple values could be provided with comma separation.", - "items": { - "$ref": "#/definitions/Condition" - } - }, - "Schedule": { - "type": "object", - "description": "Scheduling configuration for a given alert processing rule.", - "properties": { - "effectiveFrom": { - "type": "string", - "pattern": "^(?:(\\d{4}-\\d{2}-\\d{2})T(\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?))$", - "description": "Scheduling effective from time. Date-Time in ISO-8601 format without timezone suffix." - }, - "effectiveUntil": { - "type": "string", - "pattern": "^(?:(\\d{4}-\\d{2}-\\d{2})T(\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?))$", - "description": "Scheduling effective until time. Date-Time in ISO-8601 format without timezone suffix." - }, - "timeZone": { - "type": "string", - "description": "Scheduling time zone." - }, - "recurrences": { - "type": "array", - "description": "List of recurrences.", - "items": { - "$ref": "#/definitions/Recurrence" - } - } - } - }, - "Recurrence": { - "type": "object", - "description": "Recurrence object.", - "discriminator": "recurrenceType", - "required": [ - "recurrenceType" - ], - "properties": { - "recurrenceType": { - "type": "string", - "description": "Specifies when the recurrence should be applied.", - "enum": [ - "Daily", - "Weekly", - "Monthly" - ], - "x-ms-enum": { - "name": "RecurrenceType", - "modelAsString": true - } - }, - "startTime": { - "type": "string", - "description": "Start time for recurrence." - }, - "endTime": { - "type": "string", - "description": "End time for recurrence." - } - } - }, - "DailyRecurrence": { - "x-ms-discriminator-value": "Daily", - "type": "object", - "description": "Daily recurrence object.", - "required": [ - "startTime", - "endTime" - ], - "allOf": [ - { - "$ref": "#/definitions/Recurrence" - } - ] - }, - "WeeklyRecurrence": { - "x-ms-discriminator-value": "Weekly", - "type": "object", - "description": "Weekly recurrence object.", - "required": [ - "daysOfWeek" - ], - "allOf": [ - { - "$ref": "#/definitions/Recurrence" - } - ], - "properties": { - "daysOfWeek": { - "type": "array", - "description": "Specifies the values for weekly recurrence pattern.", - "items": { - "$ref": "#/definitions/DaysOfWeek" - } - } - } - }, - "MonthlyRecurrence": { - "x-ms-discriminator-value": "Monthly", - "type": "object", - "description": "Monthly recurrence object.", - "required": [ - "daysOfMonth" - ], - "allOf": [ - { - "$ref": "#/definitions/Recurrence" - } - ], - "properties": { - "daysOfMonth": { - "type": "array", - "description": "Specifies the values for monthly recurrence pattern.", - "items": { - "type": "integer", - "format": "int32" - } - } - } - }, - "DaysOfWeek": { - "type": "string", - "description": "Days of week.", - "enum": [ - "Sunday", - "Monday", - "Tuesday", - "Wednesday", - "Thursday", - "Friday", - "Saturday" - ], - "x-ms-enum": { - "name": "DaysOfWeek", - "modelAsString": true - } - }, - "AlertProcessingRule": { - "type": "object", - "description": "Alert processing rule object containing target scopes, conditions and scheduling logic.", - "allOf": [ - { - "$ref": "#/definitions/ManagedResource" - } - ], - "properties": { - "properties": { - "description": "Alert processing rule properties.", - "$ref": "#/definitions/AlertProcessingRuleProperties" - }, - "systemData": { - "description": "Alert processing rule system data.", - "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/systemData" - } - } - }, - "AlertProcessingRuleProperties": { - "type": "object", - "description": "Alert processing rule properties defining scopes, conditions and scheduling logic for alert processing rule.", - "required": [ - "scopes", - "actions" - ], - "properties": { - "scopes": { - "description": "Scopes on which alert processing rule will apply.", - "$ref": "#/definitions/Scopes" - }, - "conditions": { - "description": "Conditions on which alerts will be filtered.", - "$ref": "#/definitions/Conditions" - }, - "schedule": { - "description": "Scheduling for alert processing rule.", - "$ref": "#/definitions/Schedule" - }, - "actions": { - "type": "array", - "description": "Actions to be applied.", - "items": { - "$ref": "#/definitions/Action" - } - }, - "description": { - "type": "string", - "description": "Description of alert processing rule." - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates if the given alert processing rule is enabled or disabled." - } - } - }, - "Action": { - "type": "object", - "description": "Action to be applied.", - "discriminator": "actionType", - "required": [ - "actionType" - ], - "properties": { - "actionType": { - "type": "string", - "description": "Action that should be applied.", - "enum": [ - "AddActionGroups", - "RemoveAllActionGroups", - "CorrelateAlerts" - ], - "x-ms-enum": { - "name": "actionType", - "modelAsString": true - } - } - } - }, - "AddActionGroups": { - "x-ms-discriminator-value": "AddActionGroups", - "type": "object", - "description": "Add action groups to alert processing rule.", - "required": [ - "actionGroupIds" - ], - "allOf": [ - { - "$ref": "#/definitions/Action" - } - ], - "properties": { - "actionGroupIds": { - "description": "List of action group Ids to add to alert processing rule.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "RemoveAllActionGroups": { - "x-ms-discriminator-value": "RemoveAllActionGroups", - "type": "object", - "description": "Indicates if all action groups should be removed.", - "allOf": [ - { - "$ref": "#/definitions/Action" - } - ] - }, - "CorrelateAlerts": { - "x-ms-discriminator-value": "CorrelateAlerts", - "type": "object", - "description": "Add logic for alerts correlation.", - "required": [ - "correlateBy", - "correlationInterval", - "priority" - ], - "allOf": [ - { - "$ref": "#/definitions/Action" - } - ], - "properties": { - "correlateBy": { - "type": "array", - "description": "The list of conditions for the alerts correlations.", - "items": { - "$ref": "#/definitions/CorrelateBy" - }, - "x-ms-identifiers": [] - }, - "correlationInterval": { - "type": "string", - "description": "The required duration (in ISO8601 format) for the alerts correlation." - }, - "priority": { - "type": "integer", - "format": "int32", - "description": "The priority of this correlation." - }, - "notificationsForCorrelatedAlerts": { - "type": "string", - "default": "SuppressAlways", - "description": "Indicates how to handle child alerts notifications.", - "enum": [ - "NotifyAlways", - "SuppressAlways" - ], - "x-ms-enum": { - "name": "NotificationsForCorrelatedAlerts", - "modelAsString": true - } - } - } - }, - "CorrelateBy": { - "type": "object", - "description": "The logic for the correlation.", - "properties": { - "field": { - "type": "string", - "description": "The JPath of the property that the alerts should be correlated by." - } - } - }, - "AlertProcessingRulesList": { - "type": "object", - "description": "List of alert processing rules.", - "properties": { - "nextLink": { - "type": "string", - "description": "URL to fetch the next set of alert processing rules." - }, - "value": { - "type": "array", - "description": "List of alert processing rules.", - "items": { - "$ref": "#/definitions/AlertProcessingRule" - } - } - } - }, - "PatchProperties": { - "description": "Alert processing rule properties supported by patch.", - "properties": { - "enabled": { - "type": "boolean", - "description": "Indicates if the given alert processing rule is enabled or disabled." - } - } - }, - "PatchObject": { - "description": "Data contract for patch.", - "properties": { - "properties": { - "x-ms-client-flatten": true, - "description": "Properties supported by patch operation.", - "$ref": "#/definitions/PatchProperties" - }, - "tags": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "Tags to be updated." - } - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json deleted file mode 100644 index 32b4fc1d28be..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json +++ /dev/null @@ -1,93 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "AddActionGroupToSubscription", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" - ] - } - ], - "description": "Add ActionGroup1 to all alerts in the subscription", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" - ] - } - ], - "description": "Add ActionGroup1 to all alerts in the subscription", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupToSubscription", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupToSubscription", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" - ] - } - ], - "description": "Add ActionGroup1 to all alerts in the subscription", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupToSubscription", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupToSubscription", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation.json deleted file mode 100644 index 8fde816481be..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation.json +++ /dev/null @@ -1,108 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "CorrelateAlerts", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways" - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways" - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "CorrelateAlerts", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways" - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "CorrelateAlerts", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json deleted file mode 100644 index ae6e9c54d3d3..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json +++ /dev/null @@ -1,129 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "AddActionGroupsBySeverity", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "sev0", - "sev1" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - ], - "description": "Add AGId1 and AGId2 to all Sev0 and Sev1 alerts in these resourceGroups", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-13T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "sev0", - "sev1" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - ], - "description": "Add AGId1 and AGId2 to all Sev0 and Sev1 alerts in these resourceGroups", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupsBySeverity", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupsBySeverity", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-13T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "sev0", - "sev1" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - ], - "description": "Add AGId1 and AGId2 to all Sev0 and Sev1 alerts in these resourceGroups", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupsBySeverity", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupsBySeverity", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json deleted file mode 100644 index 8a6297b88e2c..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json +++ /dev/null @@ -1,111 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsSpecificAlertRule", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "conditions": [ - { - "field": "AlertRuleId", - "operator": "Equals", - "values": [ - "/subscriptions/suubId1/resourceGroups/Rgid2/providers/microsoft.insights/activityLogAlerts/RuleName" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Removes all ActionGroups from all Alerts that fire on above AlertRule", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "conditions": [ - { - "field": "AlertRuleId", - "operator": "Equals", - "values": [ - "/subscriptions/suubId1/resourceGroups/Rgid2/providers/microsoft.insights/activityLogAlerts/RuleName" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Removes all ActionGroups from all Alerts that fire on above AlertRule", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsSpecificAlertRule", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsSpecificAlertRule", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "conditions": [ - { - "field": "AlertRuleId", - "operator": "Equals", - "values": [ - "/subscriptions/suubId1/resourceGroups/Rgid2/providers/microsoft.insights/activityLogAlerts/RuleName" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Removes all ActionGroups from all Alerts that fire on above AlertRule", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsSpecificAlertRule", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsSpecificAlertRule", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json deleted file mode 100644 index 50a9d0e3ba95..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json +++ /dev/null @@ -1,135 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsOutsideBusinessHours", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "Eastern Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "17:00:00", - "endTime": "09:00:00" - }, - { - "recurrenceType": "Weekly", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups outside business hours", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "Eastern Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "17:00:00", - "endTime": "09:00:00" - }, - { - "recurrenceType": "Weekly", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups outside business hours", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsOutsideBusinessHours", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsOutsideBusinessHours", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "Eastern Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "17:00:00", - "endTime": "09:00:00" - }, - { - "recurrenceType": "Weekly", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups outside business hours", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsOutsideBusinessHours", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsOutsideBusinessHours", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json deleted file mode 100644 index f8565f60ba12..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json +++ /dev/null @@ -1,156 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsRecurringMaintenance", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "TargetResourceType", - "operator": "Equals", - "values": [ - "microsoft.compute/virtualmachines" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "India Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "22:00:00", - "endTime": "04:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups from all Vitual machine Alerts during the recurring maintenance", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "TargetResourceType", - "operator": "Equals", - "values": [ - "microsoft.compute/virtualmachines" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "India Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "22:00:00", - "endTime": "04:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups from all Vitual machine Alerts during the recurring maintenance", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsRecurringMaintenance", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsRecurringMaintenance", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "TargetResourceType", - "operator": "Equals", - "values": [ - "microsoft.compute/virtualmachines" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "India Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "22:00:00", - "endTime": "04:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups from all Vitual machine Alerts during the recurring maintenance", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsRecurringMaintenance", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsRecurringMaintenance", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json deleted file mode 100644 index 6af7e683b7e6..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json +++ /dev/null @@ -1,99 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsMaintenanceWindow", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1/providers/Microsoft.Compute/virtualMachines/VMName" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "effectiveFrom": "2021-04-15T18:00:00", - "effectiveUntil": "2021-04-15T20:00:00", - "timeZone": "Pacific Standard Time" - }, - "description": "Removes all ActionGroups from all Alerts on VMName during the maintenance window", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T20:13:29Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1/providers/Microsoft.Compute/virtualMachines/VMName" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "effectiveFrom": "2021-04-15T18:00:00", - "effectiveUntil": "2021-04-15T20:00:00", - "timeZone": "Pacific Standard Time" - }, - "description": "Removes all ActionGroups from all Alerts on VMName during the maintenance window", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsMaintenanceWindow", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsMaintenanceWindow", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T20:13:29Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1/providers/Microsoft.Compute/virtualMachines/VMName" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "effectiveFrom": "2021-04-15T18:00:00", - "effectiveUntil": "2021-04-15T20:00:00", - "timeZone": "Pacific Standard Time" - }, - "description": "Removes all ActionGroups from all Alerts on VMName during the maintenance window", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsMaintenanceWindow", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsMaintenanceWindow", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Delete.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Delete.json deleted file mode 100644 index 4739ed28de22..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Delete.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "DailySuppression" - }, - "responses": { - "200": {}, - "204": {} - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_GetById.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_GetById.json deleted file mode 100644 index 06d56f08128d..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_GetById.json +++ /dev/null @@ -1,96 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "DailySuppression" - }, - "responses": { - "200": { - "body": { - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/DailySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "DailySuppression", - "location": "Global", - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "MonitorCondition", - "operator": "Equals", - "values": [ - "Fired" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-01-10T22:05:09", - "effectiveUntil": "2018-12-10T22:05:09", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "06:00:00", - "endTime": "14:00:00" - }, - { - "recurrenceType": "Weekly", - "startTime": "10:00:00", - "endTime": "20:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "actiongGroup1", - "actiongGroup2" - ] - } - ], - "description": "Alert processing rule on resource group for daily and weekly scheduling", - "enabled": true - }, - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_List_ResourceGroup.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_List_ResourceGroup.json deleted file mode 100644 index b699ca7bbea2..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_List_ResourceGroup.json +++ /dev/null @@ -1,135 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg" - }, - "responses": { - "200": { - "body": { - "nextLink": "https://management.azure.com:443/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules?api-version=2023-05-01-preview&ctoken=%2bRID%3aPlwOAPHEGwB9UwEAAAAgCw%3d%3d%23RT%3a2%23TRC%3a500%23RTD%3aqtQyMDE4LTA2LTEyVDE1OjEyOjE1", - "value": [ - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-09-12T06:00:00", - "effectiveUntil": "2018-09-20T14:00:00", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "06:00:00", - "endTime": "14:00:00" - } - ] - }, - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Alert processing rule on resource group for daily suppression", - "enabled": true - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/DailySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "DailySuppression", - "location": "Global", - "tags": {} - }, - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.Compute/VirtualMachines/testResource" - ], - "conditions": [ - { - "field": "MonitorCondition", - "operator": "Equals", - "values": [ - "Fired" - ] - }, - { - "field": "Description", - "operator": "Contains", - "values": [ - "Percentage CPU greater than 80%", - "Metric alert on resource foo" - ] - }, - { - "field": "AlertContext", - "operator": "DoesNotContain", - "values": [ - "testresource", - "foo" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.insights/actiongroups/testAG" - ] - } - ], - "description": "Alert processing rule on resource group for sending email", - "enabled": true - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/WeeklySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "WeeklySuppression", - "location": "Global", - "tags": {} - } - ] - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_List_Subscription.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_List_Subscription.json deleted file mode 100644 index cbf581ab8ff4..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_List_Subscription.json +++ /dev/null @@ -1,126 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d" - }, - "responses": { - "200": { - "body": { - "nextLink": "https://management.azure.com:443/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/providers/Microsoft.AlertsManagement/actionRules?api-version=2023-05-01-preview&ctoken=%2bRID%3aPlwOAPHEGwB9UwEAAAAgCw%3d%3d%23RT%3a2%23TRC%3a500%23RTD%3aqtQyMDE4LTA2LTEyVDE1OjEyOjE1", - "value": [ - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-01-10T22:05:09", - "effectiveUntil": "2018-12-10T22:05:09", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "06:00:00", - "endTime": "14:00:00" - } - ] - }, - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Alert processing rule on resource group for daily suppression", - "enabled": true - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/DailySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "DailySuppression", - "location": "Global", - "tags": {} - }, - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.Compute/VirtualMachines/testResource" - ], - "conditions": [ - { - "field": "MonitorCondition", - "operator": "Equals", - "values": [ - "Fired" - ] - }, - { - "field": "Description", - "operator": "Contains", - "values": [ - "Percentage CPU greater than 80%", - "Metric alert on resource foo" - ] - } - ], - "description": "Alert processing rule on resource group for adding action group", - "enabled": true, - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "actiongGroup1" - ] - } - ] - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/WeeklySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "WeeklySuppression", - "location": "Global", - "tags": {} - } - ] - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Patch.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Patch.json deleted file mode 100644 index 7c663679c69f..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2023-05-01-preview/examples/AlertProcessingRules_Patch.json +++ /dev/null @@ -1,92 +0,0 @@ -{ - "parameters": { - "api-version": "2023-05-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "WeeklySuppression", - "alertProcessingRulePatch": { - "tags": { - "key1": "value1", - "key2": "value2" - }, - "properties": { - "enabled": false - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-12-10T22:05:09", - "effectiveUntil": "2018-12-05T22:05:09", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "06:00:00", - "endTime": "14:00:00", - "daysOfWeek": [ - "Tuesday", - "Friday" - ] - } - ] - }, - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Alert processing rule on resource group for weekly suppression", - "enabled": false - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/WeeklySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "WeeklySuppression", - "location": "Global", - "tags": { - "key1": "value1", - "key2": "value2" - } - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/AlertProcessingRules.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/AlertProcessingRules.json deleted file mode 100644 index a24150c84c64..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/AlertProcessingRules.json +++ /dev/null @@ -1,911 +0,0 @@ -{ - "swagger": "2.0", - "info": { - "version": "2024-03-01-preview", - "title": "Azure Alerts Management Service Resource Provider", - "description": "APIs for Azure alert processing rules CRUD operations." - }, - "host": "management.azure.com", - "schemes": [ - "https" - ], - "consumes": [ - "application/json" - ], - "produces": [ - "application/json" - ], - "securityDefinitions": { - "azure_auth": { - "type": "oauth2", - "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", - "flow": "implicit", - "description": "Azure Active Directory OAuth2 Flow", - "scopes": { - "user_impersonation": "impersonate your user account" - } - } - }, - "paths": { - "/subscriptions/{subscriptionId}/providers/Microsoft.AlertsManagement/actionRules": { - "get": { - "description": "List all alert processing rules in a subscription.", - "operationId": "AlertProcessingRules_ListBySubscription", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Return the list of alert processing rules.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRulesList" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "GetAlertProcessingRulesSubscriptionWide": { - "$ref": "./examples/AlertProcessingRules_List_Subscription.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AlertsManagement/actionRules": { - "get": { - "operationId": "AlertProcessingRules_ListByResourceGroup", - "description": "List all alert processing rules in a resource group.", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Return the list of alert processing rules.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRulesList" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "GetAlertProcessingRulesResourceGroupWide": { - "$ref": "./examples/AlertProcessingRules_List_ResourceGroup.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AlertsManagement/actionRules/{alertProcessingRuleName}": { - "get": { - "description": "Get an alert processing rule by name.", - "operationId": "AlertProcessingRules_GetByName", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name of the alert processing rule that needs to be fetched.", - "required": true, - "type": "string" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Returns the specific alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "GetAlertProcessingRuleById": { - "$ref": "./examples/AlertProcessingRules_GetById.json" - } - } - }, - "put": { - "operationId": "AlertProcessingRules_CreateOrUpdate", - "description": "Create or update an alert processing rule.", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name of the alert processing rule that needs to be created/updated.", - "required": true, - "type": "string" - }, - { - "name": "alertProcessingRule", - "in": "body", - "description": "Alert processing rule to be created/updated.", - "required": true, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Returns the updated alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "201": { - "description": "Created. Returns the created alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "Create or update a rule that adds an action group to all alerts in a subscription": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json" - }, - "Create or update a rule that adds two action groups to all Sev0 and Sev1 alerts in two resource groups": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json" - }, - "Create or update a rule that removes all action groups from alerts on a specific VM during a one-off maintenance window (1800-2000 at a specific date, Pacific Standard Time)": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json" - }, - "Create or update a rule that removes all action groups from all alerts on any VM in two resource groups during a recurring maintenance window (2200-0400 every Sat and Sun, India Standard Time)": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json" - }, - "Create or update a rule that removes all action groups outside business hours (Mon-Fri 09:00-17:00, Eastern Standard Time)": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json" - }, - "Create or update a rule that removes all action groups from all alerts in a subscription coming from a specific alert rule": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json" - }, - "Create or update a rule that adds alerts correlation": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_add_correlation.json" - }, - "Create or update a rule that adds alerts correlation with correlation updates": { - "$ref": "./examples/AlertProcessingRules_Create_or_update_add_correlation_with_correlation_updates.json" - } - } - }, - "delete": { - "description": "Delete an alert processing rule.", - "operationId": "AlertProcessingRules_Delete", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name of the alert processing rule that needs to be deleted.", - "required": true, - "type": "string" - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successful request to delete an alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - } - }, - "204": { - "description": "No content: the request was successful, but the response is empty.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "DeleteAlertProcessingRule": { - "$ref": "./examples/AlertProcessingRules_Delete.json" - } - } - }, - "patch": { - "description": "Enable, disable, or update tags for an alert processing rule.", - "operationId": "AlertProcessingRules_Update", - "parameters": [ - { - "$ref": "#/parameters/subscriptionId" - }, - { - "$ref": "#/parameters/resourceGroupName" - }, - { - "name": "alertProcessingRuleName", - "in": "path", - "description": "The name that needs to be updated.", - "required": true, - "type": "string" - }, - { - "name": "alertProcessingRulePatch", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/PatchObject" - }, - "description": "Parameters supplied to the operation." - }, - { - "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "OK. Returns the created/updated alert processing rule.", - "headers": { - "x-ms-request-id": { - "type": "string", - "description": "Service generated Request ID." - } - }, - "schema": { - "$ref": "#/definitions/AlertProcessingRule" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/errorResponse" - } - } - }, - "x-ms-examples": { - "PatchAlertProcessingRule": { - "$ref": "./examples/AlertProcessingRules_Patch.json" - } - } - } - } - }, - "parameters": { - "subscriptionId": { - "name": "subscriptionId", - "in": "path", - "required": true, - "type": "string", - "description": "The ID of the target subscription.", - "minLength": 1 - }, - "resourceGroupName": { - "name": "resourceGroupName", - "description": "Resource group name where the resource is created.", - "type": "string", - "in": "path", - "required": true, - "x-ms-parameter-location": "method" - } - }, - "definitions": { - "errorResponse": { - "description": "An error response from the service.", - "properties": { - "error": { - "$ref": "#/definitions/errorResponseBody" - } - } - }, - "errorResponseBody": { - "description": "Details of error response.", - "properties": { - "code": { - "type": "string", - "description": "Error code, intended to be consumed programmatically." - }, - "message": { - "type": "string", - "description": "Description of the error, intended for display in user interface." - }, - "target": { - "type": "string", - "description": "Target of the particular error, for example name of the property." - }, - "details": { - "type": "array", - "description": "A list of additional details about the error.", - "items": { - "$ref": "#/definitions/errorResponseBody" - } - } - } - }, - "Resource": { - "x-ms-azure-resource": true, - "description": "An azure resource object", - "properties": { - "id": { - "type": "string", - "readOnly": true, - "description": "Azure resource Id" - }, - "type": { - "type": "string", - "readOnly": true, - "description": "Azure resource type" - }, - "name": { - "type": "string", - "readOnly": true, - "description": "Azure resource name" - } - } - }, - "ManagedResource": { - "description": "An azure managed resource object.", - "allOf": [ - { - "$ref": "#/definitions/Resource" - } - ], - "properties": { - "location": { - "type": "string", - "description": "Resource location", - "x-ms-mutability": [ - "create", - "read" - ] - }, - "tags": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "Resource tags" - } - }, - "required": [ - "location" - ] - }, - "Scopes": { - "type": "array", - "description": "List of ARM IDs which will be the target of the given alert processing rule.", - "items": { - "type": "string" - } - }, - "Condition": { - "type": "object", - "description": "Condition to trigger an alert processing rule.", - "properties": { - "field": { - "type": "string", - "description": "Field for a given condition.", - "enum": [ - "Severity", - "MonitorService", - "MonitorCondition", - "SignalType", - "TargetResourceType", - "TargetResource", - "TargetResourceGroup", - "AlertRuleId", - "AlertRuleName", - "Description", - "AlertContext" - ], - "x-ms-enum": { - "name": "Field", - "modelAsString": true - } - }, - "operator": { - "type": "string", - "description": "Operator for a given condition.", - "enum": [ - "Equals", - "NotEquals", - "Contains", - "DoesNotContain" - ], - "x-ms-enum": { - "name": "Operator", - "modelAsString": true - } - }, - "values": { - "type": "array", - "description": "List of values to match for a given condition.", - "items": { - "type": "string" - } - } - } - }, - "Conditions": { - "type": "array", - "description": "Conditions in alert instance to be matched for a given alert processing rule. Default value is all. Multiple values could be provided with comma separation.", - "items": { - "$ref": "#/definitions/Condition" - } - }, - "Schedule": { - "type": "object", - "description": "Scheduling configuration for a given alert processing rule.", - "properties": { - "effectiveFrom": { - "type": "string", - "pattern": "^(?:(\\d{4}-\\d{2}-\\d{2})T(\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?))$", - "description": "Scheduling effective from time. Date-Time in ISO-8601 format without timezone suffix." - }, - "effectiveUntil": { - "type": "string", - "pattern": "^(?:(\\d{4}-\\d{2}-\\d{2})T(\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?))$", - "description": "Scheduling effective until time. Date-Time in ISO-8601 format without timezone suffix." - }, - "timeZone": { - "type": "string", - "description": "Scheduling time zone." - }, - "recurrences": { - "type": "array", - "description": "List of recurrences.", - "items": { - "$ref": "#/definitions/Recurrence" - } - } - } - }, - "Recurrence": { - "type": "object", - "description": "Recurrence object.", - "discriminator": "recurrenceType", - "required": [ - "recurrenceType" - ], - "properties": { - "recurrenceType": { - "type": "string", - "description": "Specifies when the recurrence should be applied.", - "enum": [ - "Daily", - "Weekly", - "Monthly" - ], - "x-ms-enum": { - "name": "RecurrenceType", - "modelAsString": true - } - }, - "startTime": { - "type": "string", - "description": "Start time for recurrence." - }, - "endTime": { - "type": "string", - "description": "End time for recurrence." - } - } - }, - "DailyRecurrence": { - "x-ms-discriminator-value": "Daily", - "type": "object", - "description": "Daily recurrence object.", - "required": [ - "startTime", - "endTime" - ], - "allOf": [ - { - "$ref": "#/definitions/Recurrence" - } - ] - }, - "WeeklyRecurrence": { - "x-ms-discriminator-value": "Weekly", - "type": "object", - "description": "Weekly recurrence object.", - "required": [ - "daysOfWeek" - ], - "allOf": [ - { - "$ref": "#/definitions/Recurrence" - } - ], - "properties": { - "daysOfWeek": { - "type": "array", - "description": "Specifies the values for weekly recurrence pattern.", - "items": { - "$ref": "#/definitions/DaysOfWeek" - } - } - } - }, - "MonthlyRecurrence": { - "x-ms-discriminator-value": "Monthly", - "type": "object", - "description": "Monthly recurrence object.", - "required": [ - "daysOfMonth" - ], - "allOf": [ - { - "$ref": "#/definitions/Recurrence" - } - ], - "properties": { - "daysOfMonth": { - "type": "array", - "description": "Specifies the values for monthly recurrence pattern.", - "items": { - "type": "integer", - "format": "int32" - } - } - } - }, - "DaysOfWeek": { - "type": "string", - "description": "Days of week.", - "enum": [ - "Sunday", - "Monday", - "Tuesday", - "Wednesday", - "Thursday", - "Friday", - "Saturday" - ], - "x-ms-enum": { - "name": "DaysOfWeek", - "modelAsString": true - } - }, - "AlertProcessingRule": { - "type": "object", - "description": "Alert processing rule object containing target scopes, conditions and scheduling logic.", - "allOf": [ - { - "$ref": "#/definitions/ManagedResource" - } - ], - "properties": { - "properties": { - "description": "Alert processing rule properties.", - "$ref": "#/definitions/AlertProcessingRuleProperties" - }, - "systemData": { - "description": "Alert processing rule system data.", - "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/systemData" - } - } - }, - "AlertProcessingRuleProperties": { - "type": "object", - "description": "Alert processing rule properties defining scopes, conditions and scheduling logic for alert processing rule.", - "required": [ - "scopes", - "actions" - ], - "properties": { - "scopes": { - "description": "Scopes on which alert processing rule will apply.", - "$ref": "#/definitions/Scopes" - }, - "conditions": { - "description": "Conditions on which alerts will be filtered.", - "$ref": "#/definitions/Conditions" - }, - "schedule": { - "description": "Scheduling for alert processing rule.", - "$ref": "#/definitions/Schedule" - }, - "actions": { - "type": "array", - "description": "Actions to be applied.", - "items": { - "$ref": "#/definitions/Action" - } - }, - "description": { - "type": "string", - "description": "Description of alert processing rule." - }, - "enabled": { - "type": "boolean", - "default": true, - "description": "Indicates if the given alert processing rule is enabled or disabled." - } - } - }, - "Action": { - "type": "object", - "description": "Action to be applied.", - "discriminator": "actionType", - "required": [ - "actionType" - ], - "properties": { - "actionType": { - "type": "string", - "description": "Action that should be applied.", - "enum": [ - "AddActionGroups", - "RemoveAllActionGroups", - "CorrelateAlerts" - ], - "x-ms-enum": { - "name": "actionType", - "modelAsString": true - } - } - } - }, - "AddActionGroups": { - "x-ms-discriminator-value": "AddActionGroups", - "type": "object", - "description": "Add action groups to alert processing rule.", - "required": [ - "actionGroupIds" - ], - "allOf": [ - { - "$ref": "#/definitions/Action" - } - ], - "properties": { - "actionGroupIds": { - "description": "List of action group Ids to add to alert processing rule.", - "type": "array", - "items": { - "type": "string" - } - } - } - }, - "RemoveAllActionGroups": { - "x-ms-discriminator-value": "RemoveAllActionGroups", - "type": "object", - "description": "Indicates if all action groups should be removed.", - "allOf": [ - { - "$ref": "#/definitions/Action" - } - ] - }, - "CorrelateAlerts": { - "x-ms-discriminator-value": "CorrelateAlerts", - "type": "object", - "description": "Add logic for alerts correlation.", - "required": [ - "correlateBy", - "correlationInterval", - "priority" - ], - "allOf": [ - { - "$ref": "#/definitions/Action" - } - ], - "properties": { - "correlateBy": { - "type": "array", - "description": "The list of conditions for the alerts correlations.", - "items": { - "$ref": "#/definitions/CorrelateBy" - }, - "x-ms-identifiers": [] - }, - "correlationInterval": { - "type": "string", - "description": "The required duration (in ISO8601 format) for the alerts correlation." - }, - "priority": { - "type": "integer", - "format": "int32", - "description": "The priority of this correlation." - }, - "notificationsForCorrelatedAlerts": { - "type": "string", - "default": "SuppressAlways", - "description": "Indicates how to handle child alerts notifications.", - "enum": [ - "NotifyAlways", - "SuppressAlways" - ], - "x-ms-enum": { - "name": "NotificationsForCorrelatedAlerts", - "modelAsString": true - } - }, - "correlationUpdates": { - "$ref": "#/definitions/CorrelationUpdates" - } - } - }, - "CorrelateBy": { - "type": "object", - "description": "The logic for the correlation.", - "properties": { - "field": { - "type": "string", - "description": "The JPath of the property that the alerts should be correlated by." - } - } - }, - "CorrelationUpdates": { - "type": "object", - "description": "Defines the updates to be applied for correlation.", - "properties": { - "updateType": { - "type": "string", - "description": "The type of update that needs to be performed.", - "default": "timeBased", - "enum": [ - "timeBased" - ], - "x-ms-enum": { - "name": "UpdateType", - "modelAsString": true - } - }, - "updateInterval": { - "type": "string", - "description": "The update interval for notification updates in ISO8601 format." - }, - "actionGroups": { - "type": "array", - "description": "The action group ids.", - "items": { - "type": "string" - } - } - }, - "required": [ - "updateType", - "updateInterval", - "actionGroups" - ] - }, - "AlertProcessingRulesList": { - "type": "object", - "description": "List of alert processing rules.", - "properties": { - "nextLink": { - "type": "string", - "description": "URL to fetch the next set of alert processing rules." - }, - "value": { - "type": "array", - "description": "List of alert processing rules.", - "items": { - "$ref": "#/definitions/AlertProcessingRule" - } - } - } - }, - "PatchProperties": { - "description": "Alert processing rule properties supported by patch.", - "properties": { - "enabled": { - "type": "boolean", - "description": "Indicates if the given alert processing rule is enabled or disabled." - } - } - }, - "PatchObject": { - "description": "Data contract for patch.", - "properties": { - "properties": { - "x-ms-client-flatten": true, - "description": "Properties supported by patch operation.", - "$ref": "#/definitions/PatchProperties" - }, - "tags": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "Tags to be updated." - } - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json deleted file mode 100644 index 720b541f15c4..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json +++ /dev/null @@ -1,93 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "AddActionGroupToSubscription", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" - ] - } - ], - "description": "Add ActionGroup1 to all alerts in the subscription", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" - ] - } - ], - "description": "Add ActionGroup1 to all alerts in the subscription", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupToSubscription", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupToSubscription", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" - ] - } - ], - "description": "Add ActionGroup1 to all alerts in the subscription", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupToSubscription", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupToSubscription", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation.json deleted file mode 100644 index 9722d8f855b2..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation.json +++ /dev/null @@ -1,108 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "CorrelateAlerts", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways" - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways" - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "CorrelateAlerts", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways" - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "CorrelateAlerts", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation_with_correlation_updates.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation_with_correlation_updates.json deleted file mode 100644 index c4f6125919aa..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation_with_correlation_updates.json +++ /dev/null @@ -1,132 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "CorrelateAlerts", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways", - "correlationUpdates": { - "updateType": "timeBased", - "updateInterval": "PT15M", - "actionGroups": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways", - "correlationUpdates": { - "updateType": "timeBased", - "updateInterval": "PT15M", - "actionGroups": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "CorrelateAlerts", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2021-02-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2021-02-13T16:15:34Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "CorrelateAlerts", - "correlateBy": [ - { - "field": "essentials.alertRule" - } - ], - "correlationInterval": "PT30M", - "priority": 50, - "notificationsForCorrelatedAlerts": "SuppressAlways", - "correlationUpdates": { - "updateType": "timeBased", - "updateInterval": "PT15M", - "actionGroups": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - } - ], - "description": "Correlate Alerts Example.", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "CorrelateAlerts", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json deleted file mode 100644 index 182f0188b0ee..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_two_action_groups_all_Sev0_Sev1_two_resource_groups.json +++ /dev/null @@ -1,129 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "AddActionGroupsBySeverity", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "sev0", - "sev1" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - ], - "description": "Add AGId1 and AGId2 to all Sev0 and Sev1 alerts in these resourceGroups", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-13T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "sev0", - "sev1" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - ], - "description": "Add AGId1 and AGId2 to all Sev0 and Sev1 alerts in these resourceGroups", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupsBySeverity", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupsBySeverity", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-13T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "sev0", - "sev1" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", - "/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" - ] - } - ], - "description": "Add AGId1 and AGId2 to all Sev0 and Sev1 alerts in these resourceGroups", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupsBySeverity", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "AddActionGroupsBySeverity", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json deleted file mode 100644 index bdfce5606a0a..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_from_specific_alert_rule.json +++ /dev/null @@ -1,111 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsSpecificAlertRule", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "conditions": [ - { - "field": "AlertRuleId", - "operator": "Equals", - "values": [ - "/subscriptions/suubId1/resourceGroups/Rgid2/providers/microsoft.insights/activityLogAlerts/RuleName" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Removes all ActionGroups from all Alerts that fire on above AlertRule", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "conditions": [ - { - "field": "AlertRuleId", - "operator": "Equals", - "values": [ - "/subscriptions/suubId1/resourceGroups/Rgid2/providers/microsoft.insights/activityLogAlerts/RuleName" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Removes all ActionGroups from all Alerts that fire on above AlertRule", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsSpecificAlertRule", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsSpecificAlertRule", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "conditions": [ - { - "field": "AlertRuleId", - "operator": "Equals", - "values": [ - "/subscriptions/suubId1/resourceGroups/Rgid2/providers/microsoft.insights/activityLogAlerts/RuleName" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Removes all ActionGroups from all Alerts that fire on above AlertRule", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsSpecificAlertRule", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsSpecificAlertRule", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json deleted file mode 100644 index e3966fd2a737..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_outside_business_hours.json +++ /dev/null @@ -1,135 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsOutsideBusinessHours", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "Eastern Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "17:00:00", - "endTime": "09:00:00" - }, - { - "recurrenceType": "Weekly", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups outside business hours", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "Eastern Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "17:00:00", - "endTime": "09:00:00" - }, - { - "recurrenceType": "Weekly", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups outside business hours", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsOutsideBusinessHours", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsOutsideBusinessHours", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "Eastern Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "17:00:00", - "endTime": "09:00:00" - }, - { - "recurrenceType": "Weekly", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups outside business hours", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsOutsideBusinessHours", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsOutsideBusinessHours", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json deleted file mode 100644 index 3be69fef8b72..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_recurring_maintenance_window.json +++ /dev/null @@ -1,156 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsRecurringMaintenance", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "TargetResourceType", - "operator": "Equals", - "values": [ - "microsoft.compute/virtualmachines" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "India Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "22:00:00", - "endTime": "04:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups from all Vitual machine Alerts during the recurring maintenance", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "TargetResourceType", - "operator": "Equals", - "values": [ - "microsoft.compute/virtualmachines" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "India Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "22:00:00", - "endTime": "04:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups from all Vitual machine Alerts during the recurring maintenance", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsRecurringMaintenance", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsRecurringMaintenance", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-11T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1", - "/subscriptions/subId1/resourceGroups/RGId2" - ], - "conditions": [ - { - "field": "TargetResourceType", - "operator": "Equals", - "values": [ - "microsoft.compute/virtualmachines" - ] - } - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "timeZone": "India Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "22:00:00", - "endTime": "04:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "description": "Remove all ActionGroups from all Vitual machine Alerts during the recurring maintenance", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsRecurringMaintenance", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsRecurringMaintenance", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json deleted file mode 100644 index 485cababf062..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_remove_all_action_groups_specific_VM_one-off_maintenance_window.json +++ /dev/null @@ -1,99 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "subId1", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "RemoveActionGroupsMaintenanceWindow", - "alertProcessingRule": { - "location": "Global", - "tags": {}, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1/providers/Microsoft.Compute/virtualMachines/VMName" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "effectiveFrom": "2021-04-15T18:00:00", - "effectiveUntil": "2021-04-15T20:00:00", - "timeZone": "Pacific Standard Time" - }, - "description": "Removes all ActionGroups from all Alerts on VMName during the maintenance window", - "enabled": true - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T20:13:29Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1/providers/Microsoft.Compute/virtualMachines/VMName" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "effectiveFrom": "2021-04-15T18:00:00", - "effectiveUntil": "2021-04-15T20:00:00", - "timeZone": "Pacific Standard Time" - }, - "description": "Removes all ActionGroups from all Alerts on VMName during the maintenance window", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsMaintenanceWindow", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsMaintenanceWindow", - "location": "Global", - "tags": {} - } - }, - "201": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T20:13:29Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/subId1/resourceGroups/RGId1/providers/Microsoft.Compute/virtualMachines/VMName" - ], - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "schedule": { - "effectiveFrom": "2021-04-15T18:00:00", - "effectiveUntil": "2021-04-15T20:00:00", - "timeZone": "Pacific Standard Time" - }, - "description": "Removes all ActionGroups from all Alerts on VMName during the maintenance window", - "enabled": true - }, - "id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/RemoveActionGroupsMaintenanceWindow", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "RemoveActionGroupsMaintenanceWindow", - "location": "Global", - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Delete.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Delete.json deleted file mode 100644 index 686e3126fbe6..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Delete.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "DailySuppression" - }, - "responses": { - "200": {}, - "204": {} - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_GetById.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_GetById.json deleted file mode 100644 index 14867df25384..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_GetById.json +++ /dev/null @@ -1,96 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "DailySuppression" - }, - "responses": { - "200": { - "body": { - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/DailySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "DailySuppression", - "location": "Global", - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "MonitorCondition", - "operator": "Equals", - "values": [ - "Fired" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-01-10T22:05:09", - "effectiveUntil": "2018-12-10T22:05:09", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "06:00:00", - "endTime": "14:00:00" - }, - { - "recurrenceType": "Weekly", - "startTime": "10:00:00", - "endTime": "20:00:00", - "daysOfWeek": [ - "Saturday", - "Sunday" - ] - } - ] - }, - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "actiongGroup1", - "actiongGroup2" - ] - } - ], - "description": "Alert processing rule on resource group for daily and weekly scheduling", - "enabled": true - }, - "tags": {} - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_List_ResourceGroup.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_List_ResourceGroup.json deleted file mode 100644 index b672d112e52f..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_List_ResourceGroup.json +++ /dev/null @@ -1,135 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg" - }, - "responses": { - "200": { - "body": { - "nextLink": "https://management.azure.com:443/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules?api-version=2023-05-01-preview&ctoken=%2bRID%3aPlwOAPHEGwB9UwEAAAAgCw%3d%3d%23RT%3a2%23TRC%3a500%23RTD%3aqtQyMDE4LTA2LTEyVDE1OjEyOjE1", - "value": [ - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-09-12T06:00:00", - "effectiveUntil": "2018-09-20T14:00:00", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "06:00:00", - "endTime": "14:00:00" - } - ] - }, - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Alert processing rule on resource group for daily suppression", - "enabled": true - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/DailySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "DailySuppression", - "location": "Global", - "tags": {} - }, - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.Compute/VirtualMachines/testResource" - ], - "conditions": [ - { - "field": "MonitorCondition", - "operator": "Equals", - "values": [ - "Fired" - ] - }, - { - "field": "Description", - "operator": "Contains", - "values": [ - "Percentage CPU greater than 80%", - "Metric alert on resource foo" - ] - }, - { - "field": "AlertContext", - "operator": "DoesNotContain", - "values": [ - "testresource", - "foo" - ] - } - ], - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.insights/actiongroups/testAG" - ] - } - ], - "description": "Alert processing rule on resource group for sending email", - "enabled": true - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/WeeklySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "WeeklySuppression", - "location": "Global", - "tags": {} - } - ] - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_List_Subscription.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_List_Subscription.json deleted file mode 100644 index f173f58f4454..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_List_Subscription.json +++ /dev/null @@ -1,126 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d" - }, - "responses": { - "200": { - "body": { - "nextLink": "https://management.azure.com:443/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/providers/Microsoft.AlertsManagement/actionRules?api-version=2023-05-01-preview&ctoken=%2bRID%3aPlwOAPHEGwB9UwEAAAAgCw%3d%3d%23RT%3a2%23TRC%3a500%23RTD%3aqtQyMDE4LTA2LTEyVDE1OjEyOjE1", - "value": [ - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-01-10T22:05:09", - "effectiveUntil": "2018-12-10T22:05:09", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Daily", - "startTime": "06:00:00", - "endTime": "14:00:00" - } - ] - }, - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Alert processing rule on resource group for daily suppression", - "enabled": true - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/DailySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "DailySuppression", - "location": "Global", - "tags": {} - }, - { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.Compute/VirtualMachines/testResource" - ], - "conditions": [ - { - "field": "MonitorCondition", - "operator": "Equals", - "values": [ - "Fired" - ] - }, - { - "field": "Description", - "operator": "Contains", - "values": [ - "Percentage CPU greater than 80%", - "Metric alert on resource foo" - ] - } - ], - "description": "Alert processing rule on resource group for adding action group", - "enabled": true, - "actions": [ - { - "actionType": "AddActionGroups", - "actionGroupIds": [ - "actiongGroup1" - ] - } - ] - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/WeeklySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "WeeklySuppression", - "location": "Global", - "tags": {} - } - ] - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Patch.json b/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Patch.json deleted file mode 100644 index 534ffc1548c1..000000000000 --- a/specification/alertsmanagement/resource-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/examples/AlertProcessingRules_Patch.json +++ /dev/null @@ -1,92 +0,0 @@ -{ - "parameters": { - "api-version": "2024-03-01-preview", - "subscriptionId": "1e3ff1c0-771a-4119-a03b-be82a51e232d", - "resourceGroupName": "alertscorrelationrg", - "alertProcessingRuleName": "WeeklySuppression", - "alertProcessingRulePatch": { - "tags": { - "key1": "value1", - "key2": "value2" - }, - "properties": { - "enabled": false - } - } - }, - "responses": { - "200": { - "body": { - "systemData": { - "createdBy": "abc@microsoft.com", - "createdByType": "User", - "createdAt": "2018-06-12T22:05:09Z", - "lastModifiedBy": "xyz@microsoft.com", - "lastModifiedByType": "User", - "lastModifiedAt": "2018-06-12T22:05:09Z" - }, - "properties": { - "scopes": [ - "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg" - ], - "conditions": [ - { - "field": "Severity", - "operator": "Equals", - "values": [ - "Sev0", - "Sev2" - ] - }, - { - "field": "MonitorService", - "operator": "Equals", - "values": [ - "Platform", - "Application Insights" - ] - }, - { - "field": "TargetResourceType", - "operator": "NotEquals", - "values": [ - "Microsoft.Compute/VirtualMachines" - ] - } - ], - "schedule": { - "effectiveFrom": "2018-12-10T22:05:09", - "effectiveUntil": "2018-12-05T22:05:09", - "timeZone": "Pacific Standard Time", - "recurrences": [ - { - "recurrenceType": "Weekly", - "startTime": "06:00:00", - "endTime": "14:00:00", - "daysOfWeek": [ - "Tuesday", - "Friday" - ] - } - ] - }, - "actions": [ - { - "actionType": "RemoveAllActionGroups" - } - ], - "description": "Alert processing rule on resource group for weekly suppression", - "enabled": false - }, - "id": "/subscriptions/1e3ff1c0-771a-4119-a03b-be82a51e232d/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/WeeklySuppression", - "type": "Microsoft.AlertsManagement/actionRules", - "name": "WeeklySuppression", - "location": "Global", - "tags": { - "key1": "value1", - "key2": "value2" - } - } - } - } -} diff --git a/specification/alertsmanagement/resource-manager/readme.md b/specification/alertsmanagement/resource-manager/readme.md index ec60ffba02b5..6cf150503fb0 100644 --- a/specification/alertsmanagement/resource-manager/readme.md +++ b/specification/alertsmanagement/resource-manager/readme.md @@ -47,18 +47,6 @@ openapi-type: arm tag: package-2023-03 ``` -### Tag: package-preview-2024-03 - -These settings apply only when `--tag=package-preview-2024-03` is specified on the command line. - -```yaml $(tag) == 'package-preview-2024-03' -input-file: - - Microsoft.AlertsManagement/preview/2024-03-01-preview/AlertProcessingRules.json -suppressions: - - code: OperationsAPIImplementation - from: AlertProcessingRules.json - reason: Aleady implemented in AlertsManagement.json. -``` ### Tag: package-preview-2024-01 These settings apply only when `--tag=package-preview-2024-01` is specified on the command line. @@ -83,14 +71,6 @@ These settings apply only when `--tag=package-preview-2023-07` is specified on t input-file: - Microsoft.AlertsManagement/preview/2023-07-12-preview/AlertsManagement.json ``` -### Tag: package-preview-2023-05 - -These settings apply only when `--tag=package-preview-2023-05` is specified on the command line. - -```yaml $(tag) == 'package-preview-2023-05' -input-file: - - Microsoft.AlertsManagement/preview/2023-05-01-preview/AlertProcessingRules.json -``` ### Tag: package-preview-2023-04 These settings apply only when `--tag=package-preview-2023-04` is specified on the command line. @@ -117,7 +97,7 @@ input-file: - Microsoft.AlertsManagement/preview/2024-01-01-preview/AlertsManagement.json - Microsoft.AlertsManagement/preview/2019-05-05-preview/SmartGroups.json - Microsoft.AlertsManagement/preview/2023-08-01-preview/AlertRuleRecommendations.json - - Microsoft.AlertsManagement/preview/2024-03-01-preview/AlertProcessingRules.json + - Microsoft.AlertsManagement/preview/2021-08-08-preview/AlertProcessingRules.json ``` ### Tag: package-2021-08