Skip to content

Claude Code Plugin

The SWEny plugin for Claude Code gives you slash commands, MCP tools, a startup hook, and an isolated agent — all from a single install. Instead of switching to your terminal, type /sweny:triage and Claude delegates the work to SWEny’s DAG executor.

First add the SWEny marketplace, then install the plugin:

/plugin marketplace add swenyai/sweny
/plugin install sweny@sweny-official
SkillDescription
/sweny:triageInvestigate production alerts, create issues, implement fixes
/sweny:implementPick up an issue and implement a fix
/sweny:e2e-initGenerate browser E2E test workflows
/sweny:e2e-runRun E2E test workflows
/sweny:workflow-createGenerate a workflow from natural language
/sweny:workflow-editEdit a workflow with natural language
/sweny:workflow-runRun any workflow from a YAML file
/sweny:workflow-diagramVisualize a workflow as a Mermaid diagram
/sweny:initSet up SWEny in the current project
/sweny:checkVerify provider credentials
/sweny:setupCreate labels in your issue tracker

The plugin also registers an MCP server that gives Claude two tools for autonomous use — Claude can list and run workflows without you typing a slash command:

  • sweny_list_workflows — list available workflows
  • sweny_run_workflow — execute triage or implement programmatically
  • SessionStart — if a .sweny.yml exists, runs sweny check on startup to surface credential issues early
  • sweny-workflow — long-running workflows (triage, implement, e2e-run, workflow-run) execute in a forked context using this agent, keeping your main conversation clean

If you prefer to configure just the MCP server without the full plugin:

Claude Code runs everything in a single conversation context. For complex tasks, that context gets bloated and unfocused. SWEny’s DAG executor solves this by splitting work into nodes — each node gets a focused context window with only the inputs it needs.

Task typeBest approach
Simple, single-step tasksClaude Code handles directly
Complex multi-step workflowsClaude delegates to SWEny via MCP

SWEny handles the structured orchestration — conditional routing, scoped tool access, structured output schemas — that a single conversation can’t do reliably.

Add to .claude/settings.json in your project:

{
"mcpServers": {
"sweny": {
"command": "npx",
"args": ["-y", "@sweny-ai/mcp"]
}
}
}

Add to your claude_desktop_config.json:

{
"mcpServers": {
"sweny": {
"command": "npx",
"args": ["-y", "@sweny-ai/mcp"]
}
}
}
  • A .sweny.yml config file in the working directory (run sweny new to create one)
  • Credentials for your configured providers set via environment variables or .env
  • @sweny-ai/core installed (provides the sweny CLI binary)

Lists built-in workflows (triage, implement, seed-content) and any custom workflows found in .sweny/workflows/*.yml.

ParameterTypeRequiredDescription
cwdstringnoWorking directory to search. Defaults to the server’s working directory.

Example response:

[
{
"id": "triage",
"name": "Triage",
"description": "Investigate alerts and create issues or PRs",
"nodeCount": 8,
"source": "builtin"
},
{
"id": "implement",
"name": "Implement",
"description": "Pick up an issue and implement a fix",
"nodeCount": 5,
"source": "builtin"
}
]

Executes a triage or implement workflow by spawning the sweny CLI. Returns structured JSON results when the workflow completes.

ParameterTypeRequiredDescription
workflow"triage" or "implement"yesWhich workflow to run
inputstringfor implementIssue ID or URL (required for implement, ignored for triage)
cwdstringnoWorking directory containing .sweny.yml
dryRunbooleannoSkip side effects — investigate but don’t create issues/PRs

When Claude calls sweny_run_workflow, the MCP server:

  1. Spawns a separate sweny CLI process — this avoids recursion (the MCP server runs inside Claude Code, but the workflow spawns its own Claude Code instance)
  2. Passes --json --stream — the CLI outputs NDJSON events as the DAG executes
  3. Streams progress in real time — parses NDJSON events (node:enter, node:progress, node:exit) and forwards them to Claude via MCP logging notifications
  4. Returns the final result — the last JSON object from the stream, with success/failure status

The MCP server itself is stateless — each tool call is independent.

SWEny has two MCP integration points — don’t confuse them:

ConceptWhat it doesDocs
SWEny as MCP server (this page)Exposes SWEny workflows as tools for Claude Code/Desktop
MCP server auto-injectionSWEny injects external MCP servers (GitHub, Linear, etc.) into its own workflowsMCP Servers

They complement each other: Claude Code calls SWEny via MCP, and SWEny’s workflows internally use other MCP servers to access external services.