A Claude Code plugin that connects any Claude Code session to an AELLI orchestrator via the A2A (Agent-to-Agent) protocol.
AELLI is a self-hosted AI orchestration platform that routes tasks to connected agent clients. This plugin makes Claude Code one such client — on session start it opens an SSE subscription to the AELLI server and receives tasks in real time.
- A running AELLI orchestrator server (self-hosted)
- Node.js 18+
- Claude Code
git clone https://github.com/raelli/aelli-cc-plugin.git
cp -r aelli-cc-plugin ~/.claude/plugins/aelli-cc-pluginThen enable the plugin in Claude Code via /plugins.
git clone https://github.com/raelli/aelli-cc-plugin.git
cp -r aelli-cc-plugin .claude/plugins/aelli-cc-pluginAdd the following to ~/.claude/settings.json under env:
{
"env": {
"AELLI_API_BASE": "https://your-aelli-server/api",
"AELLI_AUTH_TOKEN": "your-token-here"
}
}| Variable | Required | Default | Description |
|---|---|---|---|
AELLI_API_BASE |
Yes | http://localhost:3001/api |
AELLI server API base URL |
AELLI_AUTH_TOKEN |
Yes | — | Bearer token for API authentication |
PTY_SESSION_ID |
No | auto-generated | Session ID sent to the AELLI server on SSE subscribe |
By default processTask in src/a2a-client.js is a stub that acknowledges every task. Replace it with your own dispatch logic:
async function processTask(task) {
// task: { id, messages, metadata }
await updateTask(task.id, "working");
// your logic here — read task.messages, call tools, etc.
await updateTask(task.id, "completed", {
name: "result",
parts: [{ type: "text", text: "done" }],
});
}Background subscriber output goes to ~/.cache/aelli-cc/aelli-cc.log.
SessionStart hook
└─ hooks/scripts/start.sh
└─ node index.js (background, PID tracked at ~/.cache/aelli-cc/aelli-cc.pid)
└─ src/a2a-client.js → SSE subscribe → AELLI_API_BASE
Stop hook
└─ hooks/scripts/stop-hook.js (sends SIGTERM to subscriber via PID file)
MIT — see LICENSE.