Feature #44337
openAdd an administration page listing all webhooks
Description
Webhooks introduced in #29664 are owned by a user and managed from a single page reachable from My account. A webhook is only visible and editable by the user who created it, administrators cannot see or edit the webhooks. There is no entry in the administration menu.
This may be a problem:
Any member with the use_webhooks permission can register a hook posting project data to an external endpoint, and no administrator can see that it exists.
Once webhooks are enabled, an administrator has no way to know which external endpoints are receiving project data, how many hooks exist, or which projects and events they cover. Admins cannot respond to the question "where is our issue data being sent?".
Proposal: Add a separate administration page
A new page listing all webhooks:- a new entry in the administration menu
- the list shows the same columns as the personal page plus an Author column
- administrators can view, edit, deactivate and delete any webhook from that page
I am willing to provide a patch if the approach is agreed upon.
Files
Related issues
Updated by Vincent Robert 1 day ago
- Related to Feature #29664: Webhook triggers in Redmine added
Updated by Marius BĂLTEANU about 12 hours ago
I'm adding also Jens and Holger from Plan.io who contributed with this feature.
Updated by Vincent Robert about 6 hours ago
Here is the proposed patch.
It adds the administration page at /admin/webhooks, listing all webhooks. Administrators can edit, deactivate and delete any webhook.
The existing /webhooks page is unchanged: it still lists only the hooks of the current user.
The field secret of another user is never displayed; submitting the field empty keeps the stored value.
The admin page stays reachable when webhooks_enabled is off, with a notice, so that existing webhooks can still be reviewed and removed at the moment an administrator needs it.
The patch also resolves a performance issue by changing one line in Webhook#setable_projects (N+1 queries when filtering lots of projects)