How to Build and Publish OpenClaw Skills
A skill is a pluggable module that teaches your agent a new ability — like hiring an employee AND sending them to a training course. The OpenClaw ecosystem already has 4 dedicated mindmap MCP servers on GitHub, plus Mermaid as a rendering engine. Today, we’ll build one ourselves.
Anatomy of an OpenClaw Skill
Every skill follows a simple structure:
mindmap-generator/
├── SKILL.md ← Required (the brain)
├── scripts/ ← Executable code
├── references/ ← Context docs for the agent
└── assets/ ← Output templates
Only SKILL.md is required. Everything else is optional.
The SKILL.md File
This is the only file OpenClaw needs. It has two parts:
- YAML Frontmatter — tells OpenClaw when to activate the skill:
---
name: mindmap-generator
description: Generates visual mindmap images from conversations, goals, decisions, and daily priorities.
metadata: {"openclaw": {"emoji": "🗺️", "requires": {"bins": ["node","npx"]}}}
---
- Markdown Body — tells the agent how to use the skill.
Step 1: Extract Hierarchical Structure
From the user's input, extract a tree structure. Level 1 = major categories, Level 2 = details.
Step 2: Write Mermaid Mindmap Syntax
Format using Mermaid's indentation-based syntax.
Step 3: Render to PNG
Run: ./scripts/render_mindmap.sh input.mmd output.png
Step 4: Send via Telegram
Run: ./scripts/send_telegram_photo.sh output.png "caption" $CHAT_ID
Publish to ClawHub
Once tested locally, publishing is easy:
clawhub login
clawhub publish . --slug mindmap-generator --name "Mindmap Generator" --version 1.0.0
That’s it. Your skill is live. Anyone can now install it using clawhub install mindmap-generator.