Add object_attributes.action for note webhooks
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
- Create a project webhook:
- Choose a project, go Settings > Webhooks.
- For URL use https://webhook.site to generate a new webhook receiving URL.
- For Trigger, select Comment events.
- Select Add webhook.
- Choose an issue in the project.
- Add a comment to the issue. Your https://webhook.site URL should receive a webhook with
object_attributes.action
of"create"
. - Now edit the same comment. Your https://webhook.site URL should receive a webhook with
object_attributes.action
of"update"
.
- Add a comment to the issue. Your https://webhook.site URL should receive a webhook with
Edited by Luke Duncalfe