Crate Structure¶
openclaw-rs is organized as a Cargo workspace with multiple crates.
Workspace Overview¶
openclaw-rs/
├── crates/
│ ├── openclaw-core/ # Core types and auth
│ ├── openclaw-providers/ # AI provider implementations
│ ├── openclaw-agents/ # Agent runtime
│ ├── openclaw-channels/ # Pub/sub messaging
│ ├── openclaw-plugins/ # Plugin system
│ ├── openclaw-ipc/ # IPC bridge
│ ├── openclaw-gateway/ # HTTP/WS server
│ ├── openclaw-cli/ # Command-line tool
│ └── openclaw-ui/ # Vue 3 web UI
└── bridge/
└── openclaw-node/ # Node.js bindings
Dependency Graph¶
┌─────────────┐
│ openclaw-cli│
└──────┬──────┘
│
┌──────▼──────┐
│ openclaw- │
│ gateway │
└──────┬──────┘
│
┌───────────────────┼───────────────────┐
│ │ │
┌──────▼──────┐ ┌──────▼──────┐ ┌──────▼──────┐
│ openclaw- │ │ openclaw- │ │ openclaw- │
│ agents │ │ channels │ │ plugins │
└──────┬──────┘ └──────┬──────┘ └──────┬──────┘
│ │ │
└───────────────────┼───────────────────┘
│
┌──────▼──────┐
│ openclaw- │
│ providers │
└──────┬──────┘
│
┌───────────────────┴───────────────────┐
│ │
┌──────▼──────┐ ┌──────▼──────┐
│ openclaw- │ │ openclaw- │
│ core │ │ ipc │
└─────────────┘ └─────────────┘
Crate Details¶
openclaw-core¶
Foundation types and authentication.
| Feature | Description |
|---|---|
types |
Common type definitions |
auth |
Credential management |
config |
Configuration loading |
events |
Event system primitives |
Key types:
Message- Chat message structureTool- Tool definitionCredentialStore- Encrypted credential storageConfig- Application configuration
openclaw-providers¶
AI provider implementations.
| Provider | Status | Features |
|---|---|---|
| Anthropic | Full | Streaming, tools |
| OpenAI | Full | Streaming, functions |
Key traits:
Provider- Common provider interfaceStreamingProvider- Streaming supportToolProvider- Tool calling support
openclaw-agents¶
Agent runtime and orchestration.
| Feature | Description |
|---|---|
runtime |
Agent execution |
tools |
Tool management |
sessions |
Session tracking |
Key types:
AgentRuntime- Main runtimeSession- Conversation sessionToolExecutor- Tool execution
openclaw-channels¶
Pub/sub messaging system.
Provides:
- Topic-based messaging
- Broadcast channels
- Event filtering
- Async subscribers
openclaw-plugins¶
Plugin system with IPC support.
Enables:
- External process plugins
- JSON-RPC communication
- Capability extension
- Sandboxed execution
openclaw-ipc¶
Inter-process communication.
Features:
- JSON-RPC client/server
- Stdio transport
- Socket transport
- Process lifecycle
openclaw-gateway¶
HTTP/WebSocket server.
Includes:
- Axum-based HTTP server
- WebSocket support
- Embedded UI serving
- REST and JSON-RPC APIs
openclaw-cli¶
Command-line interface.
Commands:
onboard- Setup wizardgateway- Server managementconfig- Configurationstatus- System status
openclaw-ui¶
Vue 3 web dashboard.
Not published to crates.io - embedded in gateway.
Built with:
- Vue 3 + Composition API
- Pinia state management
- Vue Router
- Vite build tool
openclaw-node¶
Node.js bindings.
Provides:
- Native provider bindings
- Event system
- Auth integration
- Agent runtime access
Feature Flags¶
openclaw-core¶
| Flag | Description |
|---|---|
default |
All features |
auth |
Credential storage |
config |
Configuration loading |
openclaw-providers¶
| Flag | Description |
|---|---|
default |
All providers |
anthropic |
Anthropic only |
openai |
OpenAI only |
openclaw-gateway¶
| Flag | Description |
|---|---|
default |
Full gateway |
embedded-ui |
Include web UI |
Publishing Order¶
For crates.io publishing, use this order:
openclaw-coreopenclaw-ipcopenclaw-providersopenclaw-channelsopenclaw-pluginsopenclaw-agentsopenclaw-gatewayopenclaw-cliopenclaw-node(npm)
Next Steps¶
:material-lightbulb: Design Principles :material-shield: Security Model