About webhook integrations
Third-party applications can be configured to allow inbound data requests by exposing webhooks and using them to listen for incoming events. The Hybrid Cloud Console integrations service uses this functionality to send events and associated data from each service.
You can configure the Hybrid Cloud Console notifications service to send POST messages to those third-party application webhook endpoints. For example, you can configure the Hybrid Cloud Console to automatically forward events triggered when a new Advisor recommendation is found. The event and its data are sent as an HTTP POST message to the third-party application on its incoming webhook endpoint.
After you configure the endpoints in the notifications service, you can subscribe to a stream of Hybrid Cloud Console events and automatically forward that stream to the webhooks of your choice. Each event contains additional metadata, which you can use to process the event, for example, to perform specific actions or trigger responses, as part of your operational workflow. You configure the implementation and data handling within your application.
If you have any issues with integrating the Hybrid Cloud Console with webhooks, contact Red Hat for support. To open a Red Hat support case directly from the Hybrid Cloud Console:
- Click Help (the ? icon) to open the help panel.
- Select the My support cases tab.
- Click Open a support case and add information about the issue.
Configure a webhook integration Copy linkLink copied!
For third-party applications that do not have a native Hybrid Cloud Console integration available, configure a webhook integration to receive event notifications from the Hybrid Cloud Console in your chosen application.
Before you begin Copy linkLink copied!
- You have configured a webhook in your third-party application.
- You have Organization Administrator or Notifications administrator permissions for the Hybrid Cloud Console.
Procedure Copy linkLink copied!
What to do next Copy linkLink copied!
Verify your configuration:
Create a test notification to confirm you have correctly connected your application to the Hybrid Cloud Console:
- Next to your integration on the Integrations > Webhooks page, click the options icon (⋮) and then click Test.
- In the Integration Test screen, enter a message and click Send. If you leave the field empty, the Hybrid Cloud Console sends a default message.
- Open your third-party application and check for the message sent from the Hybrid Cloud Console.
- In the Hybrid Cloud Console, go to Notifications > Event Log and check that the Integration: Webhook event is listed with a green label.
Create the behavior group for a webhook integration Copy linkLink copied!
A behavior group defines which notifications will be sent to external services when a specific event is received by the notifications service. You can link events from any Red Hat Hybrid Cloud Console service to your behavior group.
Before you begin Copy linkLink copied!
- You are logged in to the Hybrid Cloud Console as an Organization Administrator or as a user with Notifications administrator permissions.
Note You cannot log in to the Hybrid Cloud Console with your email address unless your email address is the same as your Red Hat login. For more information, see ../get-started/access-hcc.dita#finding-login. - A webhook integration is configured. For configuration steps, see Configure a webhook integration.
Procedure Copy linkLink copied!
- In the Hybrid Cloud Console, navigate to Settings > Notifications.
- Under Notifications, select Configure Events.
- Select the application bundle tab you want to configure event notification behavior for: Red Hat Enterprise Linux, Console, or OpenShift.
- Click the Behavior Groups tab.
- Click Create new group to open the Create behavior group wizard.
- Type a name for the behavior group and click Next.
- In the Actions and Recipients step, select Integration: Webhook from the Actions drop-down list.
- From the Recipient drop-down list, select the name of the webhook integration you created and click Next.
- In the Associate event types step, select one or more events for which you want to send notifications (for example, Policies: Policy triggered) and click Next.
- Review your behavior group settings and click Finish. The new behavior group appears on the Notifications > Configure Events page in the Behavior Groups tab.
What to do next Copy linkLink copied!
Verify your integration:
- Create an event that will trigger a Hybrid Cloud Console notification. For example, run
insights-clienton a system that will trigger a policy event. - Wait a few minutes, and then navigate to your third-party application to check for a notification.
- In the Hybrid Cloud Console, go to Settings > Notifications > Event Log and check for an event that shows the label Integration: Webhook.
- If the label is green, the notification succeeded.
- If the label is red, verify that the incoming webhook connector was properly created in your application, and that the correct incoming webhook URL is added in the Hybrid Cloud Console integration configuration.
Note See Troubleshoot notification failures in the notifications documentation for more details.
- For webhook configuration examples, see these articles in the Red Hat blog: