Skip to content

Allow to set different webhooks on events in Discord Integration

What does this MR do and why?

Allow to set different webhooks on events in Discord Integration.

Until now, it was only possible to send all events to a single channel. There was no possibility to send issues/merge requests to channel 1 and failed pipelines to channel 2.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After
image image

How to set up and validate locally

  1. Create at least 2 discord webhooks: https://docs.gitlab.com/ee/user/project/integrations/discord_notifications.html#create-webhook
  2. Open the integration settings at path <project>/-/settings/integrations/discord/edit
  3. Enter the first webhook in the Webhook field
  4. Enter the second webhook in one of the fields at the triggers (easiest to validate would be with internal notes or confidential issues)
  5. Trigger an event which sends a notification for an event that has no override
  6. Validate that the webhook message is sent to the first webhook
  7. Trigger an event which sends a notification for an event that has an override
  8. Validate that the webhook message is sent to the second message

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports

Loading