Skip to content

Add object_attributes.action for note webhooks

Luke Duncalfe requested to merge ld-add-action-to-notes-webhooks into master

What does this MR do and why?

After !127169 (merged) note webhooks now also fire when a note is updated, as well as created.

As suggested in !127169 (comment 1822611315), this MR adds a new object_attributes.action property to the comment webhook to provide customers with a way to determine which event triggered the webhook. This is a property key used in other webhooks for the same purpose.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

How to set up and validate locally

  1. Create a project webhook:
    1. Choose a project, go Settings > Webhooks.
    2. For URL use https://webhook.site to generate a new webhook receiving URL.
    3. For Trigger, select Comment events.
    4. Select Add webhook.
  2. Choose an issue in the project.
    1. Add a comment to the issue. Your https://webhook.site URL should receive a webhook with object_attributes.action of "create".
    2. Now edit the same comment. Your https://webhook.site URL should receive a webhook with object_attributes.action of "update".
Edited by Luke Duncalfe

Merge request reports