Set an Azure Alert for a Web App

This IT Pro Challenge lab shows learners fundamental web application concepts and Microsoft Azure Resource group services. Learners will use the Microsoft Azure Portal and an existing Azure Resource Group to create an action group, add an email alert action and a webhook action for the action group, and create an alert rule.

45 minutes
Join over 3 million cybersecurity professionals advancing their career
Sign up with
Required fields are marked with an *

Already have an account? Sign In »


In this IT Pro Challenge, learners will understand how to use the Microsoft Azure Portal and Microsoft Azure Resource group services to create an action group with both an email alert and webhook action. Learners will also create a metric-based alert rule that triggers an alert for the action group and use a web application to verify that the alert they created triggers based on a specific server action. The skills acquired in this lab are beneficial for the role of a network or system administrator.


The scenario for this lab is that you are a system administrator. Your company provides web hosting services for its clients, and your job is to configure alerts for a web application. To accomplish this, you will create an alert action group with an email action that is triggered by a webhook action. You will then define an alert rule for the web application and, as a proof of concept, trigger the alert you created and verify that it “fired,” and sent an email to you.

A webhook action is an automated call from a website to a server triggered by an alert action. An example of a webhook action is if a user signs up for a website (webhook action) and is then automatically sent a welcome email (email action).

Create an action group

To begin the lab, you will sign into the Azure Portal, navigate to the Alerts page of the provided Web App, and add an action group (Alert Challenge) to the provided resource group. You will then assign the action group a short name that is 11 characters or less, add an Email/SMS/Push/Voice action (email) that uses your email address, and then add a Webhook action (webhook) that calls https://[Web App Name] (provided with lab).

When you are finished, the Alert Challenge action group should have an email and a webhook action.

Create an alert rule

Now, you will return to the Alerts page for the provided Web App and add an alert rule with the Condition set as follows: Select Http Server Errors and set the alert to trigger if the total error count > 10. Then, select the Alert Challenge action group that you created in the previous step of the lab, name the new alert rule (Server Error Alert), enter a description, and save the rule. When you’re finished, you will have a metric-based alert rule that triggers based on the number of server errors.

Verify an alert

Finally, you need to verify the alert that you just created by navigating to the homepage of the Web App, selecting the Generate Activity button, and waiting for the alert to get triggered. If you configured the rule properly, you should get an email alert when the alert triggers. After you receive the message, select the Check Alert messages button, and you should see the raw alert message. If you configured everything properly, you would see the Server Error Alert and webhook action have been triggered.

Summary Conclusion

By taking this lab, you will learn how to create an action group, create a metric-based alert, and trigger the alert you created.