This commit is contained in:
Timothy Jaeryang Baek committed 2026-06-25 03:31:45 +01:00
1 parent 35f8bf97e3
commit b5c43968db
32 files changed
+2251 -120

No files matched your search

+13
View File
@@ -22,6 +22,7 @@ from open_webui.config import (
CACHE_DIR,
)
from open_webui.constants import ERROR_MESSAGES
from open_webui.events import EVENTS, publish_event
from open_webui.env import (
AIOHTTP_CLIENT_SESSION_SSL,
AIOHTTP_CLIENT_TIMEOUT,
@@ -310,6 +311,18 @@ async def update_config(request: Request, form_data: OpenAIConfigForm, user=Depe
'openai.api_configs': api_configs,
}
)
await publish_event(
request,
EVENTS.MODEL_PROVIDER_CONFIG_UPDATED,
actor=user,
subject_id='openai',
subject_type='model.provider_config',
data={
'provider': 'openai',
'enabled': form_data.ENABLE_OPENAI_API,
'base_url_count': len(form_data.OPENAI_API_BASE_URLS),
},
)
return {
'ENABLE_OPENAI_API': form_data.ENABLE_OPENAI_API,