create-plugin
Create a new Claude Code plugin with proper directory structure and manifest. Use when the user wants to create a new plugin from scratch. Sets up plugin.json, directory structure, and optional components.
What this skill does
# Create Plugin Skill
Create new Claude Code plugins with proper structure and configuration.
## Plugin Directory Structure
```
plugin-name/
├── .claude-plugin/ # Required: Metadata directory
│ └── plugin.json # Required: Plugin manifest
├── commands/ # Optional: Command definitions
│ ├── command1.md
│ └── command2.md
├── agents/ # Optional: Agent definitions
│ ├── agent1.md
│ └── agent2.md
├── skills/ # Optional: Agent Skills
│ ├── skill-name/
│ │ └── SKILL.md
│ └── another-skill/
│ ├── SKILL.md
│ └── scripts/
├── hooks/ # Optional: Hook configurations
│ ├── hooks.json # Main hook config
│ └── additional-hooks.json
├── .mcp.json # Optional: MCP server definitions
├── scripts/ # Optional: Hook and utility scripts
│ ├── script1.sh
│ └── script2.py
├── LICENSE # Optional: License file
├── CHANGELOG.md # Optional: Version history
└── README.md # Optional: Documentation
```
## Plugin Manifest (plugin.json)
### Required Fields
| Field | Type | Description |
|-------|------|-------------|
| `name` | string | Plugin identifier (kebab-case recommended) |
| `version` | string | Semantic version (e.g., "1.2.0") |
| `description` | string | Brief description of the plugin |
### Optional Fields
| Field | Type | Description |
|-------|------|-------------|
| `author` | object | Author information |
| `author.name` | string | Author's name (required if author present) |
| `author.email` | string | Author's email |
| `author.url` | string | Author's website or GitHub profile |
| `homepage` | string | Plugin documentation URL |
| `repository` | string | Git repository URL |
| `license` | string | License identifier (e.g., "MIT", "Apache-2.0") |
| `keywords` | array | Searchable keywords |
| `commands` | string or array | Custom command locations (directory or file paths) |
| `agents` | array | Array of agent file paths (must end with .md) |
| `hooks` | string | Custom hook configuration file location |
| `mcpServers` | string | Custom MCP server configuration file location |
## CRITICAL: Manifest Format
### Commands Configuration
Commands MUST be a **string** (directory path) or **array of strings** (file paths):
**CORRECT - Directory path:**
```json
{
"commands": "./commands/"
}
```
**CORRECT - Array of file paths:**
```json
{
"commands": ["./commands/lint.md", "./commands/format.md"]
}
```
**CORRECT - Single custom path:**
```json
{
"commands": "./custom/commands/special.md"
}
```
**WRONG - Object format (INVALID):**
```json
{
"commands": {
"my-command": {
"description": "...",
"source": "..."
}
}
}
```
### Agents Configuration
Agents MUST be an **array of file paths** ending with `.md`:
**CORRECT:**
```json
{
"agents": [
"./agents/my-agent.md",
"./agents/another-agent.md"
]
}
```
**CORRECT - Single agent:**
```json
{
"agents": ["./agents/expert.md"]
}
```
**WRONG - Directory path (INVALID):**
```json
{
"agents": "./agents/"
}
```
**WRONG - Object format (INVALID):**
```json
{
"agents": {
"agent-name": {
"description": "...",
"file": "..."
}
}
}
```
### Skills Auto-Discovery
Skills are automatically discovered from the `skills/` directory. No manifest entry needed.
Each skill must be in its own folder with a `SKILL.md` file:
```
skills/
├── skill-name/
│ └── SKILL.md
└── another-skill/
└── SKILL.md
```
## Example Manifests
### Minimal
```json
{
"name": "my-plugin",
"version": "1.0.0",
"description": "A simple plugin for Claude Code"
}
```
### With Commands and Agents
```json
{
"name": "code-quality",
"version": "1.0.0",
"description": "Code quality tools including linting and review",
"author": {
"name": "Developer",
"email": "[email protected]"
},
"commands": "./commands/",
"agents": [
"./agents/code-reviewer.md"
]
}
```
### Complete
```json
{
"name": "enterprise-plugin",
"version": "1.2.0",
"description": "Enterprise-grade development plugin",
"author": {
"name": "Jane Developer",
"email": "[email protected]",
"url": "https://github.com/janedev"
},
"homepage": "https://docs.example.com/plugin",
"repository": "https://github.com/janedev/enterprise-plugin",
"license": "MIT",
"keywords": ["enterprise", "security", "compliance"],
"commands": ["./custom/commands/special.md"],
"agents": ["./custom/agents/security-expert.md"],
"hooks": "./config/hooks.json",
"mcpServers": "./mcp-config.json"
}
```
## Creation Process
1. **Plan the plugin**
- Define the plugin's purpose
- List components needed (commands, agents, skills)
- Choose a descriptive name (kebab-case)
2. **Create directory structure**
```bash
mkdir -p plugin-name/.claude-plugin
mkdir -p plugin-name/agents
mkdir -p plugin-name/commands
mkdir -p plugin-name/skills
```
3. **Create plugin.json**
```json
{
"name": "plugin-name",
"version": "1.0.0",
"description": "Plugin description",
"author": {
"name": "Author Name"
},
"commands": "./commands/",
"agents": ["./agents/my-agent.md"]
}
```
4. **Add components**
- Add agents to `agents/` with proper frontmatter
- Add commands to `commands/` with proper frontmatter
- Add skills to `skills/skill-name/SKILL.md`
5. **IMPORTANT: Register in marketplace.json**
Every new plugin MUST be added to `.claude-plugin/marketplace.json`
6. **Validate the plugin**
```bash
./scripts/validate-all-plugins.sh plugin-name
```
7. **Commit the changes**
Include both the plugin directory AND marketplace.json
## Adding to Marketplace (REQUIRED)
**Every new plugin must be registered in `.claude-plugin/marketplace.json`.**
Add a new entry to the `plugins` array:
```json
{
"plugins": [
// ... existing plugins ...
{
"name": "plugin-name",
"description": "Brief plugin description",
"source": "./plugins/plugin-name",
"category": "development"
}
]
}
```
### Marketplace Entry Fields
| Field | Required | Description |
|-------|----------|-------------|
| `name` | Yes | Must match plugin.json name |
| `description` | Yes | Brief description for marketplace listing |
| `source` | Yes | Relative path to plugin directory |
| `category` | Yes | One of: `productivity`, `development`, `security` |
### Categories
- `productivity` - Workflow, project management, documentation tools
- `development` - Code quality, testing, language-specific tools
- `security` - Security, compliance, privacy tools
## Testing Your Plugin
1. Add marketplace: `/plugin marketplace add ./path-to-marketplace`
2. Install plugin: `/plugin install plugin-name@marketplace-name`
3. Verify with `/help` to see commands
4. Test components individually
## Common Validation Errors
| Error | Cause | Fix |
|-------|-------|-----|
| `Missing required file: .claude-plugin/plugin.json` | No manifest | Create `.claude-plugin/plugin.json` |
| `plugin.json missing required fields` | Missing name, version, or description | Add all required fields |
| `'author' must be an object` | Author is a string | Use object format with `name` field |
| `Invalid JSON syntax` | Trailing commas, missing quotes | Fix JSON syntax |
| `agents: Invalid input: must end with ".md"` | Using directory path for agents | Use array of file paths: `["./agents/name.md"]` |
## Best Practices
1. **Use semantic versioning** for the `version` field
2. **Include descriptive keywords** for better discoverability
3. **Provide author information** for attribution and support
4. **Link to repository** for open-source contributions
5. **Document your plugin** with a README.md
6. **Track changes** with CHANGELOG.md
7. **Use clear names** that describe the plugin's purpose
8. **Keep descriptions concise** but informative
## Migration Guide
If youRelated in AI Agents
skill-development
IncludedComprehensive meta-skill for creating, managing, validating, auditing, and distributing Claude Code skills and slash commands (unified in v2.1.3+). Provides skill templates, creation workflows, validation patterns, audit checklists, naming conventions, YAML frontmatter guidance, progressive disclosure examples, and best practices lookup. Use when creating new skills, validating existing skills, auditing skill quality, understanding skill architecture, needing skill templates, learning about YAML frontmatter requirements, progressive disclosure patterns, tool restrictions (allowed-tools), skill composition, skill naming conventions, troubleshooting skill activation issues, creating custom slash commands, configuring command frontmatter, using command arguments ($ARGUMENTS, $1, $2), bash execution in commands, file references in commands, command namespacing, plugin commands, MCP slash commands, Skill tool configuration, or deciding between skills vs slash commands. Delegates to docs-management skill for official documentation.
reprompter
IncludedTransform messy prompts into well-structured, effective prompts — single or multi-agent. Use when: "reprompt", "reprompt this", "clean up this prompt", "structure my prompt", rough text needing XML tags and best practices, "reprompter teams", "repromptception", "run with quality", "smart run", "smart agents", multi-agent tasks, audits, parallel work, anything going to agent teams. Don't use when: simple Q&A, pure chat, immediate execution-only tasks. See "Don't Use When" section for details. Outputs: Structured XML/Markdown prompt, quality score (before/after), optional team brief + per-agent sub-prompts, agent team output files. Success criteria: Single mode quality score ≥ 7/10; Repromptception per-agent prompt quality score 8+/10; all required sections present, actionable and specific.
adaptive-compaction
IncludedAdaptive add-on policy and recovery layer that decides WHEN to compact, prune, snapshot, or fork -- replacing fixed-percent auto-compaction across Claude Code, Codex, and MCP-capable hosts. Trigger on auto-compact timing or damage: "when should I compact", "is it safe to compact now or start a fresh session", "auto-compact fires too early/mid-task", "switching to an unrelated task but the window still has space", "context rot", "answers get worse the longer the session runs", "the agent forgot the plan or my decisions after it summarized", "add a layer on top that manages context without changing the agent", raising autoCompactWindow to give the policy room, or installing/tuning a cross-tool compaction policy or PreCompact hook -- even when "compaction" is never said but the problem is context-window pressure or post-summarization memory loss. Do NOT use to summarize a conversation, build RAG, write a summarization prompt (decides WHEN not HOW), or answer max-context-length trivia.
agent-skill-creator
IncludedCreate cross-platform agent skills from workflow descriptions. Activates when users ask to create an agent, automate a repetitive workflow, create a custom skill, or need advanced agent creation. Triggers on phrases like create agent for, automate workflow, create skill for, every day I have to, daily I need to, turn process into agent, need to automate, create a cross-platform skill, validate this skill, export this skill, migrate this skill. Supports single skills, multi-agent suites, transcript processing, template-based creation, interactive configuration, cross-platform export, and spec validation.
llm-wiki
IncludedUse when building or maintaining a persistent personal knowledge base (second brain) in Obsidian where an LLM incrementally ingests sources, updates entity/concept pages, maintains cross-references, and keeps a synthesis current. Triggers include "second brain", "Obsidian wiki", "personal knowledge management", "ingest this paper/article/book", "build a research wiki", "compound knowledge", "Memex", or whenever the user wants knowledge to accumulate across sessions instead of being re-derived by RAG on every query.
skill-master
IncludedAgent Skills authoring, evaluation, and optimization. Create, edit, validate, benchmark, and improve skills following the agentskills.io specification. Use when designing SKILL.md files, structuring skill folders (references, scripts, assets), ingesting external documentation into skills, running trigger evals, benchmarking skill quality, optimizing descriptions, or performing blind A/B comparisons. Keywords: agentskills.io, SKILL.md, skill authoring, eval, benchmark, trigger optimization.