
AWS Enterprise or Business Support on all accounts in your AWS Organizations.
The following prerequisites are necessary for this solution: The Lambda function formats a message, decrypts the webhook URL, and posts a well-formatted message to Amazon Chime or Slack.The Lambda function looks for an existing entry in the DynamoDB table by comparing the JSON response Health Event ARNs and the LastUpdatedTime.The AWS Health Organizational View API goes out to every account in the organization and returns a JSON response.A CloudWatch Scheduled Rule triggers a Lambda function every 60 seconds to query the AWS Health Organizational View API.
A webhook URL is entered into an AWS CloudFormation template that is then encrypted using AWS KMS. The following diagram illustrates the workflow used to query the AWS Health API and posts to Amazon Chime or Slack. The webhook URL is encrypted via a second Lambda function using AWS Key Management Service, and is only decrypted when posting to Amazon Chime or Slack. If there is a new event or an existing event has been updated, the Lambda function posts the event to an Amazon Chime room or a Slack channel using the webhook URL. The Lambda function verifies if the AWS Health Event is new or has been updated by comparing the event’s last updated time with entries in an Amazon DynamoDB table. The described solution uses an Amazon CloudWatch Scheduled Rule which triggers an AWS Lambda function to check the AWS Health Organizational View API every 60 seconds. If there is an ongoing AWS Health issue, the issue updates its status-such as open, investigating, or closed-throughout the event. LastUpdatedTime is the last time a Health event ARN was updated by AWS. It is presented in the following format: arn:aws:health:region::event/SERVICE_ISSUE_ID. Health Event ARN is the Amazon Resource Name of an AWS Health Event. Both Amazon Chime and Slack can create a unique webhook URL to use specifically for your chat room or channel. Webhook URL is a public URL that can be used to send HTTP Post requests. The following terms are used in this post: Solution overviewĪWS Health Organizational View Alerts (AHOVA) is an automated notification tool for sending well-formatted Alerts to your Amazon Chime room or Slack channel. Recently, the team behind AWS Health API (available to AWS Business/Enterprise Support customers) released AWS Health Organizational View, which allows you to aggregate all AWS Health events across your AWS Organizations. Receiving notifications for AWS Health events can be done in multiple ways depending on your desired platform, from email notifications with Amazon SNS to account-specific chat notifications with AWS Chatbot. There’s now a much easier solution! Please see our blog post on AWS Health Aware – Customize AWS Health Alerts for Organizational and Personal AWS Accounts.