Plugin Structure

Guide Claude Code plugin structure with manifest configuration and directory layouts.

1|Updated Jan 27, 2026
One-click install
npx skills add https://github.com/kurohit2/MlProject --skill plugin-structure-kurohit2
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: Plugin Structure
Source: https://github.com/kurohit2/MlProject/tree/main/.agents/skills/plugin-structure
Command: npx skills add https://github.com/kurohit2/MlProject --skill plugin-structure-kurohit2

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

The plugin-structure guidance helps teams design, organize, and activate Claude Code plugins with consistent directory layouts, manifest configuration, and auto-discovery enabling reliable tool integration.

Core Features & Use Cases

  • Provides a canonical directory structure for commands, agents, skills, hooks, and MCP servers.
  • Explains how to reference portable paths using ${CLAUDE_PLUGIN_ROOT} and how to structure required vs. optional components.
  • Offers practical patterns for component discovery, validation, and maintenance across projects.

Quick Start

Create a plugin that follows the standard layout by including a manifest at .claude-plugin/plugin.json, placing commands under commands/ and a SKILL.md under skills/.

Frequently Asked Questions about Plugin Structure

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I structure a Claude Code plugin for command and agent auto-discovery?▼

Claude Code plugin structure requires a manifest at .claude-plugin/plugin.json, with commands placed under commands/ and a SKILL.md under skills/ to enable automatic component discovery and safe integration.

What is ${CLAUDE_PLUGIN_ROOT} used for in plugin directory layout?▼

${CLAUDE_PLUGIN_ROOT} provides portable path referencing within your plugin directory layout, ensuring safe integration of scripts, references, and assets across diverse environments without hardcoding absolute file paths.

How do I configure a manifest for a Claude Code plugin with hooks and MCP servers?▼

Configuring a Claude Code plugin manifest involves placing plugin.json at .claude-plugin/ and organizing hooks and MCP servers into the canonical directory structure to enable validation and auto-discovery.

When do I need to organize optional resources like scripts and assets in a plugin?▼

Optional resources like scripts, references, and assets require specific directory placement within the plugin structure when you need auto-discovery and safe integration of supplementary components across diverse environments.

What naming conventions should I follow for Claude Code plugin components?▼

Claude Code plugin naming conventions dictate consistent directory layouts for commands, agents, skills, hooks, and MCP servers to ensure reliable tool integration and proper component validation across projects.

Can I scaffold a Claude Code plugin without including optional components like scripts?▼

Yes, you can scaffold a Claude Code plugin with only required components like the manifest and commands directory, as optional resources such as scripts, references, and assets are handled separately for auto-discovery.