clawdbot-skill-update
Comprehensive backup, update, and restore workflow with dynamic workspace detection
What this skill does
# Clawdbot Update Skill
Comprehensive backup, update, and restore workflow for Clawdbot installations.
## Repository
- **GitHub**: https://github.com/clawdbot/clawdbot
- **Upstream**: `origin/main`
- **Local Clone**: `~/code/clawdbot` (default)
## Description
This skill provides a complete, **modular** update workflow for Clawdbot with **dynamic workspace detection**:
- Configuration files
- Agent states and sessions
- Credentials and auth tokens
- **All agent workspaces (auto-detected from config)**
- Cron jobs and sandboxes
- Git repository state
### Key Features
✅ **Dynamic Workspace Detection** - Reads workspace paths from config
✅ **Multi-Agent Support** - Handles multiple agents automatically
✅ **Safe Rollback** - Full restore capability
✅ **Git Integration** - Tracks versions and remotes
✅ **Validation** - Pre/post checks included
✅ **Dry Run** - Preview before backup
## Files
- `config.json` - Skill configuration (repo URLs, paths)
- `backup-clawdbot-dryrun.sh` - **Dry run** preview (no changes)
- `backup-clawdbot-full.sh` - **Dynamic** full backup script
- `restore-clawdbot.sh` - **Dynamic** restore script
- `validate-setup.sh` - Pre/post update validation
- `check-upstream.sh` - Check for available updates
- `UPDATE_CHECKLIST.md` - Step-by-step update checklist
- `QUICK_REFERENCE.md` - Quick command reference
- `SKILL.md` - This file
- `README.md` - Quick start guide
### Dynamic Features
Both backup and restore scripts now:
- Read workspace paths from `~/.clawdbot/clawdbot.json`
- Support any number of agents
- Handle missing workspaces gracefully
- Generate safe filenames from agent IDs
## When to Use
Trigger this skill when asked to:
- "update clawdbot"
- "upgrade to latest version"
- "backup clawdbot before update"
- "restore clawdbot from backup"
- "rollback clawdbot update"
## Usage
### 1. Preview Backup (Dry Run)
```bash
~/.skills/clawdbot-update/backup-clawdbot-dryrun.sh
```
**Shows:**
- What files would be backed up
- Estimated backup size
- Workspace detection results
- Disk space availability
- Files that would be skipped
**No files are created or modified!**
### 2. Create Full Backup
```bash
~/.skills/clawdbot-update/backup-clawdbot-full.sh
```
**Backs up:**
- `~/.clawdbot/clawdbot.json` (config)
- `~/.clawdbot/sessions/` (session state)
- `~/.clawdbot/agents/` (multi-agent state)
- `~/.clawdbot/credentials/` (auth tokens)
- `~/.clawdbot/cron/` (scheduled jobs)
- `~/.clawdbot/sandboxes/` (sandbox state)
- All agent workspaces (dynamically detected!)
- Git commit and status
**Output:** `~/.clawdbot-backups/pre-update-YYYYMMDD-HHMMSS/`
### 3. Update Clawdbot
Follow the checklist:
```bash
cat ~/.skills/clawdbot-update/UPDATE_CHECKLIST.md
```
**Key steps:**
1. Create backup
2. Stop gateway
3. Pull latest code
4. Adjust config for breaking changes
5. Run doctor
6. Test functionality
7. Start gateway as daemon
### 4. Restore from Backup
```bash
~/.skills/clawdbot-update/restore-clawdbot.sh ~/.clawdbot-backups/pre-update-YYYYMMDD-HHMMSS
```
**Restores:**
- All configuration
- All state files
- All workspaces
- Optionally: git version
## Important Notes
### Multi-Agent Setup
This skill is designed for multi-agent setups with:
- Multiple agents with separate workspaces
- Sandbox configurations
- Provider routing (WhatsApp/Telegram/Discord/Slack/etc.)
### Breaking Changes in v2026.1.8
**CRITICAL:**
- **DM Lockdown**: DMs now default to `pairing` policy instead of open
- **Groups**: `telegram.groups` and `whatsapp.groups` are now allowlists
- **Sandbox**: Default scope changed to `"agent"` from implicit
- **Timestamps**: Now UTC format in agent envelopes
### Backup Validation
After backup, always verify:
```bash
BACKUP_DIR=~/.clawdbot-backups/pre-update-YYYYMMDD-HHMMSS
cat "$BACKUP_DIR/BACKUP_INFO.txt"
ls -lh "$BACKUP_DIR"
```
Should contain:
- ✅ `clawdbot.json`
- ✅ `credentials.tar.gz`
- ✅ `workspace-*.tar.gz` (one per agent)
### Config Changes Required
**Example: Switch WhatsApp to pairing:**
```bash
jq '.whatsapp.dmPolicy = "pairing"' ~/.clawdbot/clawdbot.json | sponge ~/.clawdbot/clawdbot.json
```
**Example: Set explicit sandbox scope:**
```bash
jq '.agent.sandbox.scope = "agent"' ~/.clawdbot/clawdbot.json | sponge ~/.clawdbot/clawdbot.json
```
## Workflow
### Standard Update Flow
```bash
# 1. Check for updates
~/.skills/clawdbot-update/check-upstream.sh
# 2. Validate current setup
~/.skills/clawdbot-update/validate-setup.sh
# 3. Dry run
~/.skills/clawdbot-update/backup-clawdbot-dryrun.sh
# 4. Backup
~/.skills/clawdbot-update/backup-clawdbot-full.sh
# 5. Stop gateway
cd ~/code/clawdbot
pnpm clawdbot gateway stop
# 6. Update code
git checkout main
git pull --rebase origin main
pnpm install
pnpm build
# 7. Run doctor
pnpm clawdbot doctor --yes
# 8. Test
pnpm clawdbot gateway start # foreground for testing
# 9. Deploy
pnpm clawdbot gateway stop
pnpm clawdbot gateway start --daemon
```
### Rollback Flow
```bash
# Quick rollback
~/.skills/clawdbot-update/restore-clawdbot.sh <backup-dir>
# Manual rollback
cd ~/code/clawdbot
git checkout <old-commit>
pnpm install && pnpm build
cp <backup-dir>/clawdbot.json ~/.clawdbot/
pnpm clawdbot gateway restart
```
## Testing After Update
### Functionality Tests
- [ ] Provider DMs work (check pairing policy)
- [ ] Group mentions respond
- [ ] Typing indicators work
- [ ] Agent routing works
- [ ] Sandbox isolation works
- [ ] Tool restrictions enforced
### New Features
```bash
pnpm clawdbot agents list
pnpm clawdbot logs --tail 50
pnpm clawdbot providers list --usage
pnpm clawdbot skills list
```
### Monitoring
```bash
# Live logs
pnpm clawdbot logs --follow
# Or Web UI
open http://localhost:3001/logs
# Check status
pnpm clawdbot status
pnpm clawdbot gateway status
```
## Troubleshooting
### Common Issues
**Gateway won't start:**
```bash
pnpm clawdbot logs --grep error
pnpm clawdbot doctor
```
**Auth errors:**
```bash
# OAuth profiles might need re-login
pnpm clawdbot providers login <provider>
```
**Sandbox issues:**
```bash
# Check sandbox config
jq '.agent.sandbox' ~/.clawdbot/clawdbot.json
# Check per-agent sandbox
jq '.routing.agents[] | {name, sandbox}' ~/.clawdbot/clawdbot.json
```
### Emergency Restore
If something goes wrong:
```bash
# 1. Stop gateway
pnpm clawdbot gateway stop
# 2. Full restore
LATEST_BACKUP=$(ls -t ~/.clawdbot-backups/ | head -1)
~/.skills/clawdbot-update/restore-clawdbot.sh ~/.clawdbot-backups/$LATEST_BACKUP
# 3. Restart
pnpm clawdbot gateway start
```
## Installation
### Via ClawdHub
```bash
clawdbot skills install clawdbot-update
```
### Manual
```bash
git clone <repo-url> ~/.skills/clawdbot-update
chmod +x ~/.skills/clawdbot-update/*.sh
```
## License
MIT - see [LICENSE](LICENSE)
## Author
**Pascal Schott** ([@pasogott](https://github.com/pasogott))
Contribution for Clawdbot
https://github.com/clawdbot/clawdbot
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.