SwarmClaw Platform
SwarmClaw is an AI agent runtime and multi-agent orchestration platform. It gives agents a uniform set of tools, persistent memory, connector integrations, and the ability to delegate work to other agents.
Website: https://swarmclaw.ai
Docs: https://swarmclaw.ai/docs
GitHub: https://github.com/swarmclawai/swarmclaw
npm: npm install -g swarmclaw
The 6 Primitive Tools
Every agent has access to these core tools. They cover the full range of agent capabilities.
| Tool |
Purpose |
When to Use |
| files |
Read, write, edit, list, search files |
Any file operation on the workspace filesystem |
| execute |
Run bash scripts (sandboxed or host) |
Shell commands, curl, data processing, package management |
| memory |
Store and retrieve persistent knowledge |
Facts, preferences, decisions that should survive across sessions |
| platform |
Tasks, communication, delegation, projects |
Coordinating with humans and other agents |
| browser |
Control a headless browser |
Interactive web pages, JavaScript-rendered content |
| skills |
Discover and load skill documentation |
Learning how to use tools, APIs, or workflows |
Tool Selection Guide
| Task |
Tool |
| Edit a source file |
files (edit action) |
| Run tests |
execute |
| Call a REST API (JSON) |
execute (curl) |
| Scrape a dynamic web page |
browser |
| Remember a user preference |
memory |
| Ask the user a question |
platform (communicate.ask_human) |
| Send a Slack message |
platform (communicate.send_message) |
| Hand off work to another agent |
platform (communicate.delegate) |
| Find out how a tool works |
skills (read action) |
Credentials
Credentials are configured per agent in the SwarmClaw UI. They are:
- Injected as environment variables into
execute tool runs (e.g., $OPENAI_API_KEY, $GITHUB_TOKEN)
- Automatically redacted from all tool output -- secrets never appear in chat history
- Named by convention:
<PROVIDER>_API_KEY or custom names set in the credential config
You never need to ask the user for API keys directly. If a credential is configured, it's available as an env var. If it's not configured, tell the user which credential to add in the agent settings.
The Skill System
Skills are markdown files that teach agents how to use tools, APIs, and workflows. They are documentation, not executable code.
Loading Skills
{ "tool": "skills", "action": "list" }
{ "tool": "skills", "action": "read", "name": "tools/files" }
{ "tool": "skills", "action": "search", "query": "github pr" }
Skill Locations
skills/ -- built-in skills shipped with SwarmClaw
data/skills/ -- user-created skills added at runtime
When to Load Skills
- Before using a tool you're unfamiliar with
- When a task involves an API or workflow you haven't used before
- When the user asks you to do something and you're unsure of the best approach
Agent Capabilities
Memory
Agents have persistent memory across sessions:
- Working memory (session-scoped): scratch notes, intermediate results
- Durable memory (cross-session): user preferences, project facts, decisions
- Memories are automatically surfaced in context when relevant
- Store important learnings proactively -- don't wait to be asked
Dreaming
Agents with dreaming enabled automatically consolidate memories during idle periods. You can also trigger a dream manually:
Check dream status
{ "tool": "memory", "action": "list", "category": "dream_reflection" }
Manual dream trigger
Use the platform API to trigger a dream cycle:
{ "tool": "execute", "command": "curl -s -X POST http://localhost:3456/api/memory/dream -H 'Content-Type: application/json' -d '{\"agentId\":\"YOUR_AGENT_ID\"}'" }
Dream cycles produce dream_reflection and consolidated_insight memories that help maintain a clean, coherent memory store over time.
Delegation
Agents can delegate work to other agents:
- delegate: route a task to a specific agent and wait for the result
- spawn: create a subagent that runs independently (fire-and-forget or session-based)
- Use
agents.list to discover available agents and their specializations
Connectors
Agents can communicate through external platforms:
- Discord, Slack, Telegram, and custom webhooks
- Messages sent via
platform tool with communicate.send_message
- Inbound messages from connectors trigger agent sessions automatically
MCP Servers
Agents can also use tools served by external Model Context Protocol servers:
- Register MCP servers under MCP Servers in the UI (stdio / sse / streamable-http transports supported).
- Quick-setup presets include SwarmVault (local-first knowledge vault) and SwarmDock (agent marketplace — browse tasks, bid, submit work, earn USDC). The SwarmDock preset is pre-filled for the hosted endpoint at
https://swarmdock-api.onrender.com/mcp and just needs the Bearer header (generate a key and register an agent at swarmdock.ai/mcp/connect). See docs/mcp-servers.md for the full workflow.
- Once attached to an agent, MCP tools appear alongside the built-in tools at execution time.
Workspace Conventions
- The workspace root is the agent's working directory
- File paths in tool calls are relative to the workspace root
/workspace/... paths are resolved to the workspace root automatically
- The
$WORKSPACE env var points to the workspace root in execute tool runs
Best Practices
Load skills before unfamiliar operations. A 30-second skill read prevents minutes of trial and error.
Use the right tool for the job. Don't use execute with echo > file.txt when files write action is cleaner. Don't use browser when curl in execute suffices.
Store important context in memory. If you learn something that would help in future sessions (user preference, project convention, API quirk), store it immediately.
Ask rather than guess. When genuinely uncertain about user intent, use communicate.ask_human. A brief clarification is better than wasted work on the wrong approach.
Delegate when appropriate. If another agent is better suited for a subtask, delegate. Check agents.list to know what's available.
Be explicit about what you're doing. When running commands, editing files, or making decisions, explain your reasoning. Transparency builds trust.
Respect file access boundaries. Stay within the workspace unless the agent has machine-scope access. Never write to system directories.
Handle errors gracefully. When a tool call fails, read the error message, diagnose the issue, and retry with a corrected approach. Don't repeat the same failing call.
1---2name: swarmclaw-23description: AI agent runtime and multi-agent orchestration platform. Teaches agents how to use SwarmClaw's 6 primitive tools, persistent memory, dreaming, delegation, connectors, credentials, and the skill system. Use when an agent is running on SwarmClaw and needs to understand the platform's capabilities.4---56# SwarmClaw Platform78SwarmClaw is an AI agent runtime and multi-agent orchestration platform. It gives agents a uniform set of tools, persistent memory, connector integrations, and the ability to delegate work to other agents.910Website: https://swarmclaw.ai11Docs: https://swarmclaw.ai/docs12GitHub: https://github.com/swarmclawai/swarmclaw13npm: `npm install -g swarmclaw`1415## The 6 Primitive Tools1617Every agent has access to these core tools. They cover the full range of agent capabilities.1819| Tool | Purpose | When to Use |20|------|---------|-------------|21| **files** | Read, write, edit, list, search files | Any file operation on the workspace filesystem |22| **execute** | Run bash scripts (sandboxed or host) | Shell commands, curl, data processing, package management |23| **memory** | Store and retrieve persistent knowledge | Facts, preferences, decisions that should survive across sessions |24| **platform** | Tasks, communication, delegation, projects | Coordinating with humans and other agents |25| **browser** | Control a headless browser | Interactive web pages, JavaScript-rendered content |26| **skills** | Discover and load skill documentation | Learning how to use tools, APIs, or workflows |2728### Tool Selection Guide2930| Task | Tool |31|------|------|32| Edit a source file | `files` (edit action) |33| Run tests | `execute` |34| Call a REST API (JSON) | `execute` (curl) |35| Scrape a dynamic web page | `browser` |36| Remember a user preference | `memory` |37| Ask the user a question | `platform` (communicate.ask_human) |38| Send a Slack message | `platform` (communicate.send_message) |39| Hand off work to another agent | `platform` (communicate.delegate) |40| Find out how a tool works | `skills` (read action) |4142## Credentials4344Credentials are configured per agent in the SwarmClaw UI. They are:4546- **Injected as environment variables** into `execute` tool runs (e.g., `$OPENAI_API_KEY`, `$GITHUB_TOKEN`)47- **Automatically redacted** from all tool output -- secrets never appear in chat history48- **Named by convention**: `<PROVIDER>_API_KEY` or custom names set in the credential config4950You never need to ask the user for API keys directly. If a credential is configured, it's available as an env var. If it's not configured, tell the user which credential to add in the agent settings.5152## The Skill System5354Skills are markdown files that teach agents how to use tools, APIs, and workflows. They are documentation, not executable code.5556### Loading Skills5758```json59{ "tool": "skills", "action": "list" }60{ "tool": "skills", "action": "read", "name": "tools/files" }61{ "tool": "skills", "action": "search", "query": "github pr" }62```6364### Skill Locations6566- `skills/` -- built-in skills shipped with SwarmClaw67- `data/skills/` -- user-created skills added at runtime6869### When to Load Skills7071- Before using a tool you're unfamiliar with72- When a task involves an API or workflow you haven't used before73- When the user asks you to do something and you're unsure of the best approach7475## Agent Capabilities7677### Memory7879Agents have persistent memory across sessions:8081- **Working memory** (session-scoped): scratch notes, intermediate results82- **Durable memory** (cross-session): user preferences, project facts, decisions83- Memories are automatically surfaced in context when relevant84- Store important learnings proactively -- don't wait to be asked8586### Dreaming8788Agents with dreaming enabled automatically consolidate memories during idle periods. You can also trigger a dream manually:8990#### Check dream status91```json92{ "tool": "memory", "action": "list", "category": "dream_reflection" }93```9495#### Manual dream trigger96Use the platform API to trigger a dream cycle:97```json98{ "tool": "execute", "command": "curl -s -X POST http://localhost:3456/api/memory/dream -H 'Content-Type: application/json' -d '{\"agentId\":\"YOUR_AGENT_ID\"}'" }99```100101Dream cycles produce `dream_reflection` and `consolidated_insight` memories that help maintain a clean, coherent memory store over time.102103### Delegation104105Agents can delegate work to other agents:106107- **delegate**: route a task to a specific agent and wait for the result108- **spawn**: create a subagent that runs independently (fire-and-forget or session-based)109- Use `agents.list` to discover available agents and their specializations110111### Connectors112113Agents can communicate through external platforms:114115- Discord, Slack, Telegram, and custom webhooks116- Messages sent via `platform` tool with `communicate.send_message`117- Inbound messages from connectors trigger agent sessions automatically118119### MCP Servers120121Agents can also use tools served by external Model Context Protocol servers:122123- Register MCP servers under **MCP Servers** in the UI (stdio / sse / streamable-http transports supported).124- Quick-setup presets include **SwarmVault** (local-first knowledge vault) and **SwarmDock** (agent marketplace — browse tasks, bid, submit work, earn USDC). The SwarmDock preset is pre-filled for the hosted endpoint at `https://swarmdock-api.onrender.com/mcp` and just needs the Bearer header (generate a key and register an agent at `swarmdock.ai/mcp/connect`). See `docs/mcp-servers.md` for the full workflow.125- Once attached to an agent, MCP tools appear alongside the built-in tools at execution time.126127## Workspace Conventions128129- The workspace root is the agent's working directory130- File paths in tool calls are relative to the workspace root131- `/workspace/...` paths are resolved to the workspace root automatically132- The `$WORKSPACE` env var points to the workspace root in execute tool runs133134## Best Practices1351361. **Load skills before unfamiliar operations.** A 30-second skill read prevents minutes of trial and error.1371382. **Use the right tool for the job.** Don't use `execute` with `echo > file.txt` when `files` write action is cleaner. Don't use `browser` when `curl` in `execute` suffices.1391403. **Store important context in memory.** If you learn something that would help in future sessions (user preference, project convention, API quirk), store it immediately.1411424. **Ask rather than guess.** When genuinely uncertain about user intent, use `communicate.ask_human`. A brief clarification is better than wasted work on the wrong approach.1431445. **Delegate when appropriate.** If another agent is better suited for a subtask, delegate. Check `agents.list` to know what's available.1451466. **Be explicit about what you're doing.** When running commands, editing files, or making decisions, explain your reasoning. Transparency builds trust.1471487. **Respect file access boundaries.** Stay within the workspace unless the agent has machine-scope access. Never write to system directories.1491508. **Handle errors gracefully.** When a tool call fails, read the error message, diagnose the issue, and retry with a corrected approach. Don't repeat the same failing call.