From 57a5e43696d0f9f057d8a0829b02aa04237f4b0e Mon Sep 17 00:00:00 2001 From: G30 <50341825+silentoplayz@users.noreply.github.com> Date: Tue, 16 Jun 2026 18:47:44 -0400 Subject: [PATCH] feat(permissions): add per-group features.user_webhooks permission (#25923) --- backend/open_webui/config.py | 5 +++++ backend/open_webui/routers/users.py | 1 + .../admin/Users/Groups/Permissions.svelte | 16 ++++++++++++++++ src/lib/components/chat/Settings/Account.svelte | 2 +- src/lib/constants/permissions.ts | 3 ++- 5 files changed, 25 insertions(+), 2 deletions(-) diff --git a/backend/open_webui/config.py b/backend/open_webui/config.py index e3a90dbcf5..d528f5ad39 100644 --- a/backend/open_webui/config.py +++ b/backend/open_webui/config.py @@ -2813,6 +2813,10 @@ USER_PERMISSIONS_FEATURES_AUTOMATIONS = os.getenv('USER_PERMISSIONS_FEATURES_AUT USER_PERMISSIONS_FEATURES_CALENDAR = os.getenv('USER_PERMISSIONS_FEATURES_CALENDAR', 'True').lower() == 'true' +USER_PERMISSIONS_FEATURES_USER_WEBHOOKS = ( + os.getenv('USER_PERMISSIONS_FEATURES_USER_WEBHOOKS', 'False').lower() == 'true' +) + USER_PERMISSIONS_SETTINGS_INTERFACE = os.getenv('USER_PERMISSIONS_SETTINGS_INTERFACE', 'True').lower() == 'true' @@ -2888,6 +2892,7 @@ DEFAULT_USER_PERMISSIONS = { 'memories': USER_PERMISSIONS_FEATURES_MEMORIES, 'automations': USER_PERMISSIONS_FEATURES_AUTOMATIONS, 'calendar': USER_PERMISSIONS_FEATURES_CALENDAR, + 'user_webhooks': USER_PERMISSIONS_FEATURES_USER_WEBHOOKS, }, 'settings': { 'interface': USER_PERMISSIONS_SETTINGS_INTERFACE, diff --git a/backend/open_webui/routers/users.py b/backend/open_webui/routers/users.py index ef1c989773..cb60e4cb33 100644 --- a/backend/open_webui/routers/users.py +++ b/backend/open_webui/routers/users.py @@ -239,6 +239,7 @@ class FeaturesPermissions(BaseModel): memories: bool = True automations: bool = False calendar: bool = True + user_webhooks: bool = False class SettingsPermissions(BaseModel): diff --git a/src/lib/components/admin/Users/Groups/Permissions.svelte b/src/lib/components/admin/Users/Groups/Permissions.svelte index bb07931efd..aef991cdfa 100644 --- a/src/lib/components/admin/Users/Groups/Permissions.svelte +++ b/src/lib/components/admin/Users/Groups/Permissions.svelte @@ -1001,6 +1001,22 @@ {/if} + +