Webhook triggered groups on flags

Prerequisites :

  1. Have a group with some users in it (mine is called ‘forum-mods’ and has trust level 4 users in it)

Steps

  1. In the /admin/api/web_hooks panel, create a webhook with the following settings

  2. Login as one of the users that is part of your group (ie. 'forum-mods). Or impersonate them

  3. Flag a regular user’s post as inapropiate

  4. Notice the flag appears in the /admin/flags/active part of the dashboard. But the request doesn’t appear in /admin/api/web_hooks/[webhook id]/events

Expected Behavior
See a webhook event get fired for a user in the ‘forum-mod’ group flagging another user’s post.

Possibly this is me misunderstanding the proper usage of the “Triggered Groups” setting in my webhook. The wording is a bit confusing for me “webhooks will only be triggered if the event is ‘related’ with specific groups”


Not entirely sure about ‘related’, but I’m assuming that a member of the ‘forum-mod’ group should be able to flag another user.

Also, the webhook events work fine when I remove my group from the Triggered Groups field. But I was hoping it would act as a filter because I’m creating a webhook that only cares about forum-mods flagging other users.

Not sure, maybe @vinothkannans could clarify?

Currently flag events are not filterable by groups. So you shouldn’t set ‘Triggered groups’ field for flag event web hooks. If you set it then it won’t fire.

I think either we should respect or mention the applicable types. Also this is happening in few other web hooks too. Currently we display both ‘Triggered categories’ and ‘Triggered groups’ for all type of web hook events. But it only applies to few types.

5 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.