• Get started
  • Documentation

Integrate Opsgenie with Microsoft Azure AutoScale

Microsoft Azure logo

Overview

What does the integration offer?

The Azure Autoscale integration sends Azure alerts to Opsgenie API with detailed information. Opsgenie acts as a dispatcher for the alerts generated by Azure Autoscale. Opsgeniedetermines the right people to notify based on on-call schedules and escalations and notifies via email, text messages (SMS), phone calls, and push notifications.

How does the integration work?

When an alert is created in Azure Autoscale, an alert is automatically created in Opsgenie through the integration.

Set up the integration

Azure Autoscale is an API-based integration. Setting it up involves the following steps:

  • Add an Azure Autoscale integration in Opsgenie

  • Configure the integration in Azure Autoscale

Add an Azure Autoscale integration

If you're using Opsgenie's Free or Essentials plan or if you’re using Opsgenie with Jira Service Management's Standard plan, you can add this integration from your team dashboard only. The Integrations page under Settings is not available in your plan.

  1. Go to Teams and select your team.

  2. Select Integrations on the left navigation and then select Add integration.

Adding the integration from your team dashboard will make your team the owner of the integration. This means Opsgenie will assign the alerts received through this integration to your team only. Follow the rest of the steps in this section to set up the integration.

To add an Azure Autoscale integration in Opsgenie:

  1. Go to Settings > Integrations.

  2. Select Add integration.

  3. Run a search and select “Azure AutoScale”.

  4. On the next screen, enter a name for the integration.

  5. Optional: Select a team in Assignee team if you want a specific team to receive alerts from the integration.

  6. Select Continue.
    The integration is saved at this point.

  7. Expand the Steps to configure the integration section and copy the integration URL, which includes Opsgenie endpoint and the API key.
    You will use this URL while configuring the integration in Azure Autoscale later.

  8. Select Turn on integration.
    The rules you create for the integration will work only if you turn on the integration.

Configure the integration in Azure

1. In the Azure Portal, select Monitor.

2. In the SETTINGS section, select AutoScale.

3. Select the resource for which you want to generate alerts.

4. Enable AutoScale.

5. Configure your autoscale settings.

6. Paste the URL you copied while adding the integration in Opsgenie into Webhook in the Notify tab.

Microsoft Azure AutoScale settings

7. Save the rule.

Sample payload sent from Azure Autoscale

Create alert payload (in JSON format)

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 { "version": "1.0", "status": "Activated", "operation": "Scale In", "context": { "timestamp": "2016-03-11T07:31:04.5834118Z", "id": "/subscriptions/s1/resourceGroups/rg1/providers/microsoft.insights/autoscalesettings/myautoscaleSetting", "name": "myautoscaleSetting", "details": "Autoscale successfully started scale operation for resource 'MyCSRole' from capacity '3' to capacity '2'", "subscriptionId": "s1", "resourceGroupName": "rg1", "resourceName": "MyCSRole", "resourceType": "microsoft.classiccompute/domainnames/slots/roles", "resourceId": "/subscriptions/s1/resourceGroups/rg1/providers/microsoft.classicCompute/domainNames/myCloudService/slots/Production/roles/MyCSRole", "portalLink": "https://portal.azure.com/#resource/subscriptions/s1/resourceGroups/rg1/providers/microsoft.classicCompute/domainNames/myCloudService", "oldCapacity": "3", "newCapacity": "2" }, "properties": { "key1": "value1", "key2": "value2" } }

Payload parsed by Opsgenie (in JSON format)

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 { "version":"1.0", "status":"Activated", "operation":"Scale In", "timestamp":"2016-03-11T07:31:04.5834118Z", "id":"/subscriptions/s1/resourceGroups/rg1/providers/microsoft.insights/autoscalesettings/myautoscaleSetting", "name":"myautoscaleSetting", "details":"Autoscale successfully started scale operation for resource 'MyCSRole' from capacity '3' to capacity '2'", "subscription_id":"s1", "resource_group_name":"rg1", "resource_name":"MyCSRole", "resource_type":"microsoft.classiccompute/domainnames/slots/roles", "resource_id":"/subscriptions/s1/resourceGroups/rg1/providers/microsoft.classicCompute/domainNames/myCloudService/slots/Production/roles/MyCSRole", "portal_link":"https://portal.azure.com/#resource/subscriptions/s1/resourceGroups/rg1/providers/microsoft.classicCompute/domainNames/myCloudService", "old_capacity":"3", "new_capacity":"2", "key1":"value1", "key2":"value2" }

Still need help?

The Atlassian Community is here for you.