Method | Skill Name | Scenario |
Standalone configuration ( .codebuddy/ directory) | /hello | Personal workflows, project-specific customization, and quick experiments |
Plugin (directory containing .codebuddy-plugin/plugin.json) | /plugin-name:hello | Team sharing, community distribution, versioned release, and cross-project reuse |
/hello or /deploy./my-plugin:hello (namespaces prevent conflicts between plugins)..codebuddy/, and convert it to a plugin when you are ready to share.--plugin-dir parameter./plugin command is not visible, update CodeBuddy Code to the latest version.mkdir my-first-plugin
.codebuddy-plugin/plugin.json and defines the plugin's identity information: name, description, and version. CodeBuddy Code uses this metadata to display your plugin in the plugin manager. Create the .codebuddy-plugin directory inside the plugin directory:mkdir my-first-plugin/.codebuddy-plugin
my-first-plugin/.codebuddy-plugin/plugin.json with the following content:{"name": "my-first-plugin","description": "A greeting plugin to learn the basics","version": "1.0.0","author": {"name": "Your Name"}}
Field | Purpose |
name | Unique identifier and skill namespace. Skills use this as a prefix (for example, /my-first-plugin:hello) |
description | Displayed when the plugin is browsed or installed in the plugin manager. |
version | |
author | Optional. Used for attribution. |
skills/ directory. Each skill is a folder that contains a SKILL.md file. The folder name becomes the skill name, prefixed with the plugin namespace (in a plugin named my-first-plugin, hello/ creates /my-first-plugin:hello). Create the skill directory in the plugin directory:mkdir -p my-first-plugin/skills/hello
my-first-plugin/skills/hello/SKILL.md with the following content:---description: Greet the user with a friendly messagedisable-model-invocation: true---Greet the user warmly and ask how you can help them today.
--plugin-dir flag to load your plugin:codebuddy --plugin-dir ./my-first-plugin
/my-first-plugin:hello
/help to see your skill listed under the plugin namespace./my-first-plugin:hello) to prevent conflicts between skills with the same name in different plugins. To change the namespace prefix, update the name field in plugin.json.$ARGUMENTS placeholder captures any text the user provides after the skill name. Update your SKILL.md file:---description: Greet the user with a personalized message---# Hello SkillGreet the user named "$ARGUMENTS" warmly and ask how you can help them today. Make the greeting personal and encouraging.
/reload-plugins to pick up the changes, then try the skill with your name:/my-first-plugin:hello Alex
.codebuddy-plugin/plugin.json): describes the plugin's metadataskills/): contains your custom skills$ARGUMENTS): captures user input to enable dynamic behavior--plugin-dir parameter is intended for development and testing. When you are ready to share your plugin with others, see Plugin Marketplace.commands/, agents/, skills/, or hooks/ inside the .codebuddy-plugin/ directory. Only plugin.json goes inside .codebuddy-plugin/. All other directories must be at the plugin root level.Directory | Position | Purpose |
.codebuddy-plugin/ | Plugin root directory | Contains the plugin.json manifest |
commands/ | Plugin root directory | Slash commands in Markdown format |
agents/ | Plugin root directory | Custom agent definitions |
skills/ | Plugin root directory | Agent skills that include the SKILL.md file |
hooks/ | Plugin root directory | hooks.json event handler |
.mcp.json | Plugin root directory | MCP server configuration |
.lsp.json | Plugin root directory | LSP server configuration (code intelligence) |
bin/ | Plugin root directory | Executable files added to the Bash tool PATH when the plugin is enabled |
settings.json | Plugin root directory |
my-plugin/├── .codebuddy-plugin/ # Metadata directory (required)│ └── plugin.json # Plugin manifest file├── commands/ # Commands directory (optional)│ └── example.md├── agents/ # Agents directory (optional)│ └── example.md├── skills/ # Skills directory (optional)│ └── code-review/│ └── SKILL.md├── hooks/ # Hooks directory (optional)│ └── hooks.json├── bin/ # Executable files directory (optional)│ └── my-tool├── .mcp.json # MCP configuration file (optional)├── .lsp.json # LSP configuration file (optional)└── settings.json # Default settings file (optional)
skills/ directory in the plugin root directory, which contains skill folders with SKILL.md files:my-plugin/├── .codebuddy-plugin/│ └── plugin.json└── skills/└── code-review/└── SKILL.md
SKILL.md must contain frontmatter with name and description fields, followed by instructions:---name: code-reviewdescription: Reviews code for best practices and potential issues. Use when reviewing code, checking PRs, or analyzing code quality.---When reviewing code, check for:1. Code organization and structure2. Error handling3. Security concerns4. Test coverage
/reload-plugins to load the skills. For a complete guide to writing skills, including progressive disclosure and tool limitations, see Agent Skills.commands/example.md---description: "Example command description"argument-hint: "[parameter]"---This is an example command. It is executed when the user enters /my-plugin:example.Arguments: $ARGUMENTS
/plugin-name:command-name. For details, see the Slash Commands documentation.jq to extract fields.hooks/hooks.json{"hooks": {"PostToolUse": [{"matcher": "Write|Edit","hooks": [{"type": "command","command": "jq -r '.tool_input.file_path' | xargs npm run lint:fix"}]}]}}
hooks/hooks.json file are automatically merged with user-level and project-level hooks when the plugin is enabled (without overwriting them), and are not subject to the allowUntrustedFrontmatterHooks gate (which applies only to hooks declared in Agent / Skill frontmatter).command, hooks also support three execution methods: type: prompt (semantic determination by a small model), type: agent (subagent validation), and type: http (POST/PUT/PATCH to a specified URL). For details, see the Hooks documentation. If your plugin also needs to carry frontmatter hooks with a Skill, see Skills documentation - Configuring Hooks in a Skill (note that this path is subject to a security gate). For detailed instructions, see the Hooks documentation..lsp.json file to your plugin:{"go": {"command": "gopls","args": ["serve"],"extensionToLanguage": {".go": "go"}}}
{"python": {"command": "pylsp","args": [],"extensionToLanguage": {".py": "python"}},"rust": {"command": "rust-analyzer","args": [],"extensionToLanguage": {".rs": "rust"}}}
go install golang.org/x/tools/gopls@latestpip install python-lsp-serverrustup component add rust-analyzersettings.json file in its root directory to apply default configuration when the plugin is enabled. Currently, only the agent key is supported. Setting agent activates one of the plugin's custom agents as the main thread, applying its system prompt, tool limits, and model. This allows the plugin to change the default behavior of CodeBuddy Code when the plugin is enabled.{"agent": "security-reviewer"}
security-reviewer agent defined in the plugin's agents/ directory. Settings in settings.json take precedence over settings declared in plugin.json. Unknown keys are silently ignored.--plugin-dir parameter to test your plugin during development. This loads your plugin directly without installation.codebuddy --plugin-dir ./my-plugin
--plugin-dir plugin has the same name as an installed marketplace plugin, the local copy takes precedence in that session. This allows you to test changes to an installed plugin without uninstalling it. The only exception is a marketplace plugin that is force-enabled through managed settings, which cannot be overridden./reload-plugins to get updates without restarting. This reloads plugins, skills, agents, hooks, plugin MCP servers, and plugin LSP servers. Test your plugin components:/plugin-name:skill-name/agents.codebuddy --plugin-dir ./plugin-one --plugin-dir ./plugin-two
.codebuddy-plugin/.--debug parameter to view detailed logs..codebuddy-plugin/plugin.json:{"name": "my-plugin","version": "1.0.0","description": "Plugin description","author": {"name": "Author name","email": "author@example.com"},"homepage": "https://github.com/username/my-plugin","repository": "https://github.com/username/my-plugin","keywords": ["example"],"category": "Development Tools","commands": [],"agents": [],"skills": [],"hooks": "./hooks/hooks.json"}
README.md that explains installation and usage.plugin.json..codebuddy/ directory, you can convert them into plugins for easier sharing and distribution.mkdir -p my-plugin/.codebuddy-plugin
my-plugin/.codebuddy-plugin/plugin.json:{"name": "my-plugin","description": "Migrated from standalone configuration","version": "1.0.0"}
# Copy the commandcp -r .codebuddy/commands my-plugin/# Copy the agent (if any)cp -r .codebuddy/agents my-plugin/# Copy the skill (if any)cp -r .codebuddy/skills my-plugin/
mkdir my-plugin/hooks
my-plugin/hooks/hooks.json and place the hooks configuration in it. Copy the hooks object from .codebuddy/settings.json or settings.local.json, as the format is the same. The command receives the hook input JSON data through standard input, and you can use jq to extract fields:{"hooks": {"PostToolUse": [{"matcher": "Write|Edit","hooks": [{"type": "command","command": "jq -r '.tool_input.file_path' | xargs npm run lint:fix"}]}]}}
codebuddy --plugin-dir ./my-plugin
/agents, and verify that hooks trigger correctly.Standalone Configuration ( .codebuddy/) | Plugins |
Available in only one project | Can be shared through the marketplace |
Files are in .codebuddy/commands/ | Files are in plugin-name/commands/ |
Hooks are in settings.json | Hooks are in hooks/hooks.json |
Manual copy is required for sharing. | Install using /plugin install |
.codebuddy/ to avoid duplication. The plugin version is used preferentially during loading.plugin.json.--plugin-dir before publishing./plugin and go to the "Installed" tab to check.plugin.json is correct./reload-plugins to reload plugins.--debug mode to view loading logs.commands/ at the plugin root, not inside .codebuddy-plugin/./reload-plugins to refresh.# Verify the plugin formatcodebuddy plugin validate /path/to/plugin# Test locally with --plugin-dircodebuddy --plugin-dir ./my-plugin# Test the plugin's skills/my-plugin:skill-name
Was this page helpful?
You can also Contact sales or Submit a Ticket for help.
Help us improve! Rate your documentation experience in 5 mins.
Feedback