plugin-builder
Build Cursor plugin scaffolds with optional Runlayer MCP integration. Use this skill when the user wants to create a new Cursor plugin, scaffold plugin skills/commands/rules/hooks, or set up MCP connector configurations. Triggers include "create a plugin", "build a plugin", "scaffold a plugin", "new plugin for [domain]", or any task involving Cursor plugin development.
Best use case
plugin-builder is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Build Cursor plugin scaffolds with optional Runlayer MCP integration. Use this skill when the user wants to create a new Cursor plugin, scaffold plugin skills/commands/rules/hooks, or set up MCP connector configurations. Triggers include "create a plugin", "build a plugin", "scaffold a plugin", "new plugin for [domain]", or any task involving Cursor plugin development.
Teams using plugin-builder should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/plugin-builder/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How plugin-builder Compares
| Feature / Agent | plugin-builder | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Build Cursor plugin scaffolds with optional Runlayer MCP integration. Use this skill when the user wants to create a new Cursor plugin, scaffold plugin skills/commands/rules/hooks, or set up MCP connector configurations. Triggers include "create a plugin", "build a plugin", "scaffold a plugin", "new plugin for [domain]", or any task involving Cursor plugin development.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Cursor Plugin Builder
Build Cursor plugin scaffolds. Optionally integrates with Runlayer MCP for tool discovery.
## Before You Start: Check Runlayer MCP (Optional)
1. Check if Runlayer MCP tools are available (e.g., `mcp__runlayer__list_servers`)
2. **If available**: call `mcp__runlayer__list_servers(scope="accessible")` to discover available integrations
3. **If NOT available**: proceed without Runlayer integration. The plugin can still include rules, skills, hooks, agents, and commands.
## Directory Context
1. Run `ls -la` to understand the current directory structure
2. Check if this is already a plugin marketplace (look for `.cursor-plugin/marketplace.json`)
3. If it's a marketplace, new plugins should be created as subdirectories
4. **Always confirm the target location with the user before creating files**
## Workflow
### Step 1: Gather Requirements
Use AskQuestion to collect structured input:
**Question 1: Plugin basics**
- Plugin name (kebab-case slug, e.g., `customer-support`)
- 1-2 sentence description
**Question 2: Components to include** (multi-select)
- Rules (.mdc files) -- persistent AI guidance
- Skills (SKILL.md) -- specialized agent capabilities
- Commands (.md) -- explicit user-invoked actions
- Hooks (hooks.json) -- automation on agent events
- Agents (.md) -- custom agent behaviors
- MCP servers (.mcp.json) -- external tool integrations
**Question 3: If skills selected -- automation preference**
- "Fully automated" -- Skills trigger automatically based on context
- "Manual triggers only" -- Commands require explicit invocation
- "Both" -- Skills for automation, Commands as explicit fallback
**Question 4: If MCP tools needed -- tool categories** (from Runlayer if available)
- Present discovered servers grouped by category (CRM, ticketing, analytics, etc.)
- If no Runlayer, ask which external services to integrate
### Step 2: Generate Plugin Structure
```
<plugin-slug>/
├── .cursor-plugin/
│ └── plugin.json
├── rules/ # if rules selected
│ └── <rule-name>.mdc
├── skills/ # if skills selected
│ └── <skill-name>/
│ └── SKILL.md
├── commands/ # if commands selected
│ └── <command-name>.md
├── agents/ # if agents selected
│ └── <agent-name>.md
├── hooks/ # if hooks selected
│ └── hooks.json
├── .mcp.json # if MCP tools needed
└── README.md
```
### File Templates
**plugin.json:**
```json
{
"name": "<plugin-slug>",
"description": "<1-2 sentence description>",
"version": "1.0.0",
"author": { "name": "<author>" },
"keywords": ["<relevant>", "<tags>"]
}
```
**Rule (.mdc):**
```markdown
---
description: <What this rule enforces>
alwaysApply: true
---
## <Rule Title>
- Rule point 1
- Rule point 2
```
For glob-scoped rules (apply only to matching files):
```markdown
---
description: <What this rule enforces>
globs:
- "**/*.ts"
- "**/*.tsx"
---
```
**SKILL.md:**
```markdown
---
name: <skill-name>
description: <When this skill should activate. Be specific about triggers and contexts.>
---
# <Skill Title>
## When to Use
<Specific triggers and contexts>
## Workflow
<Step-by-step guidance>
## Best Practices
<Domain-specific guidance>
```
**Command (.md):**
```markdown
---
name: <command-name>
description: <What this command does>
---
# <Command Title>
<Instructions for executing this command>
## Usage
Invoke via `/plugin-name:command-name`
## Workflow
<Step-by-step execution>
```
**Agent (.md):**
```markdown
---
name: <agent-name>
description: <Brief description of the agent's purpose>
---
# <Agent Title>
<System prompt and behavioral instructions for the agent>
```
**hooks.json:**
```json
{
"hooks": {
"<hookEvent>": [{ "command": "./scripts/<script>.sh" }]
}
}
```
Available hook events: `sessionStart`, `sessionEnd`, `preToolUse`, `postToolUse`, `beforeShellExecution`, `afterShellExecution`, `beforeMCPExecution`, `afterMCPExecution`, `beforeReadFile`, `afterFileEdit`, `beforeSubmitPrompt`
**.mcp.json (only if MCP tools needed):**
```json
{
"mcpServers": {
"<server-name>": {
"url": "<server-url>"
}
}
}
```
If Runlayer is available, use URLs from `mcp__runlayer__list_servers` results. Never guess URLs.
### Step 3: Generate CONNECTORS.md (if MCP tools used)
```markdown
# Connectors
| Category | Available Servers |
|----------|-------------------|
| CRM | Salesforce, HubSpot |
| Ticketing | Zendesk, Jira |
## Configuration
Configure MCP servers in `.mcp.json` based on which services you use.
```
## Plugin Examples
### Security Plugin
- **Rules:** secrets-hygiene, code-review-standards
- **Skills:** vulnerability-scan, dependency-audit
- **Hooks:** afterFileEdit (lint), beforeShellExecution (validate)
### DevOps Plugin
- **Skills:** incident-response, deployment-review
- **Commands:** /deploy-status, /incident-summary
- **MCP:** Monitoring (Datadog), CI/CD (GitHub Actions)
### Customer Support Plugin
- **Skills:** ticket-triage, response-drafting
- **Commands:** /escalate, /draft-response
- **MCP:** Ticketing (Zendesk), CRM (Salesforce)
## Testing
After generating, instruct the user to test locally:
1. Install the plugin from the local directory in Cursor
2. Try invoking skills by describing relevant tasks
3. Try commands via `/plugin-name:command-name`
4. Verify rules apply by checking agent behavior in matching contexts
## Submission
When ready to publish:
1. Ensure `.cursor-plugin/plugin.json` manifest is valid
2. All rules/skills/agents/commands have proper frontmatter
3. Push to a public Git repository
4. Submit at [cursor.com/marketplace/publish](https://cursor.com/marketplace/publish)Related Skills
writing-opencode-plugins
Guides development of OpenCode plugins including project structure, testing patterns, and publishing. Use when creating or modifying OpenCode plugins.
workflow-new-plugin
Guided workflow for creating a new Volon plugin — ideation, requirements, spec, plan, tasks.
viral-generator-builder
Expert in building shareable generator tools that go viral - name generators, quiz makers, avatar creators, personality tests, and calculator tools. Covers the psychology of sharing, viral mechanic...
update-tool-plugin
Update an existing LNAI tool plugin
slash-command-builder
Use when creating, improving, or troubleshooting Claude Code slash commands. Expert guidance on command structure, arguments, frontmatter, tool permissions, and best practices for building effective custom commands.
skill-builder
Create new Claude Code skills with proper SKILL.md format, frontmatter, and best practices. Use when building, scaffolding, or generating a new skill for Claude Code.
seo-authority-builder
Analyzes content for E-E-A-T signals and suggests improvements to build authority and trust. Identifies missing credibility elements. Use PROACTIVELY for YMYL topics.
security-bluebook-builder
Build security Blue Books for sensitive apps
rollback-workflow-builder
Creates safe rollback procedures for deployments with automated workflows, rollback runbooks, version management, and incident response. Use for "rollback automation", "deployment recovery", "incident response", or "production rollback".
reference-builder
Creates exhaustive technical references and API documentation. Generates comprehensive parameter listings, configuration guides, and searchable reference materials.
ralph-prompt-builder
Master orchestrator for generating Ralph Wiggum-compatible prompts. Analyzes task requirements and routes to appropriate generator (single-task, multi-task, project, or research). Use when you need to create any Ralph loop prompt and want automatic selection of the right generator.
pytest-plugins
Use when pytest plugin ecosystem including pytest-cov, pytest-mock, and custom plugin development.