Skip to content
Merged

sync #809

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
95 changes: 57 additions & 38 deletions docs/features/interface/banners.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,54 +5,73 @@ title: "🔰 Customizable Banners"

## Overview

Open WebUI provides a feature that allows administrators to create customizable banners with persistence in the `config.json` file. These banners can feature options for content, background color (info, warning, error, or success), and dismissibility. Banners are accessible only to logged-in users, ensuring the confidentiality of sensitive information.
Open WebUI allows administrators to display custom banners to logged-in users. This feature is useful for making announcements, displaying system-wide alerts, or sharing important information. Banners are persistent and can be configured to be dismissible by users.

## Configuring Banners through the Admin Panel
You can configure banners in two ways: through the Admin Panel for a user-friendly experience, or via environment variables for automated or GitOps-style deployments.

To configure banners through the admin panel, follow these steps:
## Configuring Banners

1. Log in to your Open WebUI instance as an administrator.
2. Navigate to the `Admin Panel` -> `Settings` -> `Interface`.
3. Locate the `Banners` option directly above the `Default Prompt Suggestions` option.
4. Click on the `+` icon to add a new banner.
5. Select the banner type and set the banner text as desired.
6. Choose whether the banner is dismissible or not.
7. Set the timestamp for the banner (optional).
8. Press `Save` at the bottom of the page to save the banner.
### Option 1: Using the Admin Panel

## Configuring Banners through Environment Variables
This is the most straightforward way to manage banners.

Alternatively, you can configure banners through environment variables. To do this, you will need to set the `WEBUI_BANNERS` environment variable with a list of dictionaries in the following format:
1. **Log in** to your Open WebUI instance as an administrator.
2. Navigate to the **Admin Panel** > **Settings** > **Interface**.
3. Locate the **"Banners"** section.
4. Click the **+** icon to add a new banner.

```json
[{"id": "string","type": "string [info, success, warning, error]","title": "string","content": "string","dismissible": False,"timestamp": 1000}]
```
You can then configure the following options for each banner:

- **Type:** The color and style of the banner. Choose from:
- `info` (Blue)
- `success` (Green)
- `warning` (Yellow)
- `error` (Red)
- **Title:** The main heading of the banner.
- **Content:** The main text or message of the banner.
- **Dismissible:** If toggled on, users can close the banner. Dismissed banners are stored in the user's browser, so they will not reappear for that user unless their browser cache is cleared. If toggled off, the banner will always be visible.

5. Click **"Save"** at the bottom of the page to apply your changes.

### Option 2: Using Environment Variables

For automated deployments, you can configure banners using the `WEBUI_BANNERS` environment variable. The variable should be a JSON string representing a list of banner objects.

