I've recently started using application insights with a web api.
It will be really helpful to configure app insights to post error messages in a slack channel.
I've seen there is a slack connector but I am not sure how to use it, my guess is that this can be solved with the slack connector and a azure logic app, any tips? tutorials?
Application Insights is enabled through either Auto-Instrumentation (agent) or by adding the Application Insights SDK to your application code. Many languages are supported and the applications could be on Azure, on-premises, or hosted by another cloud.
Select Application Insights in the left pane for your app service. Then select Enable. Create a new resource or select an existing Application Insights resource for this application. When you select OK to create a new resource, you're prompted to Apply monitoring settings.
You may have a look at this link: https://github.com/Azure/azure-quickstart-templates/tree/master/demos/alert-to-slack-with-logic-app. I followed the instruction and it worked for me.
The tricky part is you need to click the "Deploy to Azure" button on this link page. It would redirect you to Azure Portal, and you will need to specify which channel you want the alert message to be sent e.g. #somechannel. Don't use direct message like @yourname, it has some problem with that and the logic app couldn't deploy for me.
Then you just follow the instruction to find the deployed logic app and authenticate it by logging into slack. And you also need get the logic app URI from the deployment output as in the instruction. Once you put the URI into the alert webhook, you are ready to go!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With