Description
I am using the new v2 plugin API to register a custom skill via ctx.skill.transform(), but the skill is not showing up when searching with the /skills command.
Steps to Reproduce
- Create a v2 plugin at
.opencode/plugins/skill-plugin.ts
- Use
ctx.skill.transform() to register a skill with type: "embedded"
- Open the TUI and wait for the plugin to load
- Execute
/skills command and search for my-skill
Code
File: MyProject/.opencode/plugins/skill-plugin.ts
import { define } from "@opencode-ai/plugin/v2/promise"
export default define({
id: "my-skill-plugin",
setup: async (ctx) => {
console.error("[plugin v2]skill setup")
const res = await ctx.skill.transform((draft) => {
draft.source({
type: "embedded",
skill: {
name: "my-skill",
description: "Use when asked about conventions.",
location: "/builtin/my-skill.md",
content: "Always use kebab-case.",
},
})
})
}
})
Expected Behavior
The skill my-skill should appear in the /skill search results.
Actual Behavior
The plugin setup code is executed (confirmed by console output: [plugin v2]skill setup)
However, the skill my-skill cannot be found via the /skill command
Questions / Hypothesis
Is location: "/builtin/my-skill.md" required to be an actual existing file path?
Does the v2/promise API support skill registration the same way as the legacy API?
Is there a missing step (e.g., explicit activation or a different API) for v2 plugins?
Additional Context
I noticed the plugin itself loads successfully, but the skill registration seems to have no effect on the /skill search index. Any guidance on the correct v2 approach for registering discoverable skills would be appreciated.

Plugins
@opencode-ai/plugin/v2/promise
OpenCode version
1.17.10
Steps to reproduce
No response
Screenshot and/or share link
No response
Operating System
No response
Terminal
No response
Description
I am using the new v2 plugin API to register a custom skill via
ctx.skill.transform(), but the skill is not showing up when searching with the/skillscommand.Steps to Reproduce
.opencode/plugins/skill-plugin.tsctx.skill.transform()to register a skill withtype: "embedded"/skillscommand and search formy-skillCode
File:
MyProject/.opencode/plugins/skill-plugin.tsExpected Behavior
The skill my-skill should appear in the /skill search results.
Actual Behavior

The plugin setup code is executed (confirmed by console output: [plugin v2]skill setup)
However, the skill my-skill cannot be found via the /skill command
Questions / Hypothesis
Is location: "/builtin/my-skill.md" required to be an actual existing file path?
Does the v2/promise API support skill registration the same way as the legacy API?
Is there a missing step (e.g., explicit activation or a different API) for v2 plugins?
Additional Context
I noticed the plugin itself loads successfully, but the skill registration seems to have no effect on the /skill search index. Any guidance on the correct v2 approach for registering discoverable skills would be appreciated.
Plugins
@opencode-ai/plugin/v2/promise
OpenCode version
1.17.10
Steps to reproduce
No response
Screenshot and/or share link
No response
Operating System
No response
Terminal
No response