diff --git a/.agents/skills/wfdash-giellie/SKILL.md b/.agents/skills/wfdash-giellie/SKILL.md index facaf83..0a958a5 100644 --- a/.agents/skills/wfdash-giellie/SKILL.md +++ b/.agents/skills/wfdash-giellie/SKILL.md @@ -1,6 +1,6 @@ --- name: wfdash-giellie -description: Giellie — WFDASH business-CRM agent. Use whenever the operator asks to interact with the WFDASH app (the Westcott Fasteners quoting/orders CRM at https://wfdash.apphub.co.za) via API or MCP — e.g. ingest an inbound RFQ email, list/create/update companies/customers/suppliers, list orders, manage the collection pool, update order-item status, send/retry quote or purchase-order emails, generate/regenerate PO PDFs, claim sprint rows, or run any other tool under /api/mcp. Covers authentication (Bearer AGENT_API_KEY), the JSON-RPC MCP surface, the REST surface under /api/v1/*, hard rules from docs/AGENT_INSTRUCTIONS.md, the 70 tools currently exposed under tools/list, and a running list of known bugs and architectural gaps surfaced during smoke-testing. +description: Giellie — WFDASH business-CRM agent. Use whenever the operator asks to interact with the WFDASH app (the Westcott Fasteners quoting/orders CRM at https://wfdash.apphub.co.za) via API or MCP — e.g. ingest an inbound RFQ email, list/create/update companies/customers/suppliers, list orders, manage the collection pool, update order-item status, send/retry quote or purchase-order emails, generate/regenerate PO PDFs, claim sprint rows, or run any other tool under /api/mcp. Covers authentication (Bearer AGENT_API_KEY), the JSON-RPC MCP surface, the REST surface under /api/v1/*, hard rules from docs/AGENT_INSTRUCTIONS.md, the 69 tools currently exposed under tools/list, and a running list of known bugs and architectural gaps surfaced during smoke-testing. --- # Giellie — WFDASH Agent @@ -10,7 +10,7 @@ You are **Giellie**, the external automation agent for the **WFDASH** business C This skill is your operating manual. It tells you: 1. How to connect (Bearer token, base URL, MCP vs REST). -2. What you can do (the 70 MCP tools + the `/api/v1/*` REST surface). +2. What you can do (the 69 MCP tools + the `/api/v1/*` REST surface). 3. What you must **not** do (hard rules). 4. What to do when something goes wrong. 5. Known bugs and architectural gaps so you don't burn cycles rediscovering them. @@ -145,7 +145,7 @@ Per-row validation failures inside batch tools (`bulk_update_quote_items`) are * | `POST /api/mcp { method: "tools/call", params: { name: "tools.discovery", arguments: {} } }` | JSON-RPC-wrapped call that returns `{ tools: [...] }` flat (same shape as `tools/list`) | When your client can only do JSON-RPC and you want the same flat payload as the GET alternative below. | | `GET /api/mcp` (with Bearer, no body) | Returns `{ tools: [...] }` directly, **no JSON-RPC envelope**. ~60 KB. | Cheapest way to enumerate tools — ideal for clients that can't easily build JSON-RPC (cron jobs, dashboards, scripts). | -All three return the same 70-tool catalog. Pick by client capability, not by content. +All three return the same 69-tool catalog. Pick by client capability, not by content. ### REST (`/api/v1/*`) — fallback @@ -193,7 +193,7 @@ The `letterhead` body field accepts only `"CNL"` or `"ISHERWOOD"`. Anything else ## Tool families (MCP) -70 tools as of last sync. Grouped by job-to-be-done — pick the **most specific** tool that fits. +69 tools as of last sync. Grouped by job-to-be-done — pick the **most specific** tool that fits. ### 1. Quote email pipeline (read + write) @@ -266,7 +266,7 @@ The `letterhead` body field accepts only `"CNL"` or `"ISHERWOOD"`. Anything else |------|---------| | `tools.discovery` | Returns the flat `{ tools: [...] }` catalog via JSON-RPC. Mirrors `GET /api/mcp`. Implemented in `src/app/api/mcp/route.ts`. | -### Full tool index (70) +### Full tool index (69) ``` orders.list, orders.get, orders.create_from_quote @@ -645,4 +645,5 @@ The same four places for the bearer, two for the n8n key. Out-of-sync credential ## Change log -- **2026-08-04** — Initial live-server smoke test. Discovered and documented all six known bugs, the two architectural gaps, the missing webhooks/n8n tokens. Fixed `tools.discovery` source (`src/app/api/mcp/route.ts:2497`) — **deployment pending**, the live server still returns "Unknown tool" until rebuild. Replaced stale `wfdash.davidels.dev` base URL with `wfdash.apphub.co.za`. Bumped tool count from 69 → 70 (added `tools.discovery` to the live catalog; `quotes.items.rewrite` removed — it was always REST-only). \ No newline at end of file +- **2026-08-04** — Initial live-server smoke test. Discovered and documented all six known bugs, the four architectural gaps, the missing webhooks/n8n tokens. Fixed `tools.discovery` source (`src/app/api/mcp/route.ts:2497`) — **deployment pending**, the live server still returned "Unknown tool" until rebuild. Replaced stale `wfdash.davidels.dev` base URL with `wfdash.apphub.co.za`. Removed `quotes.items.rewrite` from the MCP tool families — it was always a REST endpoint. Catalog count is **69** (unchanged — `tools.discovery` was already declared; only its runtime behavior changed from "Unknown tool" to functional). +- **2026-08-04 (post-redeploy)** — Verified live: `tools.discovery` now returns the flat 69-tool catalog via JSON-RPC; `GET /api/mcp` still works; the other five bugs (`collection_pool.list`, `sprint.list`, `quotes.lookup`, `orders.list` filter, `quotes.items.rewrite` as MCP) reproduce exactly as documented, confirming the skill doc is accurate. Two PDF regenerations on `Q000087` succeeded (ISHERWOOD + CNL letterheads) — `pdf_generated_at` stays null because the quote is in a terminal `approved` state. \ No newline at end of file