- Skills: Specialized knowledge and workflows
- Hooks: Event handlers for tool lifecycle
- MCP Config: External tool server configurations
- Agents: Specialized agent definitions
- Commands: Slash commands
Plugin Structure
See the example_plugins directory for a complete working plugin structure.
plugin-name
.plugin
plugin.json
skills
skill-name
hooks
hooks.json
agents
agent-name.md
commands
command-name.md
.mcp.json
README.md
plugin-name/.plugin/plugin.json, is required.
Plugin Manifest
The manifest fileplugin-name/.plugin/plugin.json defines plugin metadata:
Skills
Skills are defined in markdown files with YAML frontmatter:Hooks
Hooks are defined inhooks/hooks.json:
MCP Configuration
MCP servers are configured in.mcp.json:
Using Plugin Components
The ready-to-run example is available here!Brief explanation on how to use a plugin with an agent.
Accessing Components
You can access the different plugin components to see which ones are available.Ready-to-run Example
The example below demonstrates plugin loading via Conversation and plugin management utilities (install, list, load, enable, disable, and uninstall).This example is available on GitHub: examples/05_skills_and_plugins/02_loading_plugins/main.py
examples/05_skills_and_plugins/02_loading_plugins/main.py
The model name should follow the LiteLLM convention:
provider/model_name (e.g., anthropic/claude-sonnet-4-5-20250929, openai/gpt-4o).
The LLM_API_KEY should be the API key for your chosen provider.Installing Plugins to Persistent Storage
The SDK provides utilities to install plugins to a local directory (~/.openhands/plugins/installed/ by default). Installed plugins are tracked
in .installed.json, which stores metadata including a persistent enabled
flag.
Use list_installed_plugins() to see all tracked plugins (enabled and
disabled). Use load_installed_plugins() to load only enabled plugins.
install_plugin(), enable_plugin(), disable_plugin(), and
uninstall_plugin() are exposed from openhands.sdk.plugin, which gives the
CLI a clean SDK surface for /plugin install, /plugin enable,
/plugin disable, and /plugin uninstall.
Installed Plugin Lifecycle
The ready-to-run example above already demonstrates the full installed-plugin lifecycle, including toggling the persistentenabled
flag in .installed.json before uninstalling the plugin.
Use the same APIs directly when you need a narrower flow:
Multiple Marketplace Registrations
For enterprise and team scenarios, you can register multiple plugin marketplaces with different loading strategies. This allows you to:- Register internal team marketplaces alongside the public marketplace
- Control which plugins auto-load at conversation start vs load on-demand
- Reference plugins from specific marketplaces using the
plugin@marketplacesyntax
Loading Strategies
| Strategy | Behavior |
|---|---|
auto_load="all" | All plugins from the marketplace load automatically when a conversation starts |
auto_load=None (default) | Marketplace is registered but plugins are loaded on-demand via load_plugin() |
Plugin Reference Syntax
Use theplugin-name@marketplace-name format to explicitly specify which
marketplace a plugin comes from. This syntax follows the same convention as
Claude Code’s plugin install command.
Example: Auto-load and On-demand Loading
The example below demonstrates registering two marketplaces with different loading strategies, then loading an additional plugin on-demand.examples/05_skills_and_plugins/04_multiple_marketplace_registrations/main.py
The model name should follow the LiteLLM convention:
provider/model_name (e.g., anthropic/claude-sonnet-4-5-20250929, openai/gpt-4o).
The LLM_API_KEY should be the API key for your chosen provider.MarketplaceRegistration Fields
| Field | Type | Description |
|---|---|---|
name | str | Identifier for this marketplace registration |
source | str | Plugin source: github:owner/repo, git URL, or local path |
ref | str | None | Optional branch, tag, or commit for the marketplace repo |
repo_path | str | None | Subdirectory within repo (for monorepos) |
auto_load | "all" | None | Loading strategy (default: None) |
Next Steps
- Skills - Learn more about skills and triggers
- Hooks - Understand hook event types
- MCP Integration - Configure external tool servers

