I'm currently using CloudWatch Alerts that send notifications through SNS to a Slack channel via its email address. The problem is that these alerts come through as long, unreadable emails, which makes them hard to process. Does anyone have suggestions for making these alerts more visually appealing or easier to read? I'm open to both ready-made solutions and custom setups!
5 Answers
If you're looking for a simple solution, using EventBridge to send messages directly to Slack can give you formatted output. It’s worth exploring if you want to avoid more complex setups!
Remember that SNS is primarily intended for event notifications, and while email is an option, it’s not designed for fancy formatting. If you need a prettier solution, an intermediary service would be necessary to process these notifications.
We’ve also gone with a Lambda function to format our alerts nicely before sending them out. A bit of extra work, but it does the trick! Though, I get it—sometimes simpler is better, just don’t forget to manage your costs.
One option is to replace the SNS email alerts with a chatbot setup instead. You can check out AWS Chatbot documentation for help on getting started with this. It can greatly enhance how notifications are displayed in Slack!
Consider using a Lambda function between SNS and Slack. This way, you can format the alerts to look better before they reach your Slack channel. It’s worked great for me—it formats the SNS event nicely and sends it to Slack’s webhook!
It’s surprising that someone would question why to improve these notifications, but I think it’s the best approach!
I completely agree! We do the same with our Lambda; it’s straightforward and keeps things neat.