Skip to content

Commit 16aae6c

Browse files
committed
release: merge develop into main for v0.32.0
2 parents 9d82da8 + f957fdd commit 16aae6c

110 files changed

Lines changed: 21327 additions & 598 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.claude/rules/skills.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ The workspace has skills in two layers:
2626
| `pulse-` | Community (daily, weekly, monthly, FAQ sync) | 4 |
2727
| `sage-` | Strategy (OKR review, strategy digest, competitive analysis) | 3 |
2828
| `create-` | Workspace management (create-routine, create-agent, create-command, create-heartbeat, create-goal, create-ticket, manage-heartbeats) | 7 |
29+
| `plugin-` | Plugins (install, list, uninstall, update, marketplace, health) | 6 |
2930

3031
> **Note:** `evo-*` skills (Evo Method) have been moved to the separate [EVO-METHOD](https://github.com/EvolutionAPI/EVO-METHOD) project.
3132

.claude/settings.json

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,16 @@
1212
"command": "bash \"$CLAUDE_PROJECT_DIR/.claude/hooks/agent-tracker.sh\""
1313
}
1414
]
15+
},
16+
{
17+
"matcher": "",
18+
"hooks": [
19+
{
20+
"type": "command",
21+
"command": "python3 \"$CLAUDE_PROJECT_DIR/dashboard/backend/claude_hook_dispatcher.py\" PreToolUse",
22+
"_evonexus_managed": true
23+
}
24+
]
1525
}
1626
],
1727
"Stop": [
@@ -23,6 +33,40 @@
2333
"command": "bash \"$CLAUDE_PROJECT_DIR/.claude/hooks/agent-tracker.sh\""
2434
}
2535
]
36+
},
37+
{
38+
"matcher": "",
39+
"hooks": [
40+
{
41+
"type": "command",
42+
"command": "python3 \"$CLAUDE_PROJECT_DIR/dashboard/backend/claude_hook_dispatcher.py\" Stop",
43+
"_evonexus_managed": true
44+
}
45+
]
46+
}
47+
],
48+
"PostToolUse": [
49+
{
50+
"matcher": "",
51+
"hooks": [
52+
{
53+
"type": "command",
54+
"command": "python3 \"$CLAUDE_PROJECT_DIR/dashboard/backend/claude_hook_dispatcher.py\" PostToolUse",
55+
"_evonexus_managed": true
56+
}
57+
]
58+
}
59+
],
60+
"SubagentStop": [
61+
{
62+
"matcher": "",
63+
"hooks": [
64+
{
65+
"type": "command",
66+
"command": "python3 \"$CLAUDE_PROJECT_DIR/dashboard/backend/claude_hook_dispatcher.py\" SubagentStop",
67+
"_evonexus_managed": true
68+
}
69+
]
2670
}
2771
]
2872
},
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
---
2+
name: plugin-health
3+
description: Check an installed plugin's health — verify manifest SHA256 matches files on disk, detect tampering or corruption. Use when the user asks if a plugin is working, reports a bug, or wants to validate integrity. Triggers on "plugin X está funcionando?", "health plugin X", "status plugin X", "está ok o plugin Y?".
4+
metadata:
5+
category: plugins
6+
version: 1.0.0
7+
---
8+
9+
# Plugin Health
10+
11+
Run on-demand integrity check for a plugin. Compares `.install-manifest.json` SHA256 entries against actual files on disk. Detects tampering, partial corruption, or missing files.
12+
13+
## How to use
14+
15+
### Step 1 — Resolve the slug
16+
17+
If not given, list and ask:
18+
19+
```python
20+
from dashboard.backend.sdk_client import evo
21+
22+
plugins = evo.get("/api/plugins")
23+
```
24+
25+
### Step 2 — Run health check
26+
27+
```python
28+
health = evo.get(f"/api/plugins/{slug}/health")
29+
```
30+
31+
Response shape:
32+
33+
```json
34+
{
35+
"status": "active" | "broken" | "routine_activation_pending",
36+
"reason": "sha_mismatch" | "missing_files" | null,
37+
"files": [".claude/agents/plugin-foo-agent.md", ...], // if broken
38+
"checked_at": "..."
39+
}
40+
```
41+
42+
### Step 3 — Report
43+
44+
**If `active`:** plugin is healthy. Summarise: total files checked, all SHA256 matching, registered hooks/heartbeats/routines still wired.
45+
46+
**If `broken`:**
47+
- List corrupted/missing files
48+
- Suggest options:
49+
- Reinstall: `plugin-install` with same source URL (overwrites files, preserves data)
50+
- Uninstall + reinstall: clean slate
51+
- Manual fix: edit files back to original state (if user knows what was changed)
52+
53+
**If `routine_activation_pending`:** scheduler was offline during install. Tell user to start/restart scheduler.
54+
55+
## Error handling
56+
57+
- `HTTP 404 not_found` — plugin not installed.
58+
- `HTTP 500 health_check_failed` — filesystem permission issue or manifest unreadable. Check `ADWs/logs/plugins/`.
59+
60+
## Notes for the agent
61+
62+
- Broken state doesn't auto-disable. Plugin files may still work partially. User should decide whether to act.
63+
- If multiple plugins broken at once, likely the user did a git operation or `.claude/` migration. Health check is diagnostic, not autofix.
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
---
2+
name: plugin-install
3+
description: Install an EvoNexus plugin from a git URL or uploaded archive. Use when the user asks to install a plugin, add a plugin, or mentions a plugin source URL (github:user/repo, https://..., or a ZIP/tar.gz upload). Triggers on phrases like "instala plugin", "install plugin X", "adicionar plugin", "quero instalar Y".
4+
metadata:
5+
category: plugins
6+
version: 1.0.0
7+
---
8+
9+
# Plugin Install
10+
11+
Install an EvoNexus plugin through the `/api/plugins/*` endpoints. Plugins execute arbitrary code (agents, skills, shell hooks, SQL migrations) — always surface the preview and require explicit confirmation before running the install.
12+
13+
## How to use
14+
15+
### Step 1 — Obtain the source URL
16+
17+
Ask for the plugin source if not provided. Accepted forms:
18+
19+
- `github:user/repo` — default branch
20+
- `github:user/repo@v1.2.3` — specific tag or branch
21+
- `https://…/archive.tar.gz` or `https://…/archive.zip` — HTTPS tarball / zip URL
22+
- Uploaded archive (`.zip` / `.tar.gz`) — via the `/plugins` upload flow
23+
24+
Local filesystem paths (`/abs/path`, `./rel`, `~/...`) and non-HTTPS schemes (`file://`, `ssh://`, etc.) are **rejected by the backend** — do not try to work around that. If the user has a local checkout, tell them to push to a branch, create a release tag, or zip the plugin directory and upload it.
25+
26+
### Step 2 — Preview the manifest
27+
28+
Use the EvoClient SDK (auto-resolves URL + Bearer auth):
29+
30+
```python
31+
from dashboard.backend.sdk_client import evo
32+
33+
preview = evo.post("/api/plugins/preview", {"source_url": "<URL>"})
34+
```
35+
36+
Show the user, in this order:
37+
38+
- **Identidade:** id, name, version, author, license
39+
- **Capabilities:** agents, skills, commands, rules, heartbeats, routines, widgets, migrations, claude_hooks (only keys present)
40+
- **Env vars exigidas:** `env_vars_required`. Must exist in `.env`.
41+
- **`install.sql` completo** (expanded): full SQL. Runs in transaction against dashboard DB.
42+
- **Hooks shell completos:** full text of `hooks/pre-install.sh` and `hooks/post-install.sh`.
43+
- **Claude hook handlers** (if any): full text of `claude_hook_handlers/*.{py,sh}`.
44+
45+
Do not abbreviate. The user needs to read everything that will execute.
46+
47+
### Step 3 — Require explicit confirmation
48+
49+
Accept only clear affirmatives ("sim", "confirmar", "pode instalar", "ok"). If the user hesitates or asks for changes, stop and answer — do not install.
50+
51+
### Step 4 — Run the install
52+
53+
```python
54+
result = evo.post("/api/plugins/install", {
55+
"source_url": "<URL>",
56+
"confirmed": True,
57+
})
58+
```
59+
60+
### Step 5 — Report the outcome
61+
62+
On success (`{"status":"active","id":"<slug>"}`), summarise what the user now has: agents under `.claude/agents/plugin-<slug>-*`, heartbeats visible in `/heartbeats`, routines (scheduler reload on SIGHUP), widgets on Overview next page load.
63+
64+
If scheduler was offline and plugin has routines, backend returns `routine_activation_pending=true` — explain the user needs to start the scheduler.
65+
66+
## Error handling
67+
68+
- `HTTP 400 invalid_source_url` — URL failed source whitelist. Reprompt.
69+
- `HTTP 400 schema_invalid` — manifest rejected by Pydantic. Show validation error.
70+
- `HTTP 409 slug_conflict` — plugin id already installed. Offer uninstall first or a different one.
71+
- `HTTP 409 install_in_progress` — another install running. Retry or check `/plugins` UI.
72+
- `HTTP 500 migration_failed` — SQL transaction rolled back. DB unchanged. Surface SQLite error.
73+
- Other 5xx — capture body, suggest checking `ADWs/logs/plugins/`.
74+
75+
## Notes for the agent
76+
77+
- Never skip preview, even with high-trust URLs.
78+
- Never pass `confirmed=True` without explicit user green light.
79+
- Install one plugin at a time — if user asks for several, preview+confirm each in sequence.
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
---
2+
name: plugin-list
3+
description: List all installed EvoNexus plugins with status, version, and update availability. Use when the user asks about installed plugins, wants an inventory, or mentions plugins generally. Triggers on "quais plugins tenho", "list plugins", "plugins instalados", "o que tem instalado".
4+
metadata:
5+
category: plugins
6+
version: 1.0.0
7+
---
8+
9+
# Plugin List
10+
11+
Return the current inventory of installed plugins.
12+
13+
## How to use
14+
15+
### Step 1 — Fetch installed plugins
16+
17+
```python
18+
from dashboard.backend.sdk_client import evo
19+
20+
plugins = evo.get("/api/plugins")
21+
```
22+
23+
Response is a JSON array of `{id, name, version, status, tier, installed_at, source_url}`.
24+
25+
### Step 2 — (Optional) Cross-check marketplace for updates
26+
27+
If user hints at "desatualizados" / "outdated" / "updates":
28+
29+
```python
30+
marketplace = evo.get("/api/plugins/marketplace")
31+
```
32+
33+
Match installed vs marketplace by `id`; flag when `installed.version < marketplace.version` (semver).
34+
35+
### Step 3 — Render compact markdown table
36+
37+
```
38+
| slug | name | version | status | update? |
39+
|------|------|---------|--------|---------|
40+
| pm-essentials | PM Essentials | 1.0.0 | active | — |
41+
| int-pipedrive | Pipedrive Suite | 0.4.1 | active | 0.5.0 |
42+
```
43+
44+
Order by `name` ascending. Hide columns user didn't ask for.
45+
46+
Close with a one-line summary: total installed, N with updates, N broken (`status=broken` = manifest SHA mismatch, suggest `plugin-health`).
47+
48+
## Error handling
49+
50+
- Empty `[]` — say plainly no plugins installed, offer `plugin-marketplace`.
51+
- HTTP 5xx — verify the dashboard backend is running; don't invent data.
52+
53+
## Notes for the agent
54+
55+
- Omit `source_url` from output unless asked — long and noisy.
56+
- If `status` is `routine_activation_pending`, surface explicitly — scheduler offline during install, restart needed.
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
---
2+
name: plugin-marketplace
3+
description: Browse the EvoNexus plugin marketplace, searching for plugins by keyword, tag, or capability. Use when the user wants to find a plugin, asks what plugins are available, or describes a need that might have a plugin. Triggers on "procura plugin de X", "marketplace de plugins", "plugins disponíveis para Y", "tem algum plugin que faz Z".
4+
metadata:
5+
category: plugins
6+
version: 1.0.0
7+
---
8+
9+
# Plugin Marketplace
10+
11+
Browse the curated `registry.json` from `github.com/EvolutionAPI/evonexus-plugins` plus community plugins. Help the user find what they need and hand off to `plugin-install` when they pick one.
12+
13+
## How to use
14+
15+
### Step 1 — Fetch registry
16+
17+
```python
18+
from dashboard.backend.sdk_client import evo
19+
20+
marketplace = evo.get("/api/plugins/marketplace")
21+
```
22+
23+
Cached 10min backend-side. If backend returns 503 `marketplace_unreachable`, tell the user the registry is offline and suggest direct install via git URL (`plugin-install`).
24+
25+
### Step 2 — Filter by user intent
26+
27+
Each entry: `{id, name, version, repo_url, tier, tags, description, verified, author, homepage}`.
28+
29+
- If user provided a keyword, match against `name`, `description`, `tags`
30+
- If user wants "verified only", filter `verified=true`
31+
- If user wants a specific `tier` (essential vs full-stack), filter
32+
33+
Default: don't filter, show everything ordered by `verified=true` first, then alphabetical.
34+
35+
### Step 3 — Render results
36+
37+
```
38+
### 🟢 PM Essentials (verified)
39+
Agents, skills, routines para gestão de projetos com sincronização Linear.
40+
v1.0.0 · tags: pm, linear, showcase · MIT · @EvolutionAPI/evonexus-plugin-pm-essentials
41+
42+
### 🟢 Pipedrive Suite (verified)
43+
CRM integrado: pipeline, deals, health scores.
44+
v0.4.1 · tags: crm, pipedrive · MIT · @user/evonexus-plugin-pipedrive
45+
46+
### Community: Custom Linear Sync
47+
Fork extendido com webhooks do Linear.
48+
v2.0.0 · tags: linear, webhooks · @community/evonexus-plugin-linear-webhooks
49+
```
50+
51+
Use `🟢 verified` green badge, no badge for community.
52+
53+
### Step 4 — Offer to install
54+
55+
If the user expresses interest in a specific plugin ("instala o Pipedrive", "quero esse aí"), hand off to `plugin-install` skill passing the `repo_url` directly.
56+
57+
## Error handling
58+
59+
- Empty registry (nothing returned) — possible fresh registry or fetch error. Suggest direct install via git URL.
60+
- `HTTP 503 marketplace_unreachable` — fetcher failed (offline or GitHub down). Offer to retry or install directly by URL.
61+
62+
## Notes for the agent
63+
64+
- Don't invent plugins. Only list what backend returns.
65+
- Verified badge is meaningful — `verified=true` means the Evolution team reviewed. Default recommendations to verified.
66+
- If user asks "what's new", sort by installed_at descending (latest first).
67+
- Respect tier: `tier=full-stack` plugins are bigger commitment (UI, backend), `tier=essential` are lighter.

0 commit comments

Comments
 (0)