For more information on configuring environment variables in Open WebUI, see [Environment Variable Configuration](https://docs.openwebui.com/getting-started/env-configuration#webui_banners).
**Environment Variable:**

## Environment Variable Description
- `WEBUI_BANNERS`
- **Type:** `string` (containing a JSON list of objects)
- **Default:** `[]`
- **Description:** A list of banner objects to be displayed to users.

**Example:**

Here is an example of how to set the `WEBUI_BANNERS` variable in a `docker-compose.yml` file:

```yaml
services:
open-webui:
image: ghcr.io/open-webui/open-webui:main
environment:
- 'WEBUI_BANNERS=[{"id":"update-2024-07-26","type":"info","title":"System Update","content":"A system update is scheduled for this Friday at 10 PM. Expect brief downtime.","dismissible":true},{"id":"policy-reminder","type":"warning","title":"Policy Reminder","content":"Please remember to adhere to the company-wide usage policy.","dismissible":false}]'
```

- `WEBUI_BANNERS`:
- Type: list of dict
- Default: `[]`
- Description: List of banners to show to users.
## Banner Object Properties

## Banner Options
Each banner object in the JSON list has the following properties:

- `id`: Unique identifier for the banner.
- `type`: Background color of the banner (info, success, warning, error).
- `title`: Title of the banner.
- `content`: Content of the banner.
- `dismissible`: Whether the banner is dismissible or not.
- `timestamp`: Timestamp for the banner (optional).
- `id` (string, required): A unique identifier for the banner. This is used to track which banners a user has dismissed.
- `type` (string, required): The style of the banner. Must be one of `info`, `success`, `warning`, or `error`.
- `title` (string, required): The title text displayed on the banner.
- `content` (string, required): The main message of the banner.
- `dismissible` (boolean, required): Determines if the user can close the banner. `true` means it can be dismissed; `false` means it cannot.
- `timestamp` (integer, optional): **Note:** While this field is present in the configuration, it is not currently used by the frontend. The timestamp does not affect whether a banner is displayed or not.

## FAQ
## Troubleshooting

- Q: Can I configure banners through the admin panel?
A: Yes, you can configure banners through the admin panel by navigating to `Admin Panel` -> `Settings` -> `Interface` and clicking on the `+` icon to add a new banner.
- Q: Can I configure banners through environment variables?
A: Yes, you can configure banners through environment variables by setting the `WEBUI_BANNERS` environment variable with a list of dictionaries.
- Q: What is the format for the `WEBUI_BANNERS` environment variable?
A: The format for the `WEBUI_BANNERS` environment variable is a list of dictionaries with the following keys: `id`, `type`, `title`, `content`, `dismissible`, and `timestamp`.
- Q: Can I make banners dismissible?
A: Yes, you can make banners dismissible by setting the `dismissible` key to `True` in the banner configuration or by toggling dismissibility for a banner within the UI.
- **Banner Not Appearing:**
- Ensure the JSON format for the `WEBUI_BANNERS` environment variable is correct. It must be a valid JSON array of objects.
- Check the Open WebUI server logs for any errors related to parsing the `WEBUI_BANNERS` variable.
- **Banner Cannot Be Dismissed:**
- Verify that the `dismissible` property for the banner is set to `true` in your configuration.
- If a banner is not dismissible, it is by design and cannot be closed by the user.
103 changes: 74 additions & 29 deletions docs/features/interface/webhooks.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,56 +5,101 @@ title: "🪝 Webhook Integrations"

## Overview

Open WebUI provides a webhook feature that allows you to receive notifications automatically whenever new users sign up to your instance. This is done by providing a webhook URL to Open WebUI, which will then send notifications to that URL when a new user account is created.
Open WebUI offers two distinct webhook integrations to help you stay informed about events happening within your instance. These webhooks allow you to receive automated notifications in external services like Discord, Slack, or any other application that supports incoming webhooks.

## Configuring Webhooks in Open WebUI
There are two types of webhooks available:

You will need to obtain a webhook URL from an external service that supports webhooks, such as a Discord channel or a Slack workspace. This URL will be used to receive notifications from Open WebUI.
1. **Admin Webhook:** A system-wide webhook that notifies administrators about new user sign-ups.
2. **User Webhook:** A personal webhook that notifies individual users when a response to their chat is ready, especially useful for long-running tasks.

To configure webhooks in Open WebUI, you have two options:
## 1. Admin Webhook: New User Notifications

### Option 1: Configure through the Admin Interface
This webhook is designed for administrators to monitor new user registration on the Open WebUI instance.

1. Log in to your Open WebUI instance as an administrator.
2. Navigate to the `Admin Panel`.
3. Click the `Settings` tab located at the top.
4. From there, navigate to the `General` sectionn of the setting in the admin panel.
5. Locate the `Webhook URL` field and enter the webhook URL.
6. Save the changes.
### Use Case

### Option 2: Configure through Environment Variables
- **User Registration Tracking:** Receive a real-time notification in a dedicated Slack or Discord channel whenever a new user creates an account. This helps you keep track of your user base and welcome new members.

Alternatively, you can configure the webhook URL by setting the `WEBHOOK_URL` environment variable. For more information on environment variables in Open WebUI, see [Environment Variable Configuration](https://docs.openwebui.com/getting-started/env-configuration/#webhook_url).
### Configuration

### Step 3: Verify the Webhook
You can configure the admin webhook in two ways:

To verify that the webhook is working correctly, create a new user account in Open WebUI. If the webhook is configured correctly, you should receive a notification at the specified webhook URL.
#### Option 1: Through the Admin Panel

## Webhook Payload Format
1. Log in as an administrator.
2. Navigate to **Admin Panel > Settings > General**.
3. Locate the **"Webhook URL"** field.
4. Enter the webhook URL provided by your external service (e.g., Discord, Slack).
5. Click **"Save"**.

The webhook payload sent by Open WebUI is in plain text and contains a simple notification message about the new user account. The payload format is as follows:
#### Option 2: Through Environment Variables

```txt
New user signed up: <username>
You can also set the webhook URL using the `WEBHOOK_URL` environment variable. For more details, refer to the [Environment Variable Configuration](https://docs.openwebui.com/getting-started/env-configuration/#webhook_url) documentation.

### Payload Format

When a new user signs up, Open WebUI will send a `POST` request to the configured URL with a JSON payload containing the new user's details.

**Payload Example:**

```json
{
"event": "new_user",
"user": {
"email": "tim@example.com",
"name": "Tim"
}
}
```

For example, if a user named "Tim" signs up, the payload sent would be:
## 2. User Webhook: Chat Response Notifications

This webhook allows individual users to receive a notification when a model has finished generating a response to their prompt. It's particularly useful for long-running tasks where you might navigate away from the Open WebUI tab.

### Use Case

- **Long-Running Task Alerts:** If you submit a complex prompt that takes several minutes to process, you can close the browser tab and still be notified the moment the response is ready. This allows you to work on other tasks without having to constantly check the Open WebUI interface.

### How it Works

```txt
New user signed up: Tim
The notification is only sent if you are **not actively using the WebUI**. If you have the tab open and focused, the webhook will not be triggered, preventing unnecessary notifications.

### Configuration

1. Click on your profile picture in the bottom-left corner to open the settings menu.
2. Navigate to **Settings > Account**.
3. Locate the **"Notification Webhook"** field.
4. Enter your personal webhook URL.
5. Click **"Save"**.

### Payload Format

When a chat response is ready and you are inactive, Open WebUI will send a `POST` request to your webhook URL with a JSON payload containing details about the chat.

**Payload Example:**

```json
{
"event": "chat_response",
"chat": {
"id": "abc-123-def-456",
"title": "My Awesome Conversation",
"last_message": "This is the prompt I submitted."
}
}
```

## Troubleshooting

- Make sure the webhook URL is correct and properly formatted.
- Verify that the webhook service is enabled and configured correctly.
- Check the Open WebUI logs for any errors related to the webhook.
- Verify the connection hasn't been interrupted or blocked by a firewall or proxy.
- The webhook server could be temporarily unavailable or experiencing high latency.
- If provided through the webhook service, verify if the Webhook API key is invalid, expired, or revoked.
If you're not receiving webhook notifications, here are a few things to check:

- **Verify the URL:** Ensure the webhook URL is correct and properly pasted into the settings field.
- **Service Configuration:** Double-check that the webhook is set up correctly in the external service (e.g., Discord, Slack).
- **Firewall/Proxy:** Make sure your network or firewall is not blocking outgoing requests from the Open WebUI server.
- **Open WebUI Logs:** Check the Open WebUI server logs for any error messages related to webhook failures.

:::note

Note: The webhook feature in Open WebUI is still evolving, and we plan to add more features and event types in the future.
The webhook features in Open WebUI are continuously being improved. Stay tuned for more event types and customization options in future updates.

:::
47 changes: 44 additions & 3 deletions docs/getting-started/env-configuration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -1187,6 +1187,13 @@ pip install open-webui[all]

:::

:::info

Only PGVector and ChromaDB will be consistently maintained by the Open WebUI team.
The other vector stores are community-added vector databases.

:::

### ChromaDB

#### `CHROMA_TENANT`
Expand Down Expand Up @@ -1289,6 +1296,13 @@ pip install open-webui[all]

### Milvus

:::warning

Milvus is not actively maintained by the Open WebUI team. It is an addition by the community and is maintained by the community.
If you want to use Milvus, be careful when upgrading Open WebUI (crate backups and snapshots for rollbacks) in case internal changes in Open WebUI lead to breakage.

:::

#### `MILVUS_URI`

- Type: `str`
Expand Down Expand Up @@ -1425,9 +1439,7 @@ After successful migration (from milvus to multitenancy milvus), legacy collecti
- Collection naming dependency: Multitenancy relies on Open WebUI's internal collection naming conventions (user-memory-, file-, web-search-, hash patterns). **If Open WebUI changes these conventions in future updates, multitenancy routing may break, causing data corruption or incorrect data retrieval across isolated resources.**
- No automatic rollback: Disabling multitenancy after data is written will not restore access to the shared collections. Data would need manual extraction and re-import.

**For fresh installations:**
- Multitenancy is recommended and enabled by default (true)
- No migration concerns exist
For fresh installations, no migration concerns exist

**For existing installations with valuable data:**
- Do not migrate to multitenancy mode if you do not want to handle migration and risk data loss
Expand All @@ -1445,6 +1457,17 @@ After successful migration (from milvus to multitenancy milvus), legacy collecti

:::

:::warning

The mapping of multitenancy relies on current Open WebUI naming conventions for collection names.

If Open WebUI changes how it generates collection names (e.g., "user-memory-" prefix, "file-" prefix, web search patterns, or hash formats), this mapping will break and route data to incorrect collections.
POTENTIALLY CAUSING HUGE DATA CORRUPTION, DATA CONSISTENCY ISSUES AND INCORRECT DATA MAPPING INSIDE THE DATABASE.

If you use Multitenancy Mode, you should always check for any changes to the collection names and data mapping before upgrading, and upgrade carefully (snapshots and backups for rollbacks)!

:::

#### `MILVUS_COLLECTION_PREFIX`

- Type: `str`
Expand Down Expand Up @@ -1522,6 +1545,13 @@ If set to `false`, open-webui will assume the postgreSQL database where embeddin

### Qdrant

:::warning

Qdrant is not actively maintained by the Open WebUI team. It is an addition by the community and is maintained by the community.
If you want to use Qdrant, be careful when upgrading Open WebUI (crate backups and snapshots for rollbacks) in case internal changes in Open WebUI lead to breakage.

:::

#### `QDRANT_API_KEY`

- Type: `str`
Expand Down Expand Up @@ -1594,6 +1624,17 @@ If you decide to use the multitenancy pattern as your default and you don't need

:::

:::warning

The mapping of multitenancy relies on current Open WebUI naming conventions for collection names.

If Open WebUI changes how it generates collection names (e.g., "user-memory-" prefix, "file-" prefix, web search patterns, or hash formats), this mapping will break and route data to incorrect collections.
POTENTIALLY CAUSING HUGE DATA CORRUPTION, DATA CONSISTENCY ISSUES AND INCORRECT DATA MAPPING INSIDE THE DATABASE.

If you use Multitenancy Mode, you should always check for any changes to the collection names and data mapping before upgrading, and upgrade carefully (snapshots and backups for rollbacks)!

:::

#### `QDRANT_COLLECTION_PREFIX`

- Type: `str`
Expand Down
11 changes: 9 additions & 2 deletions docs/getting-started/quick-start/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import TabItem from '@theme/TabItem';
import { TopBanners } from "@site/src/components/TopBanners";

import DockerCompose from './tab-docker/DockerCompose.md';
import Extension from './tab-docker/DockerDesktopExtension.md';
import Podman from './tab-docker/Podman.md';
import PodmanKubePlay from './tab-docker/PodmanKubePlay.md';
import ManualDocker from './tab-docker/ManualDocker.md';
Expand Down Expand Up @@ -55,19 +56,25 @@ Choose your preferred installation method below:
</div>
</TabItem>

<TabItem value="extension" label="Extension">
<div className='mt-5'>
<Extension />
</div>
</TabItem>

<TabItem value="podman" label="Podman">
<div className='mt-5'>
<Podman />
</div>
</TabItem>

<TabItem value="podman-kube-play" label="Podman Kube Play">
<TabItem value="podman-kube-play" label="Kube Play">
<div className='mt-5'>
<PodmanKubePlay />
</div>
</TabItem>

<TabItem value="swarm" label="Docker Swarm">
<TabItem value="swarm" label="Swarm">
<div className='mt-5'>
<DockerSwarm />
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Docker Desktop Extension
Docker has released an Open WebUI Docker extension that uses Docker Model Runner for inference. You can read their getting started blog here: [Run Local AI with Open WebUI + Docker Model Runner](https://www.docker.com/blog/open-webui-docker-desktop-model-runner/)

You can find troubleshooting steps for the extension in their Github repository: [Open WebUI Docker Extension - Troubleshooting](https://github.com/rw4lll/open-webui-docker-extension?tab=readme-ov-file#troubleshooting)

While this is an amazing resource to try out Open WebUI with little friction, it is not an officially supported installation method - you may run into unexpected bugs or behaviors while using it. For example, you are not able to log in as different users in the extension since it is designed to be for a single local user. If you run into issues using the extension, please submit an issue on the extension's [Github repository](https://github.com/rw4lll/open-webui-docker-extension).
Loading
Loading