validate-ui-mcp
v0.3.6Local stdio MCP server — the UI-authoring counterpart to the hosted keboola/mcp-server — exposing discover (discover_design), scaffold (scaffold_app)…
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
validate_ui Validate a rendered UI
Render a served URL headless and run every validation axis (runtime-health, a11y, visual-brand, brief-conformance). Returns the AggregateVerdict: overall `pass` plus per-axis `{ axis, pass, findings }`. Brief-conformance needs ANTHROPIC_API_KEY and is skipped (non-fatal) without it.
| Parameter | Type | Description |
|---|---|---|
url * | string | URL of the served route to render and validate. |
brief | string | The natural-language brief the UI was generated from (enables brief-conformance). |
score_ui Validate and score a rendered UI
Validate a served URL, then turn the verdict into a 0-100 BenchScore so an agent can decide "is this good enough?". Returns `{ verdict, score }` where score has `total` + per-axis `axes`. Read `total` and the failing axes' findings to drive a fix loop.
| Parameter | Type | Description |
|---|---|---|
url * | string | URL of the served route to render and score. |
brief | string | The natural-language brief the UI was generated from (enables brief-conformance). |
serve_and_score Serve a built SPA dir, then validate and score a route
Serve a built SPA directory (e.g. a module's `dist`) on an ephemeral port with client-side-routing fallback, validate + score one route, then close the server. Returns `{ verdict, score }`. Use when you have a build on disk rather than an already-running URL.
| Parameter | Type | Description |
|---|---|---|
distDir * | string | Path to the built SPA directory to serve (must contain index.html). |
brief | string | The natural-language brief the UI was generated from (enables brief-conformance). |
route | string | Client route to validate. Defaults to "/". |
discover_design Discover the @keboola/design component surface
Surface the @keboola/design discovery artefacts the package ships: the decision tree (AGENTS.md — which component for which UI need, with composition recipes) and/or the generated per-component prop reference (component-api.json). Read this before generating UI so you pick the right primitive and pass the right props. Returns `{ decisionTree?, componentApi? }`.
| Parameter | Type | Description |
|---|---|---|
repoRoot * | string | Absolute path to the keboola/ui repo root (where packages/design lives). |
section | string | Which surface to return: "decision-tree", "component-api", or "both" (default). |
scaffold_app Scaffold a new Keboola app
Scaffold a new `apps/<name>` by running `create-keboola-app --workspace` (the repo's `pnpm scaffold:app`). There is no template id to choose. Every app is one shell — the @keboola/design app chrome, a sidebar rail, colour-mode toggle, an overview route, the Zustand store and the vitest setup — plus the blocks you select. Omitting `blocks` selects ALL of them; pass `[]` for the shell alone. Shape it with `blocks`: pass any combination of `kpi` (stat cards), `chart` (token-themed line chart), `grid` (editable TanStack Table grid), `crud` (list → detail → form over a route, exercising rou…
| Parameter | Type | Description |
|---|---|---|
name * | string | Kebab-case app name; becomes `apps/<name>` and package `@keboola/<name>` (e.g. "catalog", "data-explorer"). |
repoRoot * | string | Absolute path to the keboola/ui repo root (the pnpm workspace root, where apps/ lives). |
blocks | array | Block ids: kpi, chart, grid, crud, assistant. Omit for all of them; pass `[]` for the shell only. Additive — the shell plus exactly what you list. |