add the missing sharing.public_chats default permission used by the shared-chat access endpoint
add USER_PERMISSIONS_CHAT_ALLOW_PUBLIC_SHARING so admins can disable public chat grants without the key being absent
pass the user's public-chat and user-grant permissions into ShareChatModal's AccessControl, so the UI matches what the backend will persist
Why
/api/v1/chats/shared/{id}/access/update already filters public grants through sharing.public_chats, but that key is absent from the default backend/frontend permission schemas. For non-admin users, selecting Public can be accepted by the UI and then filtered out by the backend, which looks like the dialog jumping back to Private. This matches #24378's reported behavior.
Validation
python -m py_compile backend/open_webui/config.py
git diff --check
No frontend dependency install was present in this clone (
ode_modules absent), so I kept validation to syntax/diff checks.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/open-webui/open-webui/pull/24403
**Author:** [@dutchaiagency](https://github.com/dutchaiagency)
**Created:** 5/6/2026
**Status:** ❌ Closed
**Base:** `dev` ← **Head:** `codex/public-chat-permission`
---
### 📝 Commits (1)
- [`4d1c089`](https://github.com/open-webui/open-webui/commit/4d1c089f2fcdee9add8ba4fa6f910a7fff22d31b) fix: honor public chat sharing permission
### 📊 Changes
**3 files changed** (+17 additions, -3 deletions)
<details>
<summary>View changed files</summary>
📝 `backend/open_webui/config.py` (+5 -0)
📝 `src/lib/components/chat/ShareChatModal.svelte` (+10 -2)
📝 `src/lib/constants/permissions.ts` (+2 -1)
</details>
### 📄 Description
## Summary
- add the missing sharing.public_chats default permission used by the shared-chat access endpoint
- add USER_PERMISSIONS_CHAT_ALLOW_PUBLIC_SHARING so admins can disable public chat grants without the key being absent
- pass the user's public-chat and user-grant permissions into ShareChatModal's AccessControl, so the UI matches what the backend will persist
## Why
/api/v1/chats/shared/{id}/access/update already filters public grants through sharing.public_chats, but that key is absent from the default backend/frontend permission schemas. For non-admin users, selecting Public can be accepted by the UI and then filtered out by the backend, which looks like the dialog jumping back to Private. This matches #24378's reported behavior.
## Validation
- python -m py_compile backend/open_webui/config.py
- git diff --check
No frontend dependency install was present in this clone (
ode_modules absent), so I kept validation to syntax/diff checks.
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/24403
Author: @dutchaiagency
Created: 5/6/2026
Status: ❌ Closed
Base:
dev← Head:codex/public-chat-permission📝 Commits (1)
4d1c089fix: honor public chat sharing permission📊 Changes
3 files changed (+17 additions, -3 deletions)
View changed files
📝
backend/open_webui/config.py(+5 -0)📝
src/lib/components/chat/ShareChatModal.svelte(+10 -2)📝
src/lib/constants/permissions.ts(+2 -1)📄 Description
Summary
Why
/api/v1/chats/shared/{id}/access/update already filters public grants through sharing.public_chats, but that key is absent from the default backend/frontend permission schemas. For non-admin users, selecting Public can be accepted by the UI and then filtered out by the backend, which looks like the dialog jumping back to Private. This matches #24378's reported behavior.
Validation
No frontend dependency install was present in this clone (
ode_modules absent), so I kept validation to syntax/diff checks.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.