Skip to main content
The migrate command automates migration from OpenClaw to Weaver, transferring configuration settings and workspace files.

Usage

weaver migrate [options]

Options

--dry-run
flag
Preview migration without making changesShows what would be migrated and displays summary.
weaver migrate --dry-run
--refresh
flag
Re-sync workspace files from OpenClawRepeatable operation that updates workspace files without touching config.Useful for keeping workspace in sync during transition period.
weaver migrate --refresh
--config-only
flag
Migrate only configuration fileSkips workspace file copying.
weaver migrate --config-only
--workspace-only
flag
Migrate only workspace filesSkips configuration migration.
weaver migrate --workspace-only
--force
flag
Skip confirmation promptsUseful for automation and scripts.
weaver migrate --force
--openclaw-home
string
default:"~/.openclaw"
Override OpenClaw home directory
weaver migrate --openclaw-home /custom/openclaw/path
--weaver-home
string
default:"~/.weaver"
Override Weaver home directory
weaver migrate --weaver-home /custom/weaver/path

Migration Process

Migration handles:

1. Configuration Mapping

Transforms OpenClaw config to Weaver format:
  • Providers: API keys and endpoints
  • Agent settings: Model, temperature, max tokens
  • Channels: Telegram, Discord, Slack tokens
  • Gateway: Host and port settings

2. Workspace Files

Copies directory structure:
OpenClaw (~/.openclaw/workspace/)
├── skills/
├── cron/
│   └── jobs.json
└── state/

↓ Migrates to ↓

Weaver (~/.weaver/workspace/)
├── skills/
├── cron/
│   └── jobs.json
└── state/

3. Compatibility Checks

Verifies:
  • OpenClaw config exists and is valid JSON
  • Target directories are writable
  • No conflicts with existing Weaver config (unless --force)

Examples

$ weaver migrate --dry-run

Detecting OpenClaw installation...
 Found OpenClaw config at /home/user/.openclaw/config.json
 Found OpenClaw workspace at /home/user/.openclaw/workspace

Migration plan:
---------------
Config:
 Provider: openrouter (API key set)
 Model: anthropic/claude-3.5-sonnet
 Channels: telegram, discord

Workspace:
 Skills: 5 directories
 Cron jobs: 3 jobs
 State files: 2 files

This is a dry run - no files were changed.
Run without --dry-run to perform migration.

Exit Codes

CodeReason
0Success - migration completed
1OpenClaw not found
1Invalid configuration
1Permission denied
1File system error

Error Handling

OpenClaw Not Found

Error: OpenClaw installation not found at ~/.openclaw
Solutions:
  • Verify OpenClaw is installed
  • Use --openclaw-home to specify custom path
  • Run weaver onboard instead for fresh setup

Invalid Configuration

Error: Failed to parse OpenClaw config: invalid JSON
OpenClaw config is corrupted. Fix manually or use weaver onboard.

Permission Denied

Error: Permission denied creating ~/.weaver/config.json
Ensure write permissions to home directory.

Existing Weaver Config

Weaver config already exists at ~/.weaver/config.json
Overwrite? (y/n): 
Response options:
  • y - Overwrite with migrated config
  • n - Abort migration
  • Use --force to skip prompt

Migration Mapping

OpenClaw → Weaver field mappings:
OpenClaw FieldWeaver FieldNotes
openrouter_api_keyproviders.openrouter.api_keyDirect copy
anthropic_api_keyproviders.anthropic.api_keyDirect copy
modelagents.defaults.modelDefault model
temperatureagents.defaults.temperatureInference parameter
telegram_tokenchannels.telegram.tokenBot token
discord_tokenchannels.discord.tokenBot token
gateway_portgateway.portServer port
workspaceworkspacePath mapping

Post-Migration

After migration:
1

Verify configuration

weaver status
Check all settings migrated correctly.
2

Test agent

weaver agent -m "Hello!"
Ensure agent responds.
3

Test gateway (optional)

weaver gateway
Verify channels connect.
4

Optional: Keep OpenClaw

You can run both OpenClaw and Weaver simultaneously during transition.Use different ports in config to avoid conflicts.

Rollback

If migration fails or causes issues:
# Remove Weaver config
rm -rf ~/.weaver

# OpenClaw remains untouched and functional

Idempotency

Migration is safe to run multiple times:
  • First run: Creates Weaver config and copies workspace
  • Subsequent runs: Prompts for overwrite or use --force
  • --refresh: Always safe, updates workspace only
Migration does not modify or delete OpenClaw files. Your OpenClaw installation remains intact.

Build docs developers (and LLMs) love