create-plugin

Solid

Create an OpenCode plugin for iPolloWork. Scaffolds the plugin file with the correct API shape, tool definitions, and hook registration. Use when the user asks to 'create a plugin', 'write a plugin', or 'make a plugin that does X'.

AI & Automation 4,373 stars 848 forks Updated today NOASSERTION

Install

View on GitHub

Quality Score: 83/100

Stars 20%
100
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Skill: Create an OpenCode Plugin Scaffold a working OpenCode plugin for use in iPolloWork. ## When to use - User asks "create a plugin that does X" - User asks "write a plugin" or "make a plugin" - User wants to extend iPolloWork/OpenCode with custom tools ## Plugin API An OpenCode plugin is an **async factory function** that returns a **hooks object**. ### File location Plugins can live in: - **Project**: `.opencode/plugins/my-plugin.ts` (auto-discovered) - **Global**: `~/.config/opencode/plugins/my-plugin.ts` - **npm**: published as a package, referenced in `opencode.json` `plugin` array - **URL**: `file:` or `https:` path in the `plugin` array ### Minimal shape ```typescript import { z } from "zod"; export default async () => ({ tool: { my_tool_name: { description: "What this tool does.", args: z.object({ input: z.string().describe("The input parameter."), }).shape, // NOTE: .shape, not the ZodObject itself async execute(args: { input: string }) { // Your logic here. Can use fetch(), fs, child_process, etc. return `Result: ${args.input}`; }, }, }, }); ``` ### Key rules 1. **Export default an async function** that returns the hooks object. 2. **Tool args use `zodSchema.shape`** (a `ZodRawShape`), not the `ZodObject`. 3. **`execute` returns a `string`** or `{ output: string; metadata?: Record<string, unknown> }`. 4. **Tools are declared, not registered imperatively** — return them in the hooks ...

Details

Author
Devin-AXIS
Repository
Devin-AXIS/iPolloWork
Created
12 months ago
Last Updated
today
Language
TypeScript
License
NOASSERTION

Similar Skills

Semantically similar based on skill content — not just same category