Azure Monitor · Arazzo Workflow

Azure Monitor Action Group With Metric Alert

Version 1.0.0

Create an action group, attach it to a new classic metric alert rule, and confirm the rule.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub Application InsightsCloudLogsMetricsMonitoringObservabilityArazzoWorkflows

Provider

microsoft-azure-monitor

Workflows

provision-action-group-and-alert
Create an action group then a classic metric alert rule that targets it.
Creates an action group with an email receiver, then creates a classic metric alert rule whose email action notifies that receiver, and reads the rule back to confirm provisioning.
3 steps inputs: actionGroupName, emailAddress, groupShortName, location, monitoredResourceUri, receiverName, resourceGroupName, ruleName, subscriptionId outputs: actionGroupId, alertRuleId, isEnabled
1
createActionGroup
Create or update the action group with a single email receiver that will be notified when alerts fire.
2
createAlertRule
Create or update a classic metric alert rule that monitors the supplied resource and is enabled on creation.
3
confirmAlertRule
Read the alert rule back to confirm it was created and capture its enabled state and last updated time.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Azure Monitor Action Group With Metric Alert
  summary: Create an action group, attach it to a new classic metric alert rule, and confirm the rule.
  description: >-
    The core alerting bootstrap for Azure Monitor. The workflow first creates or
    updates an action group that defines who is notified, then creates a classic
    metric alert rule whose action references that action group, and finally
    reads the rule back to confirm it was provisioned. Every step spells out its
    ARM request body inline so the flow can be read and executed without opening
    the underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: actionGroupsApi
  url: ../openapi/microsoft-azure-monitor-action-groups-api-openapi.yml
  type: openapi
- name: alertRulesApi
  url: ../openapi/microsoft-azure-monitor-alert-rules-api-openapi.yml
  type: openapi
workflows:
- workflowId: provision-action-group-and-alert
  summary: Create an action group then a classic metric alert rule that targets it.
  description: >-
    Creates an action group with an email receiver, then creates a classic
    metric alert rule whose email action notifies that receiver, and reads the
    rule back to confirm provisioning.
  inputs:
    type: object
    required:
    - subscriptionId
    - resourceGroupName
    - actionGroupName
    - groupShortName
    - receiverName
    - emailAddress
    - ruleName
    - location
    - monitoredResourceUri
    properties:
      subscriptionId:
        type: string
        description: The ID of the target subscription.
      resourceGroupName:
        type: string
        description: The name of the resource group.
      actionGroupName:
        type: string
        description: The name of the action group to create or update.
      groupShortName:
        type: string
        description: The short name of the action group (max 12 characters).
      receiverName:
        type: string
        description: The name of the email receiver inside the action group.
      emailAddress:
        type: string
        description: The email address that should receive notifications.
      ruleName:
        type: string
        description: The name of the classic metric alert rule.
      location:
        type: string
        description: The Azure location for the action group and alert rule resources.
      monitoredResourceUri:
        type: string
        description: The resource identifier the alert rule monitors.
  steps:
  - stepId: createActionGroup
    description: >-
      Create or update the action group with a single email receiver that will
      be notified when alerts fire.
    operationId: ActionGroups_CreateOrUpdate
    parameters:
    - name: subscriptionId
      in: path
      value: $inputs.subscriptionId
    - name: resourceGroupName
      in: path
      value: $inputs.resourceGroupName
    - name: actionGroupName
      in: path
      value: $inputs.actionGroupName
    - name: api-version
      in: query
      value: '2022-06-01'
    requestBody:
      contentType: application/json
      payload:
        location: $inputs.location
        properties:
          groupShortName: $inputs.groupShortName
          enabled: true
          emailReceivers:
          - name: $inputs.receiverName
            emailAddress: $inputs.emailAddress
            useCommonAlertSchema: true
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      actionGroupId: $response.body#/id
      actionGroupName: $response.body#/name
  - stepId: createAlertRule
    description: >-
      Create or update a classic metric alert rule that monitors the supplied
      resource and is enabled on creation.
    operationId: AlertRules_CreateOrUpdate
    parameters:
    - name: resourceGroupName
      in: path
      value: $inputs.resourceGroupName
    - name: ruleName
      in: path
      value: $inputs.ruleName
    - name: subscriptionId
      in: path
      value: $inputs.subscriptionId
    - name: api-version
      in: query
      value: '2016-03-01'
    requestBody:
      contentType: application/json
      payload:
        location: $inputs.location
        properties:
          name: $inputs.ruleName
          description: Classic metric alert rule provisioned alongside its action group.
          isEnabled: true
          condition:
            odata.type: Microsoft.Azure.Management.Insights.Models.ThresholdRuleCondition
            dataSource:
              odata.type: Microsoft.Azure.Management.Insights.Models.RuleMetricDataSource
              resourceUri: $inputs.monitoredResourceUri
          actions:
          - odata.type: Microsoft.Azure.Management.Insights.Models.RuleEmailAction
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      alertRuleId: $response.body#/id
      alertRuleName: $response.body#/name
  - stepId: confirmAlertRule
    description: >-
      Read the alert rule back to confirm it was created and capture its enabled
      state and last updated time.
    operationId: AlertRules_Get
    parameters:
    - name: resourceGroupName
      in: path
      value: $inputs.resourceGroupName
    - name: ruleName
      in: path
      value: $inputs.ruleName
    - name: subscriptionId
      in: path
      value: $inputs.subscriptionId
    - name: api-version
      in: query
      value: '2016-03-01'
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      isEnabled: $response.body#/properties/isEnabled
      lastUpdatedTime: $response.body#/properties/lastUpdatedTime
  outputs:
    actionGroupId: $steps.createActionGroup.outputs.actionGroupId
    alertRuleId: $steps.createAlertRule.outputs.alertRuleId
    isEnabled: $steps.confirmAlertRule.outputs.isEnabled

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/microsoft-azure-monitor-action-group-with-metric-alert-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.