aural-ui 3.0.2 → 3.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -116,12 +116,12 @@ The **aural-ui MCP server** exposes the design system by reading from aural-ui s
116
116
 
117
117
  ### Setup in Cursor
118
118
 
119
- Add **aural-ui** in `.cursor/mcp.json` (or Cursor Settings → MCP). Start the MCP server first (e.g. `npx tsx mcp/src/index.ts` from the aural-ui repo root, or run the Docker image), then point Cursor at the streamable HTTP endpoint:
119
+ Add the server in `.cursor/mcp.json` (or Cursor Settings → MCP). Start the MCP server first (e.g. `npx tsx mcp/src/index.ts` from the aural-ui repo root, or run the Docker image), then point Cursor at the streamable HTTP endpoint:
120
120
 
121
121
  ```json
122
122
  {
123
123
  "mcpServers": {
124
- "aural-ui-mcp": {
124
+ "aural-ui": {
125
125
  "type": "streamableHttp",
126
126
  "url": "http://localhost:3000/mcp"
127
127
  }
@@ -129,23 +129,24 @@ Add **aural-ui** in `.cursor/mcp.json` (or Cursor Settings → MCP). Start the M
129
129
  }
130
130
  ```
131
131
 
132
- Use the same URL when the server runs in Docker or elsewhere (e.g. `http://your-host:3000/mcp`).
132
+ The server identifies as **aural-ui** so agents match user phrases like "add aural-ui btn". Use the same URL when the server runs in Docker or elsewhere (e.g. `http://your-host:3000/mcp`).
133
133
 
134
134
  - **Config:** All MCP server settings are in `mcp/src/lib/env.ts` (no .env). You can set `AURAL_UI_SRC` there to the aural-ui repo `src` path if the workspace is not the aural-ui repo.
135
135
 
136
136
  **HTTP / Docker:** When running the MCP server over HTTP (e.g. in Docker):
137
137
  - **GET /health** — Returns `200` and `{ "ok": true, "server": "aural-ui" }` for load balancers and orchestrators (no MCP session required).
138
138
  - **GET /metrics** — Returns Prometheus-format metrics: `mcp_sessions_active`, `mcp_sessions_max`, `mcp_tool_calls_total{tool="..."}` (no MCP session required).
139
- - **Settings** (in `mcp/src/lib/env.ts`): `PORT` (default `3000`), `MCP_MAX_SESSIONS` (default `100`; 0 = unlimited), `MCP_SESSION_IDLE_TIMEOUT_MS` (default 15 min), `MCP_ALLOWED_PROJECT_ROOTS`, `MCP_LIST_CACHE_TTL_MS` (list cache TTL).
139
+ - **Settings** (in `mcp/src/lib/env.ts`): `PORT` (default `3000`), `MCP_MAX_SESSIONS` (default `100`; 0 = unlimited), `MCP_SESSION_IDLE_TIMEOUT_MS` (default 15 min), `MCP_LIST_CACHE_TTL_MS` (list cache TTL).
140
140
 
141
- To have Cursor install Aural UI components in your project (instead of writing code manually), ask it to use **`add_aural_components`** with the component names (e.g. `["button", "card", "dialog"]`). The tool will run `npx aural-ui init --yes` if needed, then `npx aural-ui add ...`.
141
+ To have Cursor install Aural UI components in your project (instead of writing code manually), ask it to use **`add_aural_components`** with the component names (e.g. `["button", "card", "dialog"]`). The agent must run the returned CLI steps first on the user machine; use componentSources only if the CLI fails. Do not pass `--yes` to `add`; only `init` supports it.
142
142
 
143
143
  ### MCP tools
144
144
 
145
145
  | Tool | Description |
146
146
  |------|-------------|
147
- | `add_aural_components` | **Runs the CLI:** init if needed, then `npx aural-ui add <components>`. Only use component names that exist; if the user's request is unclear or doesn't match, call `list_components` first and show available names—do not guess and add a different component. |
148
- | `init_aural_ui` | **Runs the CLI:** runs `npx aural-ui init --yes` in the workspace. Use when the project has no aural-ui.json yet. |
147
+ | `add_aural_components` | **Returns instructions:** run the returned CLI steps first on the user machine (init if needed, then `npx aural-ui add <components>`); use componentSources only if CLI fails. Only use component names that exist; call `list_components` first if unclear. The MCP does not run the CLI. |
148
+ | `init_aural_ui` | **Returns instructions:** step to run `npx aural-ui init --yes` in the project root on the user machine. Use when the project has no aural-ui.json yet. The MCP does not run the CLI. |
149
+ | `ensure_aural_components` | **Returns instructions:** run the returned CLI steps first (init if needed, then add); use componentSources only if CLI fails. Only missing components are added by the CLI. The MCP does not run the CLI. |
149
150
  | `get_aural_ui_status` | Where aural-ui source is resolved (env, repo, node_modules). |
150
151
  | `get_aural_ui_version` | Returns the aural-ui design system version from the resolved source (package.json). |
151
152
  | `list_components` / `list_icons` / `list_hooks` | **Call first when unsure:** returns available component, icon, or hook names. Use when the user asks for a component/hook that might not exist so you can show the list instead of guessing. |