Zing Forum

Reading

openclaw-openwebui-moss: Integrating OpenClaw Moss AI Agents into Open WebUI

This is a production-grade OpenClaw plugin that enables Moss AI agents to run in Open WebUI, providing secure multi-agent routing, strict access control, and channel-based workflows suitable for editing, development, and operation scenarios.

Open WebUIOpenClawMossAI代理插件OpenAI兼容多代理自托管
Published 2026-04-22 23:46Recent activity 2026-04-22 23:56Estimated read 5 min
openclaw-openwebui-moss: Integrating OpenClaw Moss AI Agents into Open WebUI
1

Section 01

openclaw-openwebui-moss: Bridging OpenWebUI and OpenClaw Moss AI Agents

This production-grade OpenClaw plugin integrates Moss AI agents into OpenWebUI, enabling safe multi-agent routing, strict access control, and channel-based workflows. It supports editing, development, and operations scenarios, with OpenAI compatibility and self-hosting capabilities.

2

Section 02

Background: OpenWebUI & OpenClaw Moss Ecosystems

OpenWebUI is a popular self-hosted LLM web interface with a ChatGPT-like user experience, running on private servers. OpenClaw is an emerging AI agent platform for creating and managing Moss agents (each with unique identities and capabilities). This plugin connects the two, allowing seamless use of Moss agents in OpenWebUI.

3

Section 03

Architecture: OpenAI Compatible Layer & Workflow

The plugin uses an OpenAI-compatible API layer. Workflow:

  1. OpenWebUI sends OpenAI API requests (GET /v1/models or POST /v1/chat/completions)
  2. Plugin loads Moss config from filesystem
  3. Builds prompt (IDENTITY.md + context files + user messages)
  4. Relays request to OpenClaw API
  5. Converts result to OpenAI format.

Model discovery: Dynamic from ~/.openclaw/workspace/moss-models/ — each folder is a model (folder name as model.id, IDENTITY.md required; loads .md/.txt files as context).

4

Section 04

Key Features & Integration Steps

Prompt Construction: Loads model folder → uses IDENTITY.md as system message → adds context files → combines with chat history. Optional Config: config.json in model folders sets agentId (default main) or maxContextBytes. Installation: Local dev (pnpm install/build, env vars like OPENCLAW_API_URL; Docker (compose up -d --build); embed in OpenClaw. OpenWebUI Integration: Add OpenAI connection (API URL to provider port, any API key) → Moss agents appear as models.

5

Section 05

Practical Application Scenarios

  1. Editing Teams: Moss agent for content review/editing with style guides.
  2. Dev Teams: Specialized agents (React, Python, security code review) with relevant docs.
  3. Ops Teams: Agent with runbooks/troubleshooting guides.
  4. Multi-Tenant: Isolate agents via model folders for different teams/projects.
6

Section 06

Security & Access Control

Security mechanisms:

  • File system isolation (per agent folders)
  • Config validation (skip invalid configs, log warnings)
  • Token authentication (OpenClaw Gateway Token)
  • On-request model loading (avoids automatic execution of malicious files).
7

Section 07

Limitations & Future Directions

Limitations: No streaming chat.completions; uses last user message only; simple context file concatenation; no RAG/vector search; no tools/attachments. Future: Add streaming support; better long-dialogue context management; vector DB integration; tool calling.

8

Section 08

Conclusion: Value of the Bridge Project

openclaw-openwebui-moss is a well-designed bridge between OpenWebUI and OpenClaw ecosystems. Its file-driven model discovery, OpenAI-compatible layer, and flexible config make it a powerful AI agent management platform for teams using both tools.