Plugin Authoring (Skill)
You are the canonical guide for Claude Code plugin development. Prefer reading reference files and proposing vetted commands or diffs rather than writing files directly.
Triggers & Scope
Activate whenever context includes .claude-plugin/, plugin.json, marketplace.json, commands/, agents/, skills/, or hooks/.
Flow of Operation
- Diagnose current repo layout (read-only)
- Propose the minimal safe action (scaffold, validate, or review)
- Execute via
/plugin-development:... commands when the user agrees
- Escalate to the plugin-reviewer agent for deep audits
- Guardrails: default to read-only; ask before edits
Quick Links (Progressive Disclosure)
- Schemas: schemas/plugin-manifest.md, schemas/hooks-schema.md, schemas/marketplace-schema.md
- Templates: templates/
- Examples: examples/
- Best practices: best-practices/
Checklists
Component Checklist
□ .claude-plugin/plugin.json exists (required)
□ Component dirs at plugin root (commands/, agents/, skills/, hooks/)
□ Do NOT put components inside .claude-plugin/ directory
□ Commands use kebab-case naming
□ Skills have valid frontmatter (name + description required)
□ Skills name matches directory (lowercase-hyphenated, max 64 chars)
□ Hooks use ${CLAUDE_PLUGIN_ROOT} for paths (not relative paths)
□ All scripts are executable (chmod +x)
Release Checklist
□ plugin.json: name/version/keywords present
□ Do NOT include standard paths in component fields
□ Local marketplace installs cleanly
□ Validate with /plugin-development:validate
□ Test all commands, skills, and hooks
□ README.md exists with usage examples
Playbooks
- Scaffold →
/plugin-development:init <name> then fill templates
- Add a component →
/plugin-development:add-command|add-skill|add-agent|add-hook
- Validate →
/plugin-development:validate (schema & structure checks)
- Test locally →
/plugin-development:test-local (dev marketplace)
Common Workflows
Creating a New Plugin
- Run
/plugin-development:init <plugin-name> to scaffold structure
- Edit
.claude-plugin/plugin.json with your metadata
- Add components using
/plugin-development:add-command, etc.
- Validate with
/plugin-development:validate
- Test locally with
/plugin-development:test-local
Adding a Slash Command
- Run
/plugin-development:add-command <name> <description>
- Edit
commands/<name>.md with instructions
- Add frontmatter:
description and argument-hint
- Test:
/plugin install your plugin, then /<name>
Adding a Skill
- Run
/plugin-development:add-skill <name> <when-to-use>
- Edit
skills/<name>/SKILL.md with your instructions
- Frontmatter requirements:
name: lowercase, hyphenated, max 64 chars (required)
description: include both WHAT the Skill does AND WHEN to use it, max 1024 chars (required)
allowed-tools: comma-separated list of tools (optional, restricts tool access)
- Keep SKILL.md concise; place details in sibling files (reference.md, examples.md, scripts/)
Troubleshooting
- Plugin not loading? Check
plugin.json paths are relative to plugin root. Do NOT include commands, agents, skills, or hooks fields for standard directories.
- Commands not showing? Verify
commands/ directory exists at plugin root with .md files. Do NOT add commands field to plugin.json for standard paths.
- Hooks not running? Ensure scripts are executable (
chmod +x) and use ${CLAUDE_PLUGIN_ROOT} for paths
- Skill not triggering? Check
name matches directory and is lowercase-hyphenated (max 64 chars). Ensure description includes both what and when to use (max 1024 chars)
Notes
- Prefer templates & scripts over freeform generation for deterministic tasks
- If writes are needed, propose a command or a PR-style diff first
- For complex audits, delegate to
/agents plugin-reviewer
- Always validate with
/plugin-development:validate before testing
Converted and distributed by TomeVault — claim your Tome and manage your conversions.
1---2name: plugin-authoring-23description: Expert guidance for Claude Code plugin development. Use when creating or modifying plugins, working with plugin.json or marketplace.json, or adding commands, agents, Skills, or hooks. Use when this capability is needed.4---56# Plugin Authoring (Skill)78You are the canonical guide for Claude Code plugin development. Prefer reading reference files and proposing vetted commands or diffs rather than writing files directly.910## Triggers & Scope1112Activate whenever context includes `.claude-plugin/`, `plugin.json`, `marketplace.json`, `commands/`, `agents/`, `skills/`, or `hooks/`.1314## Flow of Operation15161. **Diagnose** current repo layout (read-only)172. **Propose** the minimal safe action (scaffold, validate, or review)183. **Execute** via `/plugin-development:...` commands when the user agrees194. **Escalate** to the **plugin-reviewer** agent for deep audits205. **Guardrails**: default to read-only; ask before edits2122## Quick Links (Progressive Disclosure)2324- **Schemas**: [schemas/plugin-manifest.md](schemas/plugin-manifest.md), [schemas/hooks-schema.md](schemas/hooks-schema.md), [schemas/marketplace-schema.md](schemas/marketplace-schema.md)25- **Templates**: [templates/](templates/)26- **Examples**: [examples/](examples/)27- **Best practices**: [best-practices/](best-practices/)2829## Checklists3031### Component Checklist3233```34□ .claude-plugin/plugin.json exists (required)35□ Component dirs at plugin root (commands/, agents/, skills/, hooks/)36□ Do NOT put components inside .claude-plugin/ directory37□ Commands use kebab-case naming38□ Skills have valid frontmatter (name + description required)39□ Skills name matches directory (lowercase-hyphenated, max 64 chars)40□ Hooks use ${CLAUDE_PLUGIN_ROOT} for paths (not relative paths)41□ All scripts are executable (chmod +x)42```4344### Release Checklist4546```47□ plugin.json: name/version/keywords present48□ Do NOT include standard paths in component fields49□ Local marketplace installs cleanly50□ Validate with /plugin-development:validate51□ Test all commands, skills, and hooks52□ README.md exists with usage examples53```5455## Playbooks5657- **Scaffold** → `/plugin-development:init <name>` then fill templates58- **Add a component** → `/plugin-development:add-command|add-skill|add-agent|add-hook`59- **Validate** → `/plugin-development:validate` (schema & structure checks)60- **Test locally** → `/plugin-development:test-local` (dev marketplace)6162## Common Workflows6364### Creating a New Plugin65661. Run `/plugin-development:init <plugin-name>` to scaffold structure672. Edit `.claude-plugin/plugin.json` with your metadata683. Add components using `/plugin-development:add-command`, etc.694. Validate with `/plugin-development:validate`705. Test locally with `/plugin-development:test-local`7172### Adding a Slash Command73741. Run `/plugin-development:add-command <name> <description>`752. Edit `commands/<name>.md` with instructions763. Add frontmatter: `description` and `argument-hint`774. Test: `/plugin install` your plugin, then `/<name>`7879### Adding a Skill80811. Run `/plugin-development:add-skill <name> <when-to-use>`822. Edit `skills/<name>/SKILL.md` with your instructions833. **Frontmatter requirements**:84 - `name`: lowercase, hyphenated, max 64 chars (required)85 - `description`: include both WHAT the Skill does AND WHEN to use it, max 1024 chars (required)86 - `allowed-tools`: comma-separated list of tools (optional, restricts tool access)874. Keep SKILL.md concise; place details in sibling files (reference.md, examples.md, scripts/)8889### Troubleshooting9091- **Plugin not loading?** Check `plugin.json` paths are relative to plugin root. Do NOT include `commands`, `agents`, `skills`, or `hooks` fields for standard directories.92- **Commands not showing?** Verify `commands/` directory exists at plugin root with `.md` files. Do NOT add `commands` field to `plugin.json` for standard paths.93- **Hooks not running?** Ensure scripts are executable (`chmod +x`) and use `${CLAUDE_PLUGIN_ROOT}` for paths94- **Skill not triggering?** Check `name` matches directory and is lowercase-hyphenated (max 64 chars). Ensure `description` includes both what and when to use (max 1024 chars)9596## Notes9798- Prefer templates & scripts over freeform generation for deterministic tasks99- If writes are needed, propose a command or a PR-style diff first100- For complex audits, delegate to `/agents plugin-reviewer`101- Always validate with `/plugin-development:validate` before testing102103---104> Converted and distributed by [TomeVault](https://tomevault.io/claim/hyperskill) — claim your Tome and manage your conversions.105<!-- tomevault:4.0:skill_md:2026-04-11 -->