Run Eliza plugins inside OpenClaw. Wraps Eliza actions as OpenClaw tools, providers as lifecycle hooks, services, routes, and evaluators — letting the two agent ecosystems interoperate.
# 1. Install the adapter and an Eliza plugin
npm install @elizaos/openclaw-adapter @elizaos/plugin-evm
# 2. Add to your OpenClaw config (see Configuration below)
# 3. Start OpenClaw — the EVM wallet tools are now available to your agent| Eliza concept | OpenClaw equivalent | How it works |
|---|---|---|
| Action | Tool | Parameters converted to TypeBox schema, handler wrapped in execute() |
| Provider | before_agent_start hook |
Provider output injected as prepended context |
| Service | Service | Started eagerly, injected into RuntimeBridge for other components |
| Route | HTTP route | Request/response translated, paths prefixed with /eliza |
| Evaluator | message_received / agent_end hook |
Pre-evaluators → message hooks, post-evaluators → agent-end hooks |
| Event | Lifecycle hook | Mapped where semantics align (MESSAGE_RECEIVED → message_received, etc.) |
npm install @elizaos/openclaw-adapterIf you're inside the OpenClaw monorepo, the adapter is already at extensions/eliza-adapter/ and gets discovered automatically.
# EVM wallet (Ethereum, Base, Arbitrum, etc.)
npm install @elizaos/plugin-evm
# Solana wallet
npm install @elizaos/plugin-solana
# Or any other Eliza plugin
npm install @elizaos/plugin-discordIn your openclaw.json (or wherever your OpenClaw config lives):
{
"plugins": {
"eliza-adapter": {
"plugins": [
"@elizaos/plugin-evm"
],
"settings": {
"EVM_PRIVATE_KEY": "${EVM_PRIVATE_KEY}",
"EVM_PROVIDER_URL": "https://mainnet.infura.io/v3/YOUR_KEY"
},
"agentName": "WalletBot"
}
}
}The adapter resolves ${VAR} patterns in settings from environment variables:
export EVM_PRIVATE_KEY="0x..."
export EVM_PROVIDER_URL="https://mainnet.infura.io/v3/..."Or pass them directly (not recommended for secrets):
{
"settings": {
"EVM_PRIVATE_KEY": "0xabcdef..."
}
}| Field | Required | Default | Description |
|---|---|---|---|
plugins |
Yes | — | Array of Eliza plugin package names or file paths |
settings |
No | {} |
Key-value pairs passed to plugins via runtime.getSetting(). Supports ${ENV_VAR} expansion. |
agentName |
No | "Eliza" |
Agent display name in the Eliza character context |
EVM wallet only:
{
"plugins": {
"eliza-adapter": {
"plugins": ["@elizaos/plugin-evm"],
"settings": {
"EVM_PRIVATE_KEY": "${EVM_PRIVATE_KEY}"
}
}
}
}Multiple plugins:
{
"plugins": {
"eliza-adapter": {
"plugins": [
"@elizaos/plugin-evm",
"@elizaos/plugin-solana"
],
"settings": {
"EVM_PRIVATE_KEY": "${EVM_PRIVATE_KEY}",
"SOLANA_PRIVATE_KEY": "${SOLANA_PRIVATE_KEY}",
"SOLANA_RPC_URL": "https://api.mainnet-beta.solana.com"
},
"agentName": "MultiWallet"
}
}
}Local plugin by file path:
{
"plugins": {
"eliza-adapter": {
"plugins": ["./my-custom-eliza-plugin/index.js"]
}
}
}When you configure plugins: ["@elizaos/plugin-evm"], the adapter:
- Starts the EVMService (connects wallet, sets up RPC)
- Registers tools:
eliza_send_tokens,eliza_swap_tokens,eliza_cross_chain_transfer, etc. - Registers hooks: Wallet balance and token balance injected into agent context before each run
- Registers routes: Any HTTP endpoints the plugin exposes, under
/eliza/...
The tools appear in OpenClaw's agent like any native tool:
Agent: calling eliza_send_tokens({ toAddress: "0x742d...", amount: "1.5", chain: "base" })
→ Successfully transferred 1.5 ETH to 0x742d...
Transaction: 0xabc...
The adapter includes pre-built parameter schemas for common wallet actions:
| Tool name | Parameters |
|---|---|
eliza_send_tokens |
toAddress, amount, token?, chain? |
eliza_swap_tokens |
inputToken, outputToken, amount, chain?, slippage? |
eliza_cross_chain_transfer |
token, amount, fromChain, toChain, toAddress? |
eliza_transfer_sol |
toAddress, amount, mint? |
eliza_swap_sol |
inputMint, outputMint, amount, slippage? |
Actions with explicit parameter definitions get their schemas converted automatically. Unknown actions get a generic { input: string } fallback.
Eliza plugins are loaded via dynamic import(). They must be npm-installed or path-resolvable from where OpenClaw runs:
# Install globally alongside OpenClaw
npm install @elizaos/plugin-evm
# Or link a local development plugin
npm link ../my-local-eliza-pluginThe adapter tries these export patterns in order:
- Default export (
export default plugin) - Named
pluginexport (export const plugin = ...) - Any named export matching the Plugin shape (
{ name: string, description: string })
Any Eliza plugin that exports the standard Plugin shape works:
- Wallet plugins (plugin-evm, plugin-solana) — actions become transfer/swap/bridge tools
- Service plugins — started and available via
runtime.getService() - Provider plugins — context injected into agent prompts
- LLM methods (
useModel,generateText) are not available. Actions that rely on conversational parameter extraction need explicit parameters or known schemas. - Channel plugins (Discord, Telegram) register as tools only, not as native OpenClaw channels.
- Database is in-memory with LRU eviction (10K memories/table, 5K logs). No persistence across restarts.
- Embeddings are not generated. Vector search works if embeddings are provided but none are created automatically.
git clone https://github.com/elizaOS/openclaw-adapter.git
cd openclaw-adapter
npm install
# Run tests (418 tests)
npm test
# Type-check
npm run typecheck
# Build
npm run buildindex.ts Entry point — loads plugins, orchestrates registration
src/
runtime-bridge.ts IAgentRuntime shim backed by InMemoryStore
in-memory-store.ts IDatabaseAdapter with LRU eviction
action-to-tool.ts Eliza Action → OpenClaw tool
provider-to-hook.ts Eliza Provider → before_agent_start hook
service-adapter.ts Eliza Service → OpenClaw service
route-adapter.ts Eliza Route → OpenClaw HTTP route
evaluator-to-hook.ts Eliza Evaluator → lifecycle hooks
schema-converter.ts JSON Schema → TypeBox + known wallet schemas
event-mapper.ts Eliza events → OpenClaw hooks
config.ts Config parsing with ${ENV_VAR} resolution
eliza-types.ts Local type definitions (zero runtime deps on @elizaos/core)
logger-adapter.ts Logger shape adapter
memory-builder.ts Memory object construction
types.ts Config types + NotImplementedError
MIT