llm agent, and forwards the request to its inference backend.
Prerequisites
Before connecting Open WebUI, you need:- a reachable Hivenet Router router
- a Hivenet Router client API key
- at least one healthy agent registered with the
llmcapability - an OpenAI-compatible inference backend
- a persistent location for Open WebUI data
- HTTPS when users connect over an untrusted network
Test Hivenet Router first
Send a direct request before adding Open WebUI:- the API key is valid
- the key can access the model
- an eligible agent is available
- the backend accepts Chat Completions
- streaming works across the router and agent
Run Open WebUI
For a shared or persistent deployment, use Docker Compose and pin a specific Open WebUI release. Create:3000 directly to the internet.
The persistent volume stores Open WebUI’s database, accounts, chats, uploads, settings, and provider configuration.Recreating the container with the same volume preserves that data.
Create the administrator account
The first account created on a fresh Open WebUI installation becomes the administrator. When additional sign-up is enabled, new accounts use the configured default role. The normal restricted value is:- review whether sign-up should remain enabled
- approve only intended users
- review default user permissions
- keep provider and model administration restricted
- configure SSO when the deployment requires centralized identity management
Add the Hivenet Router connection
In Open WebUI:1
Open the connection settings
Go to:Add a new connection.
2
Select Chat Completions
Keep the connection’s API type set to:Do not select Responses.
3
Enter the router URL
Use the Hivenet Router base URL with Do not include the final
/v1:/chat/completions path.4
Enter the client API key
Enter the raw Hivenet Router client key.Open WebUI sends it upstream as:
5
Filter the model list
Add the LLM model IDs that should appear in the Open WebUI model selector.Use the exact values returned by:
6
Save and verify
Save the connection and confirm that the intended models appear in the chat model selector.
Base URL
Use:404.
Docker networking
Inside the Open WebUI container:Router in the same Compose network
router is the Hivenet Router service name.
Router on the Docker host
Router on another machine
Filter the model IDs
Open WebUI can discover models automatically through:- LLM models
- embedding models
- reranking models
llm agent would then be eligible.
Model names must match exactly
The ID configured in Open WebUI becomes the request’s top-level model value:Use a connection prefix
When several Open WebUI connections contain models with the same ID, add a connection prefix. For example:Test the browser workflow
Select one of the Hivenet Router models and send:- the model appears in the selector
- the response begins streaming
- the expected model is used
- a request appears in Hivenet Router audit data
- the selected agent is healthy
- no unexpected background or fallback provider receives the request
Shared API-key behavior
An administrator-managed Open WebUI connection is shared by the instance. Every user who accesses that connection sends requests through the same Hivenet Router client API key. Hivenet Router therefore sees:- one tenant owner
- one static key identity or dynamic key ID
- one model-access policy
- shared request-rate quotas
- shared daily token quotas
- credentials
- model access
- quotas
- rotation
- audit attribution
Forwarded user information
Open WebUI can forward headers such as:X-OpenWebUI-User-* headers with a signed JWT when FORWARD_USER_INFO_HEADER_JWT_SECRET is configured.
Hivenet Router preserves compatible client headers when forwarding a request to the selected inference backend.
However, Hivenet Router does not currently use these Open WebUI headers for:
- client authentication
- tenant selection
- API-key quotas
- model authorization
- audit tenant identity
Background task requests
Open WebUI can send additional model requests for interface features such as:- chat-title generation
- tag generation
- follow-up suggestions
- prompt autocomplete
- search-query generation
- context compaction
Use a dedicated task model
Configure a smaller model available through Hivenet Router:- appear in
/v1/models - be permitted by the shared API key
- have a healthy
llmagent - support the task request format
- have a declared per-model quota when strict per-model quotas are used
Disable unnecessary tasks
Selected features can be disabled through the Open WebUI administrator settings or environment configuration:Tool calling
Current Open WebUI releases use native model tool calling as the default supported mode. Hivenet Router forwards Chat Completions fields such as:- model family
- tool-call parser
- chat template
- backend version
- streaming behavior
- model reliability
Test native tool use
Attach a harmless tool in Open WebUI, then ask the model to use it. Confirm that:- Open WebUI sends structured tool definitions.
- The backend returns a structured tool call.
- Open WebUI runs the tool.
- The tool result is sent back to the model.
- The model produces a final response.
Chat features and endpoint support
Unsupported Open WebUI features can use separate external services where appropriate.
Do not enable Hivenet Router’s public inference surface to proxy arbitrary backend endpoints merely to satisfy an unrelated Open WebUI feature.
Use Hivenet Router for RAG embeddings
Open WebUI can send its RAG embedding requests through Hivenet Router. Configure:- the LLM used for chat
- the embedding model used for retrieval
Test embeddings directly
Use Hivenet Router for reranking
Configure an external reranker:Configuration persistence
Many Open WebUI environment settings are persistent configuration values. On the first launch, an environment variable can initialize the setting. Open WebUI then stores it in its database. On later restarts, the stored database value can take precedence over a changed environment variable. This affects settings such as:- provider URLs and keys
- model filters
- task models
- feature toggles
- sign-up and role settings
- inspect the value in the administrator interface
- update the stored setting there
- confirm that you are using the intended data volume
- review
ENABLE_PERSISTENT_CONFIGbefore changing its behavior
Bootstrap the connection through environment variables
For a simple one-connection deployment, you can seed the Hivenet Router connection when Open WebUI starts:Timeouts
Open WebUI and Hivenet Router enforce separate timeouts. Hivenet Router’s default request timeout is:Streaming and reverse proxies
The complete response path must preserve server-sent events:- backend streaming
- response
Content-Type - Hivenet Router agent version
- proxy buffering
- proxy read and idle timeouts
- Open WebUI upstream timeouts
- Hivenet Router request timeout
Access control
Open WebUI can control which users and groups can access its models and features. Use Open WebUI access control for:- model visibility in the interface
- group-based access
- chat and workspace permissions
- tools and knowledge-base access
- user approval
- upstream API authentication
- enforceable model allowlists
- request quotas
- daily token budgets
- tenant attribution
- routing policies
Security guidance
For a shared deployment:- place Open WebUI behind HTTPS
- keep it on a private network, VPN, or protected access layer
- keep sign-up disabled except during controlled onboarding
- leave new users pending until approved
- use a dedicated Hivenet Router key
- restrict that key to the required models
- do not use a Hivenet Router administrator key
- keep Open WebUI’s arbitrary OpenAI passthrough disabled
- review tools, functions, web search, code execution, and community sharing
- protect and back up the Open WebUI data volume
- treat the volume as sensitive
- use a pinned Open WebUI release for shared or production deployments
Back up before upgrading
Back up the data volume:Observe Open WebUI traffic
Give the shared connection a dedicated Hivenet Router key:Troubleshooting
The connection verification fails
Test the same URL and key directly:- URL ends in
/v1 - API key is the raw client credential
- Open WebUI can reach the router
- TLS certificates are trusted
- the router has registered agents
- a reverse proxy preserves
Authorization
The model selector is empty
Check the live catalog:- the API key hides the models
- strict per-model quotas omit them
- the model-list timeout is too short
- the saved connection is disabled
- persistent configuration contains an older URL or key
An embedding model appears in the chat selector
Limit the connection’s Model IDs tollm models.
Configure embeddings separately through the RAG settings.
Chat requests go to /v1/responses
The connection uses the wrong API type.
Edit it and select:
/v1/responses.
Requests return 401 Unauthorized
Confirm that Open WebUI stores the raw Hivenet Router client key.
Do not use:
- the key hash from
auth.yaml - an administrator key
- the agent JWT secret
/v1/models.
Hivenet Router returns model_forbidden
The shared key’s explicit allowlist does not include the selected model.
Add the exact model ID to the key or remove the model from Open WebUI.
Hivenet Router returns 429 for an apparently permitted model
The key probably uses quota.per_model, and the selected model has no entry.
Every model used for chat, tasks, embeddings, or reranking needs its own per-model quota entry.
Hivenet Router returns no_agents_available
Check:
- selected model ID
llmcapability- agent health
- routing policy
- model availability
- static metadata matches
There are more requests than user messages
Open WebUI background tasks are using the shared model. Check:- title generation
- tag generation
- follow-up generation
- autocomplete
- retrieval-query generation
- context compaction
TASK_MODEL_EXTERNAL or disable unnecessary features.
Text works but tools fail
Check that:- the model supports native function calling
- the backend accepts
toolsandtool_choice - the correct tool-call parser is enabled
- the chat template supports tools
- the response contains structured
tool_calls - the user has access to the attached Open WebUI tool
Streaming arrives all at once
Test streaming directly against Hivenet Router. If direct streaming works, inspect:- the proxy in front of Hivenet Router
- Open WebUI’s upstream connection
- browser-to-Open-WebUI proxy settings
- response buffering
- read and idle timeouts
The router is on the host but cannot be reached
Do not use:Environment changes do not apply
Open WebUI may be using the value persisted in its database. Update it through the administrator settings or review the persistent-configuration behavior.Sign-in state is lost after recreating the container
Confirm that:/app/backend/datauses a persistent volume- the same volume is mounted after recreation
WEBUI_SECRET_KEYhas not changed
Open WebUI stops after an upgrade
Inspect:- database migration errors
- invalid persistent configuration
- volume permission problems
- incompatible environment variables
- frontend cache problems
Next steps
Use from code
Call Hivenet Router from curl, Python, JavaScript, SDKs, and services.
Chat completions and messages
Review Chat Completions forwarding, streaming, headers, and errors.
Embeddings
Configure a Hivenet Router embedding model for Open WebUI retrieval.
Reranking
Connect an external reranking model to the retrieval pipeline.
API keys
Configure the shared model access, quotas, expiration, and rotation.
Audit logging
Investigate user-facing and background requests through structured records.

