@cyanheads/cpsc-recalls-mcp-server 0.1.6 → 0.1.8

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/AGENTS.md CHANGED
@@ -1,11 +1,11 @@
1
1
  # Developer Protocol
2
2
 
3
3
  **Server:** cpsc-recalls-mcp-server
4
- **Version:** 0.1.6
5
- **Framework:** [@cyanheads/mcp-ts-core](https://www.npmjs.com/package/@cyanheads/mcp-ts-core) `^0.11.0`
6
- **Engines:** Bun ≥1.3.0, Node ≥24.0.0
7
- **MCP SDK:** `@modelcontextprotocol/sdk` ^1.29.0
8
- **Zod:** ^4.4.3
4
+ **Version:** 0.1.8
5
+ **Framework:** [@cyanheads/mcp-ts-core](https://www.npmjs.com/package/@cyanheads/mcp-ts-core) `^0.13.6`
6
+ **Engines:** Bun ≥1.4.0, Node ≥24.0.0
7
+ **MCP SDK:** `@modelcontextprotocol/server` ^2.0.0 (protocol revisions 2026-07-28 and 2025-*)
8
+ **Zod:** ^4.6.5
9
9
 
10
10
  > **Read the framework docs first:** `node_modules/@cyanheads/mcp-ts-core/CLAUDE.md` contains the full API reference — builders, Context, error codes, exports, patterns. This file covers server-specific conventions only.
11
11
 
@@ -35,8 +35,9 @@ Tailor suggestions to what's actually missing or stale — don't recite the full
35
35
  - **Logic throws, framework catches.** Tool/resource handlers are pure — throw on failure, no `try/catch`. Plain `Error` is fine; the framework catches, classifies, and formats. Use error factories (`notFound()`, `validationError()`, etc.) when the error code matters.
36
36
  - **Use `ctx.log`** for request-scoped logging. No `console` calls.
37
37
  - **Use `ctx.state`** for tenant-scoped storage. Never access persistence directly.
38
- - **Check `ctx.elicit`** for presence before calling.
38
+ - **Need input the caller didn't supply?** `return ctx.requestInput(...)` and read `ctx.inputs` when the handler is re-entered. Never `await` for user input mid-handler.
39
39
  - **Secrets in env vars only** — never hardcoded.
40
+ - **Cut noise.** Add only what earns its place: no speculative generality, no guards for states the framework already prevents (Zod-validated params, classified errors), no abstraction until a third caller proves it, no option nothing sets.
40
41
  - **Close the loop on issues.** When implementing work tracked by a GitHub issue, comment on the issue with what landed and close it. Do both — a comment without a close leaves stale issues open; a close without a comment leaves no record of what shipped. The comment is for future readers — state the concrete changes, not the conversation that produced them.
41
42
 
42
43
  ---
@@ -91,7 +92,7 @@ export const itemData = resource('inventory://{itemId}', {
91
92
  params: z.object({ itemId: z.string().describe('Item identifier') }),
92
93
  auth: ['inventory:read'],
93
94
  async handler(params, ctx) {
94
- const item = await ctx.state.get(`item:${params.itemId}`);
95
+ const item = await ctx.state.get(`item/${params.itemId}`);
95
96
  if (!item) throw notFound(`Item ${params.itemId} not found`, { itemId: params.itemId });
96
97
  return item;
97
98
  },
@@ -125,6 +126,7 @@ import { parseEnvConfig } from '@cyanheads/mcp-ts-core/config';
125
126
  const ServerConfigSchema = z.object({
126
127
  apiKey: z.string().describe('External API key'),
127
128
  maxResults: z.coerce.number().default(100),
129
+ verboseLogging: z.stringbool().default(false).describe('Enable verbose logging'),
128
130
  });
129
131
 
130
132
  let _config: z.infer<typeof ServerConfigSchema> | undefined;
@@ -132,6 +134,7 @@ export function getServerConfig() {
132
134
  _config ??= parseEnvConfig(ServerConfigSchema, {
133
135
  apiKey: 'MY_API_KEY',
134
136
  maxResults: 'MY_MAX_RESULTS',
137
+ verboseLogging: 'MY_VERBOSE_LOGGING',
135
138
  });
136
139
  return _config;
137
140
  }
@@ -158,6 +161,22 @@ await createApp({
158
161
 
159
162
  `instructions` is optional server-level orientation, sent on every `initialize` as session-level context. Use it for deployment guidance (connection aliases, regional notes, scope hints) instead of repeating the same context across tool descriptions. Client adoption is uneven, but there's no downside when set.
160
163
 
164
+ ### Session posture and shutdown
165
+
166
+ Two more `createApp()` options shape how the server runs rather than how it presents itself:
167
+
168
+ ```ts
169
+ await createApp({
170
+ sessionMode: 'stateless', // or { default: 'stateful', require: 'stateful' }
171
+ setup(core) { startMyWatcher(core.config); },
172
+ async teardown() { await stopMyWatcher(); },
173
+ });
174
+ ```
175
+
176
+ `sessionMode` declares the HTTP session posture in `src/` instead of leaving it to a deployment's `MCP_SESSION_MODE`, which still wins whenever it carries a meaningful value (an empty string and an unsubstituted `${…}` placeholder read as unset and fall through to the option). Add `require: 'stateful'` when a tool asks the caller for input mid-handler via `ctx.requestInput`: startup then fails with a `ConfigurationError` rather than serving a mode in which a 2025-era client can never answer the prompt. Stdio is never refused.
177
+
178
+ `teardown(core)` is the `setup()` counterpart — release a watcher, socket, or non-`unref()`'d timer there. It runs after the transport stops and before the logger closes, on every shutdown path, and a signal-triggered shutdown then exits the process explicitly (0, or 1 if a step never settles within the framework's 10 s ceiling). This server's CPSC client holds no such handle — every fetch is per-request — so no `teardown` is wired.
179
+
161
180
  ---
162
181
 
163
182
  ## Context
@@ -166,13 +185,13 @@ Handlers receive a unified `ctx` object. Key properties:
166
185
 
167
186
  | Property | Description |
168
187
  |:---------|:------------|
169
- | `ctx.log` | Request-scoped logger — `.debug()`, `.info()`, `.notice()`, `.warning()`, `.error()`. Auto-correlates requestId, traceId, tenantId. |
188
+ | `ctx.log` | Request-scoped logger — `.debug()`, `.info()`, `.notice()`, `.warning()`, `.error()`. Auto-correlates requestId, traceId, tenantId. Dual-sink: Pino **and** `notifications/message` to the client, so treat it as client-visible. |
170
189
  | `ctx.state` | Tenant-scoped KV — `.get(key)`, `.set(key, value, { ttl? })`, `.delete(key)`, `.getMany(keys)`, `.list(prefix, { cursor, limit })`. Accepts any serializable value. |
171
- | `ctx.elicit` | Ask user for structured input — form call `(message, schema)` or `.url(message, url)` for an external link. **Check for presence first:** `if (ctx.elicit) { ... }` |
190
+ | `ctx.requestInput` | Suspend and ask the caller for more input — `return ctx.requestInput({ inputRequests: { key: inputRequired.elicit({ message, requestedSchema }) } })`. Never returns; the handler is re-entered with the answers. Always present. |
191
+ | `ctx.inputs` | Reader over a retried request's responses — `.accepted(key, schema)`, `.view(key)`, `.state()`, `.dropped`. Empty on the first round. |
172
192
  | `ctx.enrich` | Success-path agent context (empty-result notices, query echo, pagination totals) — `ctx.enrich(...)` or `.notice()` / `.total()` / `.echo()` / `.truncated()`. Reaches `structuredContent` and `content[]`; lands only when the definition declares an `enrichment` block (no-op otherwise). |
173
193
  | `ctx.content` | Non-text content blocks — `.image(data, mimeType)`, `.audio(data, mimeType)`, or `ctx.content(block)` for a raw block. Prepended to `content[]` after `format()`; never enters `structuredContent`. |
174
194
  | `ctx.signal` | `AbortSignal` for cancellation. |
175
- | `ctx.progress` | Task progress (present when `task: true`) — `.setTotal(n)`, `.increment()`, `.update(message)`. |
176
195
  | `ctx.requestId` | Unique request ID. |
177
196
  | `ctx.tenantId` | Tenant ID from JWT; `'default'` for stdio or HTTP with auth off. |
178
197
 
@@ -182,7 +201,7 @@ Handlers receive a unified `ctx` object. Key properties:
182
201
 
183
202
  Handlers throw — the framework catches, classifies, and formats.
184
203
 
185
- **Recommended: typed error contract.** Declare `errors: [{ reason, code, when, recovery, retryable? }]` on `tool()` / `resource()` to receive `ctx.fail(reason, …)` typed against the reason union. TypeScript catches typos at compile time, `data.reason` is auto-populated for observability, linter enforces conformance against the handler body. `recovery` is required (≥ 5 words, lint-validated) — the single source of truth for the agent's next move. Pass `ctx.recoveryFor('reason')` as the throw's data to put it on the wire (`data.recovery.hint`, mirrored into `content[]` text); override with an explicit `{ recovery: { hint: '...' } }` when dynamic runtime context matters. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`) bubble freely and don't need declaring.
204
+ **Recommended: typed error contract.** Declare `errors: [{ reason, code, when, recovery, retryable?, severity?, thrownBy? }]` on `tool()` / `resource()` to receive `ctx.fail(reason, …)` typed against the reason union. TypeScript catches typos at compile time, `data.reason` is auto-populated for observability, linter enforces conformance against the handler body. `recovery` is required (≥ 5 words, lint-validated) — the single source of truth for the agent's next move. Pass `ctx.recoveryFor('reason')` as the throw's data to put it on the wire (`data.recovery.hint`, mirrored into `content[]` text unless the message already contains it verbatim); override with an explicit `{ recovery: { hint: '...' } }` when dynamic runtime context matters. Forwarding it is lint-enforced per throw site (`error-contract-recovery-unforwarded`). Mark an entry the service layer throws with `thrownBy: 'service'` so `error-contract-unthrown` skips it — lint-only metadata, nothing at runtime reads it. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`, `RequestCancelled`) bubble freely and don't need declaring.
186
205
 
187
206
  ```ts
188
207
  import { JsonRpcErrorCode } from '@cyanheads/mcp-ts-core/errors';
@@ -215,7 +234,7 @@ throw new Error('Invalid query format'); // → ValidationError
215
234
 
216
235
  // McpError — when no factory exists for the code
217
236
  import { McpError, JsonRpcErrorCode } from '@cyanheads/mcp-ts-core/errors';
218
- throw new McpError(JsonRpcErrorCode.DatabaseError, 'Connection failed', { pool: 'primary' });
237
+ throw new McpError(JsonRpcErrorCode.InitializationFailed, 'Connection failed', { pool: 'primary' });
219
238
  ```
220
239
 
221
240
  See framework CLAUDE.md and the `api-errors` skill for the full auto-classification table, all available factories, and the contract reference.
@@ -253,11 +272,9 @@ src/
253
272
 
254
273
  ## Skills
255
274
 
256
- Skills are modular instructions in `skills/` at the project root. Read them directly when a task matches — e.g., `skills/add-tool/SKILL.md` when adding a tool. `bun run list-skills` prints the full registry.
275
+ Skills are modular instructions in `framework-skills/` at the project root. Read them directly when a task matches — e.g., `framework-skills/add-tool/SKILL.md` when adding a tool. `bun run list-skills` prints the full registry. The directory is deliberately not `skills/`: Claude Code and Codex auto-load a plugin's root `skills/`, so a server that ships `.claude-plugin/` or `.codex-plugin/` would hand these development skills to every agent that installs it. Keep `skills/` free for skills meant for those agents.
257
276
 
258
- **Chaining skills into pipelines.** When the user wants a multi-phase effort — build this server out, QA-and-fix the surface, update-and-ship — *and you can spawn sub-agents*, `skills/orchestrations/SKILL.md` sequences the task skills below into a gated pipeline with verification at each step. Read it to drive the run. Optional: skip it if you can't orchestrate sub-agents, and ignore it entirely if you were *spawned* as one — you've already been scoped to a single phase.
259
-
260
- **Agent skill directory:** Copy skills into the directory your agent discovers (Claude Code: `.claude/skills/`, others: equivalent). Skills then load as context without referencing `skills/` paths. After framework updates, run the `maintenance` skill — Phase B re-syncs the agent directory.
277
+ **Agent skill directory:** Copy skills into the directory your agent discovers (Claude Code: `.claude/skills/`, others: equivalent). Skills then load as context without referencing `framework-skills/` paths. After framework updates, run the `maintenance` skill — Phase B re-syncs the agent directory.
261
278
 
262
279
  Available skills:
263
280
 
@@ -276,8 +293,9 @@ Available skills:
276
293
  | `security-pass` | Audit server for MCP-flavored security gaps: output injection, scope blast radius, input sinks, tenant isolation |
277
294
  | `code-simplifier` | Post-session cleanup against `git diff` — modernize syntax, consolidate duplication, align with the codebase |
278
295
  | `polish-docs-meta` | Finalize docs, README, metadata, and agent protocol for shipping |
279
- | `git-wrapup` | Land working-tree changes as a versioned commit + annotated tag — version bump, changelog, verify, tag. Local only. |
280
- | `release-and-publish` | Push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
296
+ | `git-wrapup` | Land working-tree changes as a commit stack — version bump, changelog, verify, commit by concern, release commit on top. No tag, no push to main; opens the release PR when the project declares release PR mode |
297
+ | `release-pr-review` | Review pass on an open release PR — simplifier + correctness review, fixes as ordinary commits on top of the stack, PR body kept in sync. Release PR mode only |
298
+ | `release-and-publish` | Fast-forward merge (release PR mode) + tag + push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
281
299
  | `maintenance` | Investigate changelogs, adopt upstream changes, sync skills to agent dirs |
282
300
  | `orchestrations` | Chain task skills into a gated multi-phase pipeline — build-out, QA-fix, update-ship — when you can spawn sub-agents |
283
301
  | `report-issue-framework` | File a bug or feature request against `@cyanheads/mcp-ts-core` via `gh` CLI |
@@ -286,7 +304,7 @@ Available skills:
286
304
  | `api-auth` | Auth modes, scopes, JWT/OAuth |
287
305
  | `api-canvas` | DataCanvas: register tabular data, run SQL, export, plus the `spillover()` helper for big result sets — Tier 3 opt-in |
288
306
  | `api-config` | AppConfig, parseConfig, env vars |
289
- | `api-context` | Context interface, logger, state, progress |
307
+ | `api-context` | Context interface, RequestContext, logger, state, multi-round-trip input |
290
308
  | `api-errors` | McpError, JsonRpcErrorCode, error patterns |
291
309
  | `api-linter` | Definition linter rule catalog — invoked by `bun run lint:mcp` and `devcheck` |
292
310
  | `api-mirror` | MirrorService: persistent self-refreshing local mirror (embedded SQLite + FTS5) of a bulk upstream dataset — Tier 3 opt-in |
@@ -296,13 +314,15 @@ Available skills:
296
314
  | `api-telemetry` | OTel catalog: spans, metrics, completion logs, env config, cardinality rules |
297
315
  | `api-workers` | Cloudflare Workers runtime |
298
316
 
317
+ **Chaining skills into pipelines.** When the user wants a multi-phase effort — build this server out, QA-and-fix the surface, update-and-ship — *and you can spawn sub-agents*, `framework-skills/orchestrations/SKILL.md` sequences the task skills above into a gated pipeline with verification at each step. Read it to drive the run. Optional: skip it if you can't orchestrate sub-agents, and ignore it entirely if you were *spawned* as one — you've already been scoped to a single phase.
318
+
299
319
  When you complete a skill's checklist, check the boxes and add a completion timestamp at the end (e.g., `Completed: 2026-03-11`).
300
320
 
301
321
  ---
302
322
 
303
323
  ## Commands
304
324
 
305
- **Runtime:** Scripts use `bun run scripts/X.ts`. All commands use `bun run <cmd>`.
325
+ **Runtime:** Scripts use Bun's native TypeScript execution — `bun run <cmd>` is the standard invocation.
306
326
 
307
327
  | Command | Purpose |
308
328
  |:--------|:--------|
@@ -310,11 +330,12 @@ When you complete a skill's checklist, check the boxes and add a completion time
310
330
  | `bun run rebuild` | Clean + build |
311
331
  | `bun run clean` | Remove build artifacts |
312
332
  | `bun run devcheck` | Lint + format + typecheck + security + changelog sync |
313
- | `bun run audit:refresh` | Delete `bun.lock`, reinstall, and re-run `bun audit`. Use when `devcheck` flags a transitive advisory — Bun's `update` is sticky on transitive resolutions, so the advisory may be a stale-lockfile false positive. If it survives the refresh, it's real. |
314
- | `bun run tree` | Generate directory structure doc |
333
+ | `bun run audit:fix` | `bun audit fix` — upgrade vulnerable packages to the lowest safe version within existing ranges (`--dry-run` previews, `--latest` rewrites ranges). First response when `devcheck` flags a transitive advisory; then `bun update <name>`, then `bun dedupe` |
334
+ | `bun run audit:refresh` | Delete `bun.lock` and reinstall. Last resort after `audit:fix`, `bun update <name>`, and `bun dedupe` — re-resolves every ranged dep (the framework pin included) and rewrites the lockfile as `lockfileVersion: 2` |
315
335
  | `bun run lint:mcp` | Run the MCP definition linter standalone (rule catalog: `api-linter` skill) |
316
336
  | `bun run lint:packaging` | Packaging surface checks — `server.json`/`manifest.json` env-var parity (run by devcheck) |
317
337
  | `bun run list-skills` | Print the skill registry |
338
+ | `bun run tree` | Generate directory structure doc |
318
339
  | `bun run format` | Auto-fix formatting (safe fixes only) |
319
340
  | `bun run format:unsafe` | Also apply Biome's unsafe autofixes — review the diff; they can change behavior |
320
341
  | `bun run test` | Run tests (Vitest — use `bun run test`, not `bun test`) |
@@ -324,15 +345,17 @@ When you complete a skill's checklist, check the boxes and add a completion time
324
345
  | `bun run changelog:check` | Verify `CHANGELOG.md` is in sync (used by devcheck) |
325
346
  | `bun run bundle` | Build, pack, and clean a `.mcpb` for one-click Claude Desktop install |
326
347
 
348
+ **CI is one file.** `.github/workflows/codeql.yml` (scaffolded) is the only GitHub Actions workflow: CodeQL is GitHub-owned end to end, and the file runs only while the repo's CodeQL *default setup* is turned off. Verification — `devcheck`, tests, the release gates — runs locally; don't add a workflow that re-runs it.
349
+
327
350
  ---
328
351
 
329
352
  ## Bundling
330
353
 
331
- `bun run bundle` produces a `.mcpb` extension bundle for one-click install in Claude Desktop. The pack step is followed by `scripts/clean-mcpb.ts`, which prunes dev dependencies (`mcpb clean`) and strips two classes of `node_modules/**` content that root-anchored `.mcpbignore` patterns cannot reach: dependency-shipped agent docs (`skills/`, `.claude/`, `.agents/`, `SKILL.md`) and platform-specific native bindings, which would otherwise lock the bundle to the platform it was packed on. MCPB is stdio-only — HTTP and Cloudflare Workers deployments are unaffected. Consumers who don't need it can delete `manifest.json` and `.mcpbignore`; `lint:packaging` skips cleanly.
354
+ `bun run bundle` produces a `.mcpb` extension bundle for one-click install in Claude Desktop. The pack step is followed by `scripts/clean-mcpb.ts`, which prunes dev dependencies (`mcpb clean`) and strips two classes of `node_modules/**` content that root-anchored `.mcpbignore` patterns cannot reach: dependency-shipped agent docs (`framework-skills/`, `skills/`, `.claude/`, `.agents/`, `SKILL.md`) and platform-specific native bindings, which would otherwise lock the bundle to the platform it was packed on. MCPB is stdio-only — HTTP and Cloudflare Workers deployments are unaffected. Consumers who don't need it can delete `manifest.json` and `.mcpbignore`; `lint:packaging` skips cleanly.
332
355
 
333
- **Adding an env var requires both files:** `server.json` (registry discovery, `environmentVariables[]`) and `manifest.json` (bundle install UX, `mcp_config.env` + `user_config`). `lint:packaging` (run by `devcheck`) verifies the env var names match.
356
+ **Adding an env var requires both files:** `server.json` (registry discovery, `environmentVariables[]`) and `manifest.json` (bundle install UX, `mcp_config.env` + `user_config`). `lint:packaging` (run by `devcheck`) verifies the env var names match, that every `user_config` option is wired into `mcp_config.env` as `"X": "${user_config.X}"` (the host substitutes nothing else — `"${X}"` reaches the server as that literal string), and that an optional string option carries `"default": ""`.
334
357
 
335
- **README install badges** (Claude Desktop `.mcpb`, Cursor, VS Code) and the `base64` / `encodeURIComponent` config-generation commands are ship-time concerns — run the `polish-docs-meta` skill, which carries the badge format, layout, and generation snippets in `skills/polish-docs-meta/references/readme.md`.
358
+ **README install badges** (Claude Desktop `.mcpb`, Cursor, VS Code) and the `base64` / `encodeURIComponent` config-generation commands are ship-time concerns — run the `polish-docs-meta` skill, which carries the badge format, layout, and generation snippets in `framework-skills/polish-docs-meta/references/readme.md`.
336
359
 
337
360
  ---
338
361
 
@@ -357,12 +380,18 @@ security: false # optional — true ONLY for a source
357
380
 
358
381
  `agent-notes` is an optional free-form field for maintenance agents processing the release downstream. Content here won't appear in the rendered CHANGELOG — it's consumed by agents running the `maintenance` skill. Use it for adoption instructions that don't fit the human-facing sections: new files to create, fields to populate, one-time migration steps. Omit entirely when there's nothing to say.
359
382
 
360
- **Section order** (Keep a Changelog): Added, Changed, Deprecated, Removed, Fixed, Security. Include only sections with entries — don't ship empty headers.
383
+ **Section order:** the Keep a Changelog sequence — Added, Changed, Deprecated, Removed, Fixed, Security — then `Dependencies` last. Include only sections with entries — don't ship empty headers.
361
384
 
362
385
  **Tag annotations** render as GitHub Release bodies via `--notes-from-tag`. They must be structured markdown — never a flat comma-separated string. Subject omits the version number (GitHub prepends it). See `changelog/template.md` for the full format reference.
363
386
 
364
387
  ---
365
388
 
389
+ ## Publishing
390
+
391
+ **Every release goes through a release PR, straight-through** — `git-wrapup`'s "Release PR mode", mode `straight-through`. One run: `git-wrapup` lands the commit stack on `release/<version>`, pushes it, and opens the PR (title = the release commit subject, body = the changelog entry plus a gates section); `release-and-publish` then fast-forwards `main` locally with `git merge --ff-only`, creates the tag on `main`'s tip, pushes `main` and the tag, deletes the branch, and publishes. A caller's brief may run a given release as `gated` instead — a `release-pr-review` pass on the open PR before `release-and-publish`. **Never merge through the GitHub UI or `gh pr merge`**: squash and rebase-merge are disabled in the repo settings because both rewrite the stack (rebase-merge also strips the SSH signatures), and a merge commit breaks the linear history.
392
+
393
+ ---
394
+
366
395
  ## Imports
367
396
 
368
397
  ```ts
@@ -389,7 +418,7 @@ import { getMyService } from '@/services/my-domain/my-service.js';
389
418
  - [ ] If wrapping external API: tests include at least one sparse payload case with omitted upstream fields
390
419
  - [ ] Registered in `createApp()` arrays (directly or via barrel exports)
391
420
  - [ ] Tests use `createMockContext()` from `@cyanheads/mcp-ts-core/testing`
392
- - [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = package name; `interface.shortDescription` from `package.json` description
393
- - [ ] `.codex-plugin/mcp.json` updated — server name key matches `package.json` name; env vars added for any required API keys
394
- - [ ] `.claude-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; inline `mcpServers` entry with server name key, env vars for any required API keys
421
+ - [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = the unscoped repo name (never the npm scope — `lint:packaging` enforces this); `interface.shortDescription` from `package.json` description
422
+ - [ ] `.codex-plugin/mcp.json` updated — server name key is the unscoped repo name; every user-supplied variable (API key, contact email, instance URL) is listed in `env_vars` so Codex forwards it from the user's environment. Never write `"KEY": ""` into `env` — an empty value replaces the user's exported key and is read as unset
423
+ - [ ] `.claude-plugin/plugin.json` populated — `name`, `version`, `description`, `author`, `repository`, `license`, `keywords` from `package.json`; inline `mcpServers` entry keyed by the unscoped repo name. Every user-supplied variable is declared under `userConfig` (`type`, `title`, `description`; `sensitive: true` for keys and tokens; `required: true` or `default: ""`) and referenced from `env` as `"KEY": "${user_config.<option>}"` — mirror the `user_config` block in `manifest.json`. Never write `"KEY": ""` into `env`
395
424
  - [ ] `bun run devcheck` passes
package/CLAUDE.md CHANGED
@@ -1,11 +1,11 @@
1
1
  # Developer Protocol
2
2
 
3
3
  **Server:** cpsc-recalls-mcp-server
4
- **Version:** 0.1.6
5
- **Framework:** [@cyanheads/mcp-ts-core](https://www.npmjs.com/package/@cyanheads/mcp-ts-core) `^0.11.0`
6
- **Engines:** Bun ≥1.3.0, Node ≥24.0.0
7
- **MCP SDK:** `@modelcontextprotocol/sdk` ^1.29.0
8
- **Zod:** ^4.4.3
4
+ **Version:** 0.1.8
5
+ **Framework:** [@cyanheads/mcp-ts-core](https://www.npmjs.com/package/@cyanheads/mcp-ts-core) `^0.13.6`
6
+ **Engines:** Bun ≥1.4.0, Node ≥24.0.0
7
+ **MCP SDK:** `@modelcontextprotocol/server` ^2.0.0 (protocol revisions 2026-07-28 and 2025-*)
8
+ **Zod:** ^4.6.5
9
9
 
10
10
  > **Read the framework docs first:** `node_modules/@cyanheads/mcp-ts-core/CLAUDE.md` contains the full API reference — builders, Context, error codes, exports, patterns. This file covers server-specific conventions only.
11
11
 
@@ -35,8 +35,9 @@ Tailor suggestions to what's actually missing or stale — don't recite the full
35
35
  - **Logic throws, framework catches.** Tool/resource handlers are pure — throw on failure, no `try/catch`. Plain `Error` is fine; the framework catches, classifies, and formats. Use error factories (`notFound()`, `validationError()`, etc.) when the error code matters.
36
36
  - **Use `ctx.log`** for request-scoped logging. No `console` calls.
37
37
  - **Use `ctx.state`** for tenant-scoped storage. Never access persistence directly.
38
- - **Check `ctx.elicit`** for presence before calling.
38
+ - **Need input the caller didn't supply?** `return ctx.requestInput(...)` and read `ctx.inputs` when the handler is re-entered. Never `await` for user input mid-handler.
39
39
  - **Secrets in env vars only** — never hardcoded.
40
+ - **Cut noise.** Add only what earns its place: no speculative generality, no guards for states the framework already prevents (Zod-validated params, classified errors), no abstraction until a third caller proves it, no option nothing sets.
40
41
  - **Close the loop on issues.** When implementing work tracked by a GitHub issue, comment on the issue with what landed and close it. Do both — a comment without a close leaves stale issues open; a close without a comment leaves no record of what shipped. The comment is for future readers — state the concrete changes, not the conversation that produced them.
41
42
 
42
43
  ---
@@ -91,7 +92,7 @@ export const itemData = resource('inventory://{itemId}', {
91
92
  params: z.object({ itemId: z.string().describe('Item identifier') }),
92
93
  auth: ['inventory:read'],
93
94
  async handler(params, ctx) {
94
- const item = await ctx.state.get(`item:${params.itemId}`);
95
+ const item = await ctx.state.get(`item/${params.itemId}`);
95
96
  if (!item) throw notFound(`Item ${params.itemId} not found`, { itemId: params.itemId });
96
97
  return item;
97
98
  },
@@ -125,6 +126,7 @@ import { parseEnvConfig } from '@cyanheads/mcp-ts-core/config';
125
126
  const ServerConfigSchema = z.object({
126
127
  apiKey: z.string().describe('External API key'),
127
128
  maxResults: z.coerce.number().default(100),
129
+ verboseLogging: z.stringbool().default(false).describe('Enable verbose logging'),
128
130
  });
129
131
 
130
132
  let _config: z.infer<typeof ServerConfigSchema> | undefined;
@@ -132,6 +134,7 @@ export function getServerConfig() {
132
134
  _config ??= parseEnvConfig(ServerConfigSchema, {
133
135
  apiKey: 'MY_API_KEY',
134
136
  maxResults: 'MY_MAX_RESULTS',
137
+ verboseLogging: 'MY_VERBOSE_LOGGING',
135
138
  });
136
139
  return _config;
137
140
  }
@@ -158,6 +161,22 @@ await createApp({
158
161
 
159
162
  `instructions` is optional server-level orientation, sent on every `initialize` as session-level context. Use it for deployment guidance (connection aliases, regional notes, scope hints) instead of repeating the same context across tool descriptions. Client adoption is uneven, but there's no downside when set.
160
163
 
164
+ ### Session posture and shutdown
165
+
166
+ Two more `createApp()` options shape how the server runs rather than how it presents itself:
167
+
168
+ ```ts
169
+ await createApp({
170
+ sessionMode: 'stateless', // or { default: 'stateful', require: 'stateful' }
171
+ setup(core) { startMyWatcher(core.config); },
172
+ async teardown() { await stopMyWatcher(); },
173
+ });
174
+ ```
175
+
176
+ `sessionMode` declares the HTTP session posture in `src/` instead of leaving it to a deployment's `MCP_SESSION_MODE`, which still wins whenever it carries a meaningful value (an empty string and an unsubstituted `${…}` placeholder read as unset and fall through to the option). Add `require: 'stateful'` when a tool asks the caller for input mid-handler via `ctx.requestInput`: startup then fails with a `ConfigurationError` rather than serving a mode in which a 2025-era client can never answer the prompt. Stdio is never refused.
177
+
178
+ `teardown(core)` is the `setup()` counterpart — release a watcher, socket, or non-`unref()`'d timer there. It runs after the transport stops and before the logger closes, on every shutdown path, and a signal-triggered shutdown then exits the process explicitly (0, or 1 if a step never settles within the framework's 10 s ceiling). This server's CPSC client holds no such handle — every fetch is per-request — so no `teardown` is wired.
179
+
161
180
  ---
162
181
 
163
182
  ## Context
@@ -166,13 +185,13 @@ Handlers receive a unified `ctx` object. Key properties:
166
185
 
167
186
  | Property | Description |
168
187
  |:---------|:------------|
169
- | `ctx.log` | Request-scoped logger — `.debug()`, `.info()`, `.notice()`, `.warning()`, `.error()`. Auto-correlates requestId, traceId, tenantId. |
188
+ | `ctx.log` | Request-scoped logger — `.debug()`, `.info()`, `.notice()`, `.warning()`, `.error()`. Auto-correlates requestId, traceId, tenantId. Dual-sink: Pino **and** `notifications/message` to the client, so treat it as client-visible. |
170
189
  | `ctx.state` | Tenant-scoped KV — `.get(key)`, `.set(key, value, { ttl? })`, `.delete(key)`, `.getMany(keys)`, `.list(prefix, { cursor, limit })`. Accepts any serializable value. |
171
- | `ctx.elicit` | Ask user for structured input — form call `(message, schema)` or `.url(message, url)` for an external link. **Check for presence first:** `if (ctx.elicit) { ... }` |
190
+ | `ctx.requestInput` | Suspend and ask the caller for more input — `return ctx.requestInput({ inputRequests: { key: inputRequired.elicit({ message, requestedSchema }) } })`. Never returns; the handler is re-entered with the answers. Always present. |
191
+ | `ctx.inputs` | Reader over a retried request's responses — `.accepted(key, schema)`, `.view(key)`, `.state()`, `.dropped`. Empty on the first round. |
172
192
  | `ctx.enrich` | Success-path agent context (empty-result notices, query echo, pagination totals) — `ctx.enrich(...)` or `.notice()` / `.total()` / `.echo()` / `.truncated()`. Reaches `structuredContent` and `content[]`; lands only when the definition declares an `enrichment` block (no-op otherwise). |
173
193
  | `ctx.content` | Non-text content blocks — `.image(data, mimeType)`, `.audio(data, mimeType)`, or `ctx.content(block)` for a raw block. Prepended to `content[]` after `format()`; never enters `structuredContent`. |
174
194
  | `ctx.signal` | `AbortSignal` for cancellation. |
175
- | `ctx.progress` | Task progress (present when `task: true`) — `.setTotal(n)`, `.increment()`, `.update(message)`. |
176
195
  | `ctx.requestId` | Unique request ID. |
177
196
  | `ctx.tenantId` | Tenant ID from JWT; `'default'` for stdio or HTTP with auth off. |
178
197
 
@@ -182,7 +201,7 @@ Handlers receive a unified `ctx` object. Key properties:
182
201
 
183
202
  Handlers throw — the framework catches, classifies, and formats.
184
203
 
185
- **Recommended: typed error contract.** Declare `errors: [{ reason, code, when, recovery, retryable? }]` on `tool()` / `resource()` to receive `ctx.fail(reason, …)` typed against the reason union. TypeScript catches typos at compile time, `data.reason` is auto-populated for observability, linter enforces conformance against the handler body. `recovery` is required (≥ 5 words, lint-validated) — the single source of truth for the agent's next move. Pass `ctx.recoveryFor('reason')` as the throw's data to put it on the wire (`data.recovery.hint`, mirrored into `content[]` text); override with an explicit `{ recovery: { hint: '...' } }` when dynamic runtime context matters. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`) bubble freely and don't need declaring.
204
+ **Recommended: typed error contract.** Declare `errors: [{ reason, code, when, recovery, retryable?, severity?, thrownBy? }]` on `tool()` / `resource()` to receive `ctx.fail(reason, …)` typed against the reason union. TypeScript catches typos at compile time, `data.reason` is auto-populated for observability, linter enforces conformance against the handler body. `recovery` is required (≥ 5 words, lint-validated) — the single source of truth for the agent's next move. Pass `ctx.recoveryFor('reason')` as the throw's data to put it on the wire (`data.recovery.hint`, mirrored into `content[]` text unless the message already contains it verbatim); override with an explicit `{ recovery: { hint: '...' } }` when dynamic runtime context matters. Forwarding it is lint-enforced per throw site (`error-contract-recovery-unforwarded`). Mark an entry the service layer throws with `thrownBy: 'service'` so `error-contract-unthrown` skips it — lint-only metadata, nothing at runtime reads it. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`, `RequestCancelled`) bubble freely and don't need declaring.
186
205
 
187
206
  ```ts
188
207
  import { JsonRpcErrorCode } from '@cyanheads/mcp-ts-core/errors';
@@ -215,7 +234,7 @@ throw new Error('Invalid query format'); // → ValidationError
215
234
 
216
235
  // McpError — when no factory exists for the code
217
236
  import { McpError, JsonRpcErrorCode } from '@cyanheads/mcp-ts-core/errors';
218
- throw new McpError(JsonRpcErrorCode.DatabaseError, 'Connection failed', { pool: 'primary' });
237
+ throw new McpError(JsonRpcErrorCode.InitializationFailed, 'Connection failed', { pool: 'primary' });
219
238
  ```
220
239
 
221
240
  See framework CLAUDE.md and the `api-errors` skill for the full auto-classification table, all available factories, and the contract reference.
@@ -253,11 +272,9 @@ src/
253
272
 
254
273
  ## Skills
255
274
 
256
- Skills are modular instructions in `skills/` at the project root. Read them directly when a task matches — e.g., `skills/add-tool/SKILL.md` when adding a tool. `bun run list-skills` prints the full registry.
275
+ Skills are modular instructions in `framework-skills/` at the project root. Read them directly when a task matches — e.g., `framework-skills/add-tool/SKILL.md` when adding a tool. `bun run list-skills` prints the full registry. The directory is deliberately not `skills/`: Claude Code and Codex auto-load a plugin's root `skills/`, so a server that ships `.claude-plugin/` or `.codex-plugin/` would hand these development skills to every agent that installs it. Keep `skills/` free for skills meant for those agents.
257
276
 
258
- **Chaining skills into pipelines.** When the user wants a multi-phase effort — build this server out, QA-and-fix the surface, update-and-ship — *and you can spawn sub-agents*, `skills/orchestrations/SKILL.md` sequences the task skills below into a gated pipeline with verification at each step. Read it to drive the run. Optional: skip it if you can't orchestrate sub-agents, and ignore it entirely if you were *spawned* as one — you've already been scoped to a single phase.
259
-
260
- **Agent skill directory:** Copy skills into the directory your agent discovers (Claude Code: `.claude/skills/`, others: equivalent). Skills then load as context without referencing `skills/` paths. After framework updates, run the `maintenance` skill — Phase B re-syncs the agent directory.
277
+ **Agent skill directory:** Copy skills into the directory your agent discovers (Claude Code: `.claude/skills/`, others: equivalent). Skills then load as context without referencing `framework-skills/` paths. After framework updates, run the `maintenance` skill — Phase B re-syncs the agent directory.
261
278
 
262
279
  Available skills:
263
280
 
@@ -276,8 +293,9 @@ Available skills:
276
293
  | `security-pass` | Audit server for MCP-flavored security gaps: output injection, scope blast radius, input sinks, tenant isolation |
277
294
  | `code-simplifier` | Post-session cleanup against `git diff` — modernize syntax, consolidate duplication, align with the codebase |
278
295
  | `polish-docs-meta` | Finalize docs, README, metadata, and agent protocol for shipping |
279
- | `git-wrapup` | Land working-tree changes as a versioned commit + annotated tag — version bump, changelog, verify, tag. Local only. |
280
- | `release-and-publish` | Push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
296
+ | `git-wrapup` | Land working-tree changes as a commit stack — version bump, changelog, verify, commit by concern, release commit on top. No tag, no push to main; opens the release PR when the project declares release PR mode |
297
+ | `release-pr-review` | Review pass on an open release PR — simplifier + correctness review, fixes as ordinary commits on top of the stack, PR body kept in sync. Release PR mode only |
298
+ | `release-and-publish` | Fast-forward merge (release PR mode) + tag + push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
281
299
  | `maintenance` | Investigate changelogs, adopt upstream changes, sync skills to agent dirs |
282
300
  | `orchestrations` | Chain task skills into a gated multi-phase pipeline — build-out, QA-fix, update-ship — when you can spawn sub-agents |
283
301
  | `report-issue-framework` | File a bug or feature request against `@cyanheads/mcp-ts-core` via `gh` CLI |
@@ -286,7 +304,7 @@ Available skills:
286
304
  | `api-auth` | Auth modes, scopes, JWT/OAuth |
287
305
  | `api-canvas` | DataCanvas: register tabular data, run SQL, export, plus the `spillover()` helper for big result sets — Tier 3 opt-in |
288
306
  | `api-config` | AppConfig, parseConfig, env vars |
289
- | `api-context` | Context interface, logger, state, progress |
307
+ | `api-context` | Context interface, RequestContext, logger, state, multi-round-trip input |
290
308
  | `api-errors` | McpError, JsonRpcErrorCode, error patterns |
291
309
  | `api-linter` | Definition linter rule catalog — invoked by `bun run lint:mcp` and `devcheck` |
292
310
  | `api-mirror` | MirrorService: persistent self-refreshing local mirror (embedded SQLite + FTS5) of a bulk upstream dataset — Tier 3 opt-in |
@@ -296,13 +314,15 @@ Available skills:
296
314
  | `api-telemetry` | OTel catalog: spans, metrics, completion logs, env config, cardinality rules |
297
315
  | `api-workers` | Cloudflare Workers runtime |
298
316
 
317
+ **Chaining skills into pipelines.** When the user wants a multi-phase effort — build this server out, QA-and-fix the surface, update-and-ship — *and you can spawn sub-agents*, `framework-skills/orchestrations/SKILL.md` sequences the task skills above into a gated pipeline with verification at each step. Read it to drive the run. Optional: skip it if you can't orchestrate sub-agents, and ignore it entirely if you were *spawned* as one — you've already been scoped to a single phase.
318
+
299
319
  When you complete a skill's checklist, check the boxes and add a completion timestamp at the end (e.g., `Completed: 2026-03-11`).
300
320
 
301
321
  ---
302
322
 
303
323
  ## Commands
304
324
 
305
- **Runtime:** Scripts use `bun run scripts/X.ts`. All commands use `bun run <cmd>`.
325
+ **Runtime:** Scripts use Bun's native TypeScript execution — `bun run <cmd>` is the standard invocation.
306
326
 
307
327
  | Command | Purpose |
308
328
  |:--------|:--------|
@@ -310,11 +330,12 @@ When you complete a skill's checklist, check the boxes and add a completion time
310
330
  | `bun run rebuild` | Clean + build |
311
331
  | `bun run clean` | Remove build artifacts |
312
332
  | `bun run devcheck` | Lint + format + typecheck + security + changelog sync |
313
- | `bun run audit:refresh` | Delete `bun.lock`, reinstall, and re-run `bun audit`. Use when `devcheck` flags a transitive advisory — Bun's `update` is sticky on transitive resolutions, so the advisory may be a stale-lockfile false positive. If it survives the refresh, it's real. |
314
- | `bun run tree` | Generate directory structure doc |
333
+ | `bun run audit:fix` | `bun audit fix` — upgrade vulnerable packages to the lowest safe version within existing ranges (`--dry-run` previews, `--latest` rewrites ranges). First response when `devcheck` flags a transitive advisory; then `bun update <name>`, then `bun dedupe` |
334
+ | `bun run audit:refresh` | Delete `bun.lock` and reinstall. Last resort after `audit:fix`, `bun update <name>`, and `bun dedupe` — re-resolves every ranged dep (the framework pin included) and rewrites the lockfile as `lockfileVersion: 2` |
315
335
  | `bun run lint:mcp` | Run the MCP definition linter standalone (rule catalog: `api-linter` skill) |
316
336
  | `bun run lint:packaging` | Packaging surface checks — `server.json`/`manifest.json` env-var parity (run by devcheck) |
317
337
  | `bun run list-skills` | Print the skill registry |
338
+ | `bun run tree` | Generate directory structure doc |
318
339
  | `bun run format` | Auto-fix formatting (safe fixes only) |
319
340
  | `bun run format:unsafe` | Also apply Biome's unsafe autofixes — review the diff; they can change behavior |
320
341
  | `bun run test` | Run tests (Vitest — use `bun run test`, not `bun test`) |
@@ -324,15 +345,17 @@ When you complete a skill's checklist, check the boxes and add a completion time
324
345
  | `bun run changelog:check` | Verify `CHANGELOG.md` is in sync (used by devcheck) |
325
346
  | `bun run bundle` | Build, pack, and clean a `.mcpb` for one-click Claude Desktop install |
326
347
 
348
+ **CI is one file.** `.github/workflows/codeql.yml` (scaffolded) is the only GitHub Actions workflow: CodeQL is GitHub-owned end to end, and the file runs only while the repo's CodeQL *default setup* is turned off. Verification — `devcheck`, tests, the release gates — runs locally; don't add a workflow that re-runs it.
349
+
327
350
  ---
328
351
 
329
352
  ## Bundling
330
353
 
331
- `bun run bundle` produces a `.mcpb` extension bundle for one-click install in Claude Desktop. The pack step is followed by `scripts/clean-mcpb.ts`, which prunes dev dependencies (`mcpb clean`) and strips two classes of `node_modules/**` content that root-anchored `.mcpbignore` patterns cannot reach: dependency-shipped agent docs (`skills/`, `.claude/`, `.agents/`, `SKILL.md`) and platform-specific native bindings, which would otherwise lock the bundle to the platform it was packed on. MCPB is stdio-only — HTTP and Cloudflare Workers deployments are unaffected. Consumers who don't need it can delete `manifest.json` and `.mcpbignore`; `lint:packaging` skips cleanly.
354
+ `bun run bundle` produces a `.mcpb` extension bundle for one-click install in Claude Desktop. The pack step is followed by `scripts/clean-mcpb.ts`, which prunes dev dependencies (`mcpb clean`) and strips two classes of `node_modules/**` content that root-anchored `.mcpbignore` patterns cannot reach: dependency-shipped agent docs (`framework-skills/`, `skills/`, `.claude/`, `.agents/`, `SKILL.md`) and platform-specific native bindings, which would otherwise lock the bundle to the platform it was packed on. MCPB is stdio-only — HTTP and Cloudflare Workers deployments are unaffected. Consumers who don't need it can delete `manifest.json` and `.mcpbignore`; `lint:packaging` skips cleanly.
332
355
 
333
- **Adding an env var requires both files:** `server.json` (registry discovery, `environmentVariables[]`) and `manifest.json` (bundle install UX, `mcp_config.env` + `user_config`). `lint:packaging` (run by `devcheck`) verifies the env var names match.
356
+ **Adding an env var requires both files:** `server.json` (registry discovery, `environmentVariables[]`) and `manifest.json` (bundle install UX, `mcp_config.env` + `user_config`). `lint:packaging` (run by `devcheck`) verifies the env var names match, that every `user_config` option is wired into `mcp_config.env` as `"X": "${user_config.X}"` (the host substitutes nothing else — `"${X}"` reaches the server as that literal string), and that an optional string option carries `"default": ""`.
334
357
 
335
- **README install badges** (Claude Desktop `.mcpb`, Cursor, VS Code) and the `base64` / `encodeURIComponent` config-generation commands are ship-time concerns — run the `polish-docs-meta` skill, which carries the badge format, layout, and generation snippets in `skills/polish-docs-meta/references/readme.md`.
358
+ **README install badges** (Claude Desktop `.mcpb`, Cursor, VS Code) and the `base64` / `encodeURIComponent` config-generation commands are ship-time concerns — run the `polish-docs-meta` skill, which carries the badge format, layout, and generation snippets in `framework-skills/polish-docs-meta/references/readme.md`.
336
359
 
337
360
  ---
338
361
 
@@ -357,12 +380,18 @@ security: false # optional — true ONLY for a source
357
380
 
358
381
  `agent-notes` is an optional free-form field for maintenance agents processing the release downstream. Content here won't appear in the rendered CHANGELOG — it's consumed by agents running the `maintenance` skill. Use it for adoption instructions that don't fit the human-facing sections: new files to create, fields to populate, one-time migration steps. Omit entirely when there's nothing to say.
359
382
 
360
- **Section order** (Keep a Changelog): Added, Changed, Deprecated, Removed, Fixed, Security. Include only sections with entries — don't ship empty headers.
383
+ **Section order:** the Keep a Changelog sequence — Added, Changed, Deprecated, Removed, Fixed, Security — then `Dependencies` last. Include only sections with entries — don't ship empty headers.
361
384
 
362
385
  **Tag annotations** render as GitHub Release bodies via `--notes-from-tag`. They must be structured markdown — never a flat comma-separated string. Subject omits the version number (GitHub prepends it). See `changelog/template.md` for the full format reference.
363
386
 
364
387
  ---
365
388
 
389
+ ## Publishing
390
+
391
+ **Every release goes through a release PR, straight-through** — `git-wrapup`'s "Release PR mode", mode `straight-through`. One run: `git-wrapup` lands the commit stack on `release/<version>`, pushes it, and opens the PR (title = the release commit subject, body = the changelog entry plus a gates section); `release-and-publish` then fast-forwards `main` locally with `git merge --ff-only`, creates the tag on `main`'s tip, pushes `main` and the tag, deletes the branch, and publishes. A caller's brief may run a given release as `gated` instead — a `release-pr-review` pass on the open PR before `release-and-publish`. **Never merge through the GitHub UI or `gh pr merge`**: squash and rebase-merge are disabled in the repo settings because both rewrite the stack (rebase-merge also strips the SSH signatures), and a merge commit breaks the linear history.
392
+
393
+ ---
394
+
366
395
  ## Imports
367
396
 
368
397
  ```ts
@@ -389,7 +418,7 @@ import { getMyService } from '@/services/my-domain/my-service.js';
389
418
  - [ ] If wrapping external API: tests include at least one sparse payload case with omitted upstream fields
390
419
  - [ ] Registered in `createApp()` arrays (directly or via barrel exports)
391
420
  - [ ] Tests use `createMockContext()` from `@cyanheads/mcp-ts-core/testing`
392
- - [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = package name; `interface.shortDescription` from `package.json` description
393
- - [ ] `.codex-plugin/mcp.json` updated — server name key matches `package.json` name; env vars added for any required API keys
394
- - [ ] `.claude-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; inline `mcpServers` entry with server name key, env vars for any required API keys
421
+ - [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = the unscoped repo name (never the npm scope — `lint:packaging` enforces this); `interface.shortDescription` from `package.json` description
422
+ - [ ] `.codex-plugin/mcp.json` updated — server name key is the unscoped repo name; every user-supplied variable (API key, contact email, instance URL) is listed in `env_vars` so Codex forwards it from the user's environment. Never write `"KEY": ""` into `env` — an empty value replaces the user's exported key and is read as unset
423
+ - [ ] `.claude-plugin/plugin.json` populated — `name`, `version`, `description`, `author`, `repository`, `license`, `keywords` from `package.json`; inline `mcpServers` entry keyed by the unscoped repo name. Every user-supplied variable is declared under `userConfig` (`type`, `title`, `description`; `sensitive: true` for keys and tokens; `required: true` or `default: ""`) and referenced from `env` as `"KEY": "${user_config.<option>}"` — mirror the `user_config` block in `manifest.json`. Never write `"KEY": ""` into `env`
395
424
  - [ ] `bun run devcheck` passes
package/Dockerfile CHANGED
@@ -4,7 +4,7 @@
4
4
  # This stage installs all dependencies (including dev), builds the TypeScript
5
5
  # source code into JavaScript, and prepares the production assets.
6
6
  # ==============================================================================
7
- FROM oven/bun:1.3.14 AS build
7
+ FROM --platform=$BUILDPLATFORM oven/bun:1.4.0 AS build
8
8
 
9
9
  WORKDIR /usr/src/app
10
10
 
@@ -30,7 +30,7 @@ RUN bun run build
30
30
  # application. It uses a slim base image and only includes production
31
31
  # dependencies and build artifacts.
32
32
  # ==============================================================================
33
- FROM oven/bun:1.3.14-slim AS production
33
+ FROM oven/bun:1.4.0-slim AS production
34
34
 
35
35
  WORKDIR /usr/src/app
36
36
 
@@ -51,8 +51,13 @@ COPY package.json bun.lock ./
51
51
 
52
52
  # Install only production dependencies, ignoring any lifecycle scripts (like 'prepare')
53
53
  # that are not needed in the final production image.
54
+ # `--omit=peer` drops the framework's optional peer tiers (test runner, service
55
+ # SDKs, parsers) that Bun would otherwise auto-install. Anything this server
56
+ # actually imports belongs in its own `dependencies`, so nothing needed at
57
+ # runtime is lost. The OTEL step below carries the same flag — without it, that
58
+ # install re-resolves the graph and pulls every optional peer back in.
54
59
  RUN --mount=type=cache,target=/root/.bun/install/cache \
55
- bun install --production --frozen-lockfile --ignore-scripts
60
+ bun install --production --omit=peer --frozen-lockfile --ignore-scripts
56
61
 
57
62
  # Conditionally install OpenTelemetry optional peer dependencies (Tier 3).
58
63
  # These are not bundled by default to keep the base image lean. Enable at build time
@@ -60,7 +65,7 @@ RUN --mount=type=cache,target=/root/.bun/install/cache \
60
65
  ARG OTEL_ENABLED=true
61
66
  RUN --mount=type=cache,target=/root/.bun/install/cache \
62
67
  if [ "$OTEL_ENABLED" = "true" ]; then \
63
- bun add --omit=dev --ignore-scripts @hono/otel \
68
+ bun add --omit=dev --omit=peer --ignore-scripts @hono/otel \
64
69
  @opentelemetry/instrumentation-http \
65
70
  @opentelemetry/exporter-metrics-otlp-http \
66
71
  @opentelemetry/exporter-trace-otlp-http \
package/LICENSE CHANGED
@@ -186,7 +186,7 @@ Apache License
186
186
  same "printed page" as the copyright notice for easier
187
187
  identification within third-party archives.
188
188
 
189
- Copyright 2025 Casey Hand @cyanheads
189
+ Copyright 2026 Casey Hand @cyanheads
190
190
 
191
191
  Licensed under the Apache License, Version 2.0 (the "License");
192
192
  you may not use this file except in compliance with the License.
package/README.md CHANGED
@@ -7,7 +7,7 @@
7
7
 
8
8
  <div align="center">
9
9
 
10
- [![Version](https://img.shields.io/badge/Version-0.1.6-blue.svg?style=flat-square)](./CHANGELOG.md) [![License](https://img.shields.io/badge/License-Apache%202.0-orange.svg?style=flat-square)](./LICENSE) [![Docker](https://img.shields.io/badge/Docker-ghcr.io-2496ED?style=flat-square&logo=docker&logoColor=white)](https://github.com/users/cyanheads/packages/container/package/cpsc-recalls-mcp-server) [![MCP SDK](https://img.shields.io/badge/MCP%20SDK-^1.29.0-green.svg?style=flat-square)](https://modelcontextprotocol.io/) [![npm](https://img.shields.io/npm/v/@cyanheads/cpsc-recalls-mcp-server?style=flat-square&logo=npm&logoColor=white)](https://www.npmjs.com/package/@cyanheads/cpsc-recalls-mcp-server) [![TypeScript](https://img.shields.io/badge/TypeScript-^7.0.2-3178C6.svg?style=flat-square)](https://www.typescriptlang.org/) [![Bun](https://img.shields.io/badge/Bun-v1.3.0+-blueviolet.svg?style=flat-square)](https://bun.sh/)
10
+ [![Version](https://img.shields.io/badge/Version-0.1.8-blue.svg?style=flat-square)](./CHANGELOG.md) [![License](https://img.shields.io/badge/License-Apache%202.0-orange.svg?style=flat-square)](./LICENSE) [![Docker](https://img.shields.io/badge/Docker-ghcr.io-2496ED?style=flat-square&logo=docker&logoColor=white)](https://github.com/users/cyanheads/packages/container/package/cpsc-recalls-mcp-server) [![MCP SDK](https://img.shields.io/badge/MCP%20SDK-^2.0.0-green.svg?style=flat-square)](https://modelcontextprotocol.io/) [![npm](https://img.shields.io/npm/v/@cyanheads/cpsc-recalls-mcp-server?style=flat-square&logo=npm&logoColor=white)](https://www.npmjs.com/package/@cyanheads/cpsc-recalls-mcp-server) [![TypeScript](https://img.shields.io/badge/TypeScript-^7.0.2-3178C6.svg?style=flat-square)](https://www.typescriptlang.org/) [![Bun](https://img.shields.io/badge/Bun-v1.4.0+-blueviolet.svg?style=flat-square)](https://bun.sh/)
11
11
 
12
12
  </div>
13
13
 
@@ -27,9 +27,11 @@
27
27
 
28
28
  ---
29
29
 
30
- ## Tools
30
+ ## Overview
31
31
 
32
- 3 tools for searching and retrieving CPSC consumer product recall data:
32
+ Consumer product recalls from the CPSC [saferproducts.gov](https://www.saferproducts.gov/) database — toys, electronics, furniture, appliances, children's products, tools, and clothing. Search recalls by product, brand, retailer, or hazard, fetch full detail for a specific recall number, or pull a recent-recalls feed for a date window. Runs as a stdio process, a local Streamable HTTP server, or the public hosted endpoint above.
33
+
34
+ ### Tools
33
35
 
34
36
  | Tool | Description |
35
37
  |:---|:---|
@@ -37,79 +39,56 @@
37
39
  | `cpsc_get_recall` | Full detail for a single recall by recall number — hazards, remedy, products, injuries, images, and the official CPSC page |
38
40
  | `cpsc_get_recent` | Fetch the most recent recalls ordered newest-first, scoped to a configurable date window |
39
41
 
40
- **CPSC jurisdiction:** Consumer products only — toys, electronics, furniture, appliances, children's products, tools, and clothing. Food and drugs (FDA), motor vehicles and tires (NHTSA), boats (USCG), and pesticides (EPA) are not in this database. Every response includes a jurisdiction note.
41
-
42
- Data sourced from the [U.S. Consumer Product Safety Commission](https://www.saferproducts.gov/) via the CPSC public recalls API.
42
+ CPSC jurisdiction is consumer products only — food/drugs (FDA), motor vehicles/tires (NHTSA), boats (USCG), and pesticides (EPA) are not in this database; every response carries a jurisdiction note.
43
43
 
44
- ### `cpsc_search_recalls`
44
+ ## Capability reference
45
45
 
46
- Search recalls with flexible filtering across title, product, organization, hazard, remedy, and description fields.
46
+ ### `cpsc_search_recalls` <sub>tool</sub>
47
47
 
48
- - Filter by `title_search`, `product_name`, `manufacturer`, `retailer`, `importer`, `distributor`, `remedy`, or `description_search` — all optional substring matches, applied upstream, combining with AND
49
- - `title_search` is usually the highest-signal filter: CPSC titles name the brand, the product, and the hazard
50
- - `hazard_search` is a client-side filter applied after the upstream fetch — it matches when the term appears in hazard descriptions, product names, **or** remedy instructions (case-insensitive). Use it for hazard concepts like "fire", "choking", or "burn"; the upstream `Hazard` parameter is recognized but never matches, so it is not exposed
51
- - `remedy` searches the free-text remedy instructions, not the `remedy_options` type enum — `remedy: "repair"` matches records whose `remedy_options` list only `Refund` but whose instructions describe a free repair kit
52
- - Two independent date axes: `date_start` / `date_end` bound the recall issue date, `updated_start` / `updated_end` bound the date CPSC last published the record. A 2003 recall re-published in 2025 matches `updated_start: "2025-01-01"`. All four must be real calendar dates — `2026-02-31` and `2026-99-99` are rejected at input validation, and a reversed range fails with `invalid_date_range` rather than silently returning nothing
53
- - Client-side limit (1–200, default 20) and `offset` (default 0) applied after fetching all matching records. Page with `offset: 0, 20, 40`; an offset at or past `total_found` returns an empty result set rather than an error
54
- - `total_found` counts matches after `hazard_search` is applied and before `offset`/`limit` narrow the window; `has_more` is the paging signal; `truncated` stays limit-only and does not move with `offset`
55
- - Returns hazard descriptions, remedy options, remedy instructions, product list, UPCs, manufacturer/importer/retailer names, images, and the CPSC recall page URL
56
- - Manufacturer and importer are reported and rendered as separate roles — CPSC org names contain commas, so multiple orgs in one role are separated with `; `
57
- - Per-recall `data_quality_notes` records gaps in the upstream record (no hazard text, no product entries); empty when nothing is missing
58
- - When `manufacturer` returns no results, try `importer`, `retailer`, or `distributor` — many recalls list one of those as the primary organization
59
- - Deterministic upstream rejections surface as `upstream_rejected` (`retryable: false`) and carry the CPSC message; transient outages stay on `upstream_error` (`retryable: true`)
48
+ - Optional substring filters — `product_name`, `manufacturer`, `retailer`, `importer`, `distributor`, `title_search`, `description_search`, `remedy` (free-text instructions, not the `remedy_options` enum) — all combine with AND; `title_search` is usually highest-signal, `hazard_search` matches hazard text, product names, or remedy instructions client-side (the upstream `Hazard` parameter never matches, so it isn't exposed)
49
+ - Two independent date axes: `date_start`/`date_end` bound the recall issue date, `updated_start`/`updated_end` bound the date CPSC last published it; all four must be real calendar dates and a reversed range throws `invalid_date_range`
50
+ - Client-side `limit` (1–200, default 20) and `offset` (default 0) applied after the full upstream fetch; `total_found` counts after `hazard_search` and before `offset`/`limit` narrow the window, `has_more` is the paging signal, `truncated` is limit-only
51
+ - Returns hazard descriptions, remedy options and instructions, products, UPCs, manufacturer/importer/retailer/distributor names, images, `cpsc_url`, and per-recall `data_quality_notes`; manufacturer and importer render as separate roles — try `importer`, `retailer`, or `distributor` when `manufacturer` comes back empty
52
+ - `no_results` is a typed error, not an empty array; `upstream_rejected` (non-retryable) relays CPSC's own rejection, `upstream_error` (retryable) covers transient outages
60
53
 
61
54
  ---
62
55
 
63
- ### `cpsc_get_recall`
64
-
65
- Full detail for a single CPSC recall by recall number.
56
+ ### `cpsc_get_recall` <sub>tool</sub>
66
57
 
67
58
  - Accepts modern 5-digit recall numbers (e.g. `"25043"`) and historical 1998–2001 records with letter suffixes (e.g. `"99003a"`)
68
- - Returns the complete record: full description, all hazard descriptions, remedy type and instructions, all product variants with unit counts, UPCs, incident/injury narrative, manufacturer and importer names, retailer names with sale date ranges, country of manufacture, images, and coordinated agency recall URLs
69
- - Model numbers are typically embedded in the description text, not in a structured field
70
- - `description` is nullable — a small number of genuine CPSC records carry no description; the record is still returned and the absence is stated rather than rendered as a blank section
71
- - Manufacturer and importer are rendered under separate headings, so role attribution survives into `content[]`
72
- - `data_quality_notes` records gaps in the upstream record (absent description, no hazard text, no product entries); empty when nothing is missing
73
- - Use `cpsc_search_recalls` or `cpsc_get_recent` to find a recall number first
59
+ - Returns the complete record — full description, all hazard and remedy detail, every product variant, UPCs, incident/injury narrative, manufacturer/importer/retailer/distributor names, country of manufacture, images, and coordinated-agency recall URLs
60
+ - `description` is nullable — a small number of genuine CPSC records carry no description text, and model numbers are usually embedded there rather than in a structured field
61
+ - Manufacturer and importer render under separate headings so role attribution survives into `content[]`
62
+ - `data_quality_notes` records gaps in the upstream record (absent description, hazard text, or product entries); empty when nothing is missing
63
+ - `not_found` when the recall number doesn't exist — resolve one via `cpsc_search_recalls` or `cpsc_get_recent` first; `upstream_rejected` (non-retryable) relays CPSC's own rejection, `upstream_error` (retryable) covers transient outages
74
64
 
75
65
  ---
76
66
 
77
- ### `cpsc_get_recent`
67
+ ### `cpsc_get_recent` <sub>tool</sub>
78
68
 
79
- Fetch the most recent CPSC recalls, ordered newest-first.
80
-
81
- - Configurable look-back window of 1–365 days (default 30)
82
- - Limit of 1–100 results (default 20), with `offset` (default 0) to page through `total_found`. Narrowing `days` cannot page — the window is anchored to today, so shrinking it drops the oldest records rather than advancing past the newest
83
- - `has_more` is the paging signal; `truncated` stays limit-only and does not move with `offset`
84
- - Always applies a date window — without one, the upstream API returns 9,800+ records
85
- - Returns a lightweight record per recall: number, date, title, hazards, remedy types, product names, and CPSC URL
86
- - Per-recall `data_quality_notes` records gaps in the upstream record (no hazard text, no product entries); empty when nothing is missing
69
+ - Look-back window of 1–365 days (default 30), always applied — without one the upstream API returns 9,800+ records
70
+ - `limit` (1–100, default 20) and `offset` (default 0) page through `total_found`; narrowing `days` cannot page further back — the window is anchored to today, so shrinking it drops the oldest records rather than advancing past the newest
71
+ - `has_more` is the paging signal; `truncated` stays limit-only and doesn't move with `offset`
72
+ - Returns a lightweight record per recall — number, date, title, hazards, remedy types, product names, `cpsc_url` — plus `data_quality_notes` for gaps CPSC left empty
87
73
  - Use `cpsc_get_recall` to retrieve full detail for any result
88
74
 
89
75
  ## Features
90
76
 
91
- Built on [`@cyanheads/mcp-ts-core`](https://github.com/cyanheads/mcp-ts-core):
92
-
93
- - Declarative tool definitions — single file per tool, framework handles registration and validation
94
- - Unified error handling — handlers throw, framework catches, classifies, and formats
95
- - Pluggable auth: `none`, `jwt`, `oauth`
96
- - Swappable storage backends: `in-memory`, `filesystem`, `Supabase`, `Cloudflare KV/R2/D1`
97
- - Structured logging with optional OpenTelemetry tracing
98
- - STDIO and Streamable HTTP transports
77
+ Built on [`@cyanheads/mcp-ts-core`](https://github.com/cyanheads/mcp-ts-core): stdio and Streamable HTTP transports, pluggable auth (`none` / `jwt` / `oauth`), swappable storage (`in-memory`, `filesystem`, `Supabase`, `Cloudflare KV/R2/D1`), structured logging with optional OpenTelemetry tracing.
99
78
 
100
79
  CPSC-specific:
101
80
 
102
- - Full integration with the CPSC saferproducts.gov public recalls API
103
- - Client-side filtering applied over complete API result sets for accurate `total_found` counts
104
- - Jurisdiction boundary documented in every response — prevents misattribution of food, vehicle, or drug recalls
81
+ - Full client for the CPSC saferproducts.gov public recalls API — search, single-recall detail, and a recent-recalls feed
82
+ - Client-side filtering (`hazard_search`) applied over the complete upstream result set so `total_found` and `has_more` stay accurate
83
+ - Handles both modern 5-digit recall numbers and historical 1998–2001 records with letter suffixes
84
+ - Jurisdiction boundary documented in every response — flags food, vehicle, and drug recalls as out of scope before an agent misattributes them
105
85
 
106
86
  Agent-friendly output:
107
87
 
108
- - Jurisdiction note on every response — agents can route callers to the correct agency (FDA, NHTSA, USCG, EPA) when the product is out of scope
109
- - `total_found`, `offset`, `has_more`, and `truncated` fields on search/recent responses — agents can tell when results are clipped and page through the rest with `offset`
110
- - `cpsc_url` on every recall — authoritative source link for consumer verification
111
- - `source_note` on every response, plus `(CPSC source text)` labels and blockquotes in the rendered output — relayed CPSC narrative is marked as source data, distinct from the server's own guidance
112
- - `data_quality_notes` on every response — gaps observed in the upstream record, derived from which fields CPSC left empty rather than any judgement about the recall
88
+ - Provenance on every response — `source_note`, `cpsc_url`, and `(CPSC source text)` blockquote labels distinguish relayed CPSC narrative from the server's own guidance
89
+ - Pagination discriminators — `total_found`, `offset`, `has_more`, and `truncated` on every search/recent response so agents can tell when results are clipped and page with `offset`
90
+ - `data_quality_notes` on every response — gaps observed in the upstream record (missing hazard text, no product entries), derived from which fields CPSC left blank rather than any judgment call
91
+ - Jurisdiction note (`cpsc_jurisdiction`) on every response — lets agents route callers to the correct agency (FDA, NHTSA, USCG, EPA) when a product is out of scope
113
92
 
114
93
  ## Getting started
115
94
 
@@ -189,7 +168,7 @@ MCP_TRANSPORT_TYPE=http MCP_HTTP_PORT=3010 bun run start:http
189
168
 
190
169
  ### Prerequisites
191
170
 
192
- - [Bun v1.3.0](https://bun.sh/) or higher (or Node.js v24+).
171
+ - [Bun v1.4.0](https://bun.sh/) or higher (or Node.js v24+).
193
172
  - No API key required — the CPSC public recalls API is freely accessible.
194
173
 
195
174
  ### Installation
@@ -230,6 +209,7 @@ All configuration is validated at startup via Zod schemas. Key environment varia
230
209
  | `MCP_HTTP_HOST` | HTTP server host | `127.0.0.1` |
231
210
  | `MCP_HTTP_ENDPOINT_PATH` | HTTP endpoint path | `/mcp` |
232
211
  | `MCP_PUBLIC_URL` | Public origin for TLS-terminating reverse-proxy deployments | — |
212
+ | `MCP_SESSION_MODE` | Session handling: `auto`, `stateful`, or `stateless`. The server declares `stateless` in `src/index.ts`; setting this overrides it. | `stateless` |
233
213
  | `MCP_AUTH_MODE` | Authentication: `none`, `jwt`, or `oauth` | `none` |
234
214
  | `MCP_LOG_LEVEL` | Log level (`debug`, `info`, `warning`, `error`) | `info` |
235
215
  | `LOGS_DIR` | Directory for log files (Node.js only) | `<project-root>/logs` |
@@ -289,7 +269,7 @@ See [`CLAUDE.md`](./CLAUDE.md) / [`AGENTS.md`](./AGENTS.md) for development guid
289
269
 
290
270
  ## Contributing
291
271
 
292
- Issues and pull requests are welcome. Run checks and tests before submitting:
272
+ Issues are welcome. Run checks and tests before submitting:
293
273
 
294
274
  ```sh
295
275
  bun run devcheck
@@ -0,0 +1,37 @@
1
+ ---
2
+ summary: "Adopts mcp-ts-core 0.12.3 and MCP SDK v2 — the HTTP endpoint serves protocol revision 2026-07-28 alongside the 2025 era, tool inputs are strict so an undeclared argument key is rejected instead of ignored, and HTTP session mode is now stateless explicitly."
3
+ breaking: false
4
+ security: false
5
+ ---
6
+
7
+ # 0.1.7 — 2026-08-24
8
+
9
+ ## Changed
10
+
11
+ - **Tool inputs are strict.** An argument key none of `cpsc_search_recalls`, `cpsc_get_recall`, or `cpsc_get_recent` declares is rejected by name with a validation error, where it was previously dropped and the call ran without it. A caller sending a misspelled or unsupported parameter now gets a clean error naming the key instead of a silent success.
12
+ - **The HTTP endpoint serves MCP protocol revision `2026-07-28`** alongside the 2025 revisions; a 2025-era client negotiates exactly as before.
13
+ - **HTTP session mode is `stateless` explicitly** — `MCP_SESSION_MODE` is set in `.env.example` and documented in the README config table. The schema default `auto` resolves to stateful, so a source run and the published container previously resolved to different modes; `/.well-known/mcp.json` also reports the resolved mode rather than `auto`.
14
+ - **Advertised schemas moved to JSON Schema 2020-12**, and `outputSchema` now declares the error envelope. A client that rejects draft-07 schemas outright, or that validates `structuredContent` without checking `isError`, no longer fails against these tools.
15
+ - **`ctx.log` output reaches the client** as `notifications/message` at its RFC 5424 level, gated by the client's `logging/setLevel`.
16
+ - **`CpscRecallService.fetchRecalls` passes the handler context straight to `fetchWithTimeout` and `withRetry`** instead of minting a synthetic one, so upstream fetch and retry telemetry carries the calling request's trace, span, and tenant IDs.
17
+ - **Docker: Bun pins move to `1.4.0`** on both stages, the production install drops the framework's optional peer tiers (`--omit=peer`), and the build stage runs on the native platform (`--platform=$BUILDPLATFORM`) rather than under emulation on the amd64 leg.
18
+ - **`tsconfig.json` splits typecheck from emit** — it covers `tests/` alongside `src/` under `noEmit`, while `tsconfig.build.json` carries `rootDir: "src"` for the build. The test suites reach `tsc` for the first time.
19
+ - **`.github/CONTRIBUTING.md` and `CODE_OF_CONDUCT.md`** added, and `SECURITY.md` routes vulnerability reports to `security@caseyjhand.com`.
20
+ - Framework skills, `scripts/`, and `changelog/template.md` re-synced to what mcp-ts-core 0.12.3 ships; the `outdated` allowlist in `devcheck.config.json` is empty again, so every dependency is gated.
21
+
22
+ ## Fixed
23
+
24
+ - **The 30s upstream deadline bounds the whole saferproducts.gov exchange**, not just the response headers — a response that stalls mid-body aborts with the same `Timeout` error rather than holding the request open indefinitely.
25
+ - **An over-budget upstream error body is captured from both ends**, so a CPSC diagnostic sitting behind a boilerplate preamble survives into `error.data.body` instead of being truncated away.
26
+ - **Input-validation failures read as flat `path: message` sentences** instead of a serialized `ZodIssue[]` blob, and a call to an unknown tool rejects with `-32602` rather than resolving an error result.
27
+ - **A failure after the handler returns is recorded as a failed call** — output-schema validation, `format()`, and the enrichment merge run inside the measured region, so they produce an ERROR span and an error counter rather than a success.
28
+ - **Stdin EOF runs the full shutdown path before exiting**, so a stdio server whose client hangs up no longer stays resident.
29
+
30
+ ## Dependencies
31
+
32
+ - `@cyanheads/mcp-ts-core` `^0.11.0` → `^0.12.3` (nine framework releases; `0.12.0` is the MCP SDK v2 adoption)
33
+ - `@biomejs/biome` `^2.5.5` → `^2.5.10`
34
+ - `@types/node` `^26.1.1` → `^26.2.0`
35
+ - `tsc-alias` `^1.9.1` → `^1.9.2`
36
+ - `vitest` `^4.1.10` → `^4.1.11`
37
+ - `packageManager` `bun@1.3.14` → `bun@1.4.0` (`engines.bun` stays `>=1.3.0`)
@@ -0,0 +1,32 @@
1
+ ---
2
+ summary: "Adopts mcp-ts-core 0.13.6 — the server declares a stateless session posture, cpsc_search_recalls accepts 'hazard' as an alias for hazard_search, and the Bun engine floor rises to 1.4.0, which breaks on older Bun runtimes."
3
+ breaking: true
4
+ security: false
5
+ ---
6
+
7
+ # 0.1.8 — 2026-09-19
8
+
9
+ ## Added
10
+
11
+ - **`cpsc_search_recalls` accepts `hazard` as an alias for `hazard_search`.** `Hazard` is the upstream CPSC query parameter a caller working from the saferproducts.gov docs reaches for; the alias is not advertised in `inputSchema`.
12
+
13
+ ## Changed
14
+
15
+ - **`engines.bun` rises from `>=1.3.0` to `>=1.4.0`.** A consumer running Bun 1.3.x can no longer run the server.
16
+ - **`createApp()` declares `sessionMode: 'stateless'`** in `src/index.ts` — no tool here gates on `ctx.requestInput`, so no caller needs a session to answer a mid-handler prompt. `MCP_SESSION_MODE` still overrides the declared posture whenever it carries a meaningful value.
17
+ - **`tools/list`'s advertised `outputSchema` changes on two error-contract details; `inputSchema` is byte-identical.** Nullable string fields now render as `type: ["string", "null"]` instead of `anyOf: [{type:"string"},{type:"null"}]` — a semantically-equal re-rendering from the `zod` bump below. Each error-contract `reason` description now ends its `when` sentence with a period, so declared reasons no longer run into each other (mcp-ts-core 0.13.5, [#389](https://github.com/cyanheads/mcp-ts-core/issues/389)).
18
+ - **Tests updated for the `InvalidParams` rename** — an out-of-schema argument key now rejects as `InvalidParams` (`-32602`) rather than `ValidationError` (mcp-ts-core 0.13.2, [#416](https://github.com/cyanheads/mcp-ts-core/issues/416)).
19
+ - Framework skills moved from `skills/` to `framework-skills/` — Claude Code and Codex auto-load a plugin's root `skills/`, so keeping development skills there would hand them to every installing agent. Adds the `release-pr-review` skill and resyncs `scripts/`, `changelog/template.md`, and `devcheck.config.json`'s `lint` key.
20
+ - README condensed — an Overview section, a tighter per-tool capability reference, and the Bun 1.4.0 floor.
21
+ - `.claude-plugin/plugin.json` gains keywords and author contact; issue templates route reports between this repo and `mcp-ts-core` and add a security-advisory contact link.
22
+ - Adds `.github/workflows/codeql.yml` — the repo's only GitHub Actions workflow.
23
+
24
+ ## Dependencies
25
+
26
+ - `@cyanheads/mcp-ts-core` `^0.12.3` → `^0.13.6` (13 framework releases)
27
+ - `zod` `^4.4.3` → `^4.6.5`
28
+ - `@biomejs/biome` `^2.5.10` → `^2.5.14`
29
+ - `@types/node` `^26.2.0` → `^26.6.1`
30
+ - `ignore` `^7.0.6` → `^7.0.9`
31
+ - `tsc-alias` `^1.9.2` → `^1.9.5`
32
+ - `vitest` `^4.1.11` → `^5.0.1`
@@ -4,10 +4,11 @@
4
4
  # to author a new release. Set that file's H1 to `# <version> — YYYY-MM-DD`
5
5
  # with a concrete date.
6
6
 
7
- # Required. One-line GitHub Release-style headline. 350 character cap.
8
- # Default short and scannable. Don't pad, don't stitch unrelated changes with
9
- # semicolons — pick the headline. Quotes required: unquoted YAML treats `: `
10
- # inside the value as a key separator and fails GitHub's strict parser.
7
+ # Required. One-line GitHub Release-style headline. 350 character cap — a
8
+ # ceiling, not a target. Default short and scannable. Don't pad, don't stitch
9
+ # unrelated changes with commas/semicolons into an inventory — pick the one
10
+ # headline the release is about. Quotes required: unquoted YAML treats
11
+ # `: ` inside the value as a key separator and fails GitHub's strict parser.
11
12
  summary: ""
12
13
 
13
14
  # Set `true` when consumers must change code to upgrade: API removals,
@@ -24,9 +25,10 @@ security: false
24
25
 
25
26
  # Optional free-form notes for maintenance agents processing this release.
26
27
  # Not rendered in CHANGELOG — consumed by agents running `maintenance` on
27
- # downstream servers. Use for adoption instructions that don't fit the
28
- # human-facing sections: new files to create, fields to populate, one-time
29
- # migration steps. Omit the field entirely when there's nothing to say.
28
+ # downstream servers. ADOPTION STEPS ONLY — new files to create, fields to
29
+ # populate, one-time migration steps. Never a second rendering of the body:
30
+ # if a body bullet already says it, name the bullet's symbol instead of
31
+ # re-explaining. Omit the field entirely when there's nothing to say.
30
32
  # agent-notes: |
31
33
  # <instructions for downstream maintenance agents>
32
34
  ---
@@ -41,17 +43,54 @@ security: false
41
43
  each bullet with the symbol or concept name in **bold** so they can skip
42
44
  what's irrelevant and zoom in on what's not.
43
45
 
44
- Tone: terse, fact-dense, not verbose. Default to one sentence per bullet —
45
- name the symbol, state what changed, stop. Use a second sentence only when
46
- it carries weight. If a bullet feels long, it is.
47
-
48
- Cut: mechanism walkthroughs (those belong in JSDoc, CLAUDE.md/AGENTS.md, or the
49
- relevant skill), ceremonial framings ("This release introduces…",
50
- backwards-compat paragraphs), file-by-file test enumerations, internal
51
- implementation notes. Prefer code/symbol names over English re-explanations.
46
+ Tone: terse, fact-dense, not verbose. Bullet shape: **symbol** + what
47
+ changed + at most one consumer-facing caveat. One sentence by default, two
48
+ when the second carries weight — a bullet past ~40 words or three sentences
49
+ is wrong. The depth lives one hop away: the linked issue carries the why,
50
+ the commit diff carries the how. The changelog names what changed and what
51
+ a consumer does about it; a reader who wants mechanism opens the link.
52
+
53
+ Model length on THIS guide, never on the previous entry — entries modeled
54
+ on entries compound.
55
+
56
+ Cut (each has shipped as a wall of text; these are the cruft):
57
+ - History/justification narration — how the bug worked, why the old
58
+ behavior was wrong. One short clause at most; the issue carries the story.
59
+ - Design-rationale defense — "chosen over Y because…", "guarding the
60
+ getter is not enough…". That is the author arguing with a reviewer;
61
+ reviewers read the PR, not the changelog.
62
+ - Defensive unchanged-clauses — "X is unchanged", "byte-identical to
63
+ <prev>". Keep one only where its absence would cause a real misread,
64
+ as a short parenthetical.
65
+ - Edge-case inventories — marker lists, not-flagged lists, escape tables.
66
+ Tests and the issue carry those.
67
+ - Mechanism walkthroughs (JSDoc, CLAUDE.md/AGENTS.md, or the relevant
68
+ skill own those), ceremonial framings ("This release introduces…"),
69
+ backwards-compat paragraphs, file-by-file test enumerations. Prefer
70
+ code/symbol names over English re-explanations.
71
+
72
+ Verified ≠ included: the every-claim-verified-from-the-diff rule bounds
73
+ the TRUTH of what you write, never the AMOUNT.
74
+
75
+ Example — same fact, right size:
76
+
77
+ TOO LONG: **`fetchWithTimeout`'s `timeoutMs` bounds the whole exchange**
78
+ (#341). `fetch` resolves once headers arrive and the deadline was
79
+ cleared as the helper returned, so a peer that answered promptly and
80
+ then stalled the stream held the request open indefinitely. A 2xx
81
+ carrying a body now comes back as a passthrough wrapper that disarms
82
+ the deadline when the body closes, errors, or is cancelled; …
83
+ [+90 more words of mechanism and edge cases]
84
+
85
+ RIGHT: **`fetchWithTimeout`'s `timeoutMs` now bounds the whole
86
+ exchange, not just the headers** (#341). A stalled body aborts with
87
+ the same `Timeout` error; the returned `Response` is a wrapper, so
88
+ identity assertions (`toBe(response)`) no longer hold.
52
89
 
53
90
  Narrative intro: skip by default. Add one short sentence only when the
54
- release theme genuinely needs framing the bullets can't carry.
91
+ release theme genuinely needs framing the bullets can't carry. When many
92
+ bullets share one upgrade consequence, state it ONCE — intro line or
93
+ agent-notes — never per bullet.
55
94
 
56
95
  Sections: Keep a Changelog order — Added, Changed, Deprecated, Removed,
57
96
  Fixed, Security. Include only sections with entries; delete the rest
@@ -78,30 +117,13 @@ security: false
78
117
  in that unrelated item's metadata.
79
118
 
80
119
  TAG ANNOTATIONS — the annotated tag body renders as the GitHub Release body
81
- via `gh release create --notes-from-tag`. The tag is a derivative of this
82
- changelog entry — a condensed, scannable version, not a copy. Format:
83
-
84
- <theme — omit version number, GitHub prepends it>
85
- ← blank line
86
- <1-2 sentence context: what this release does>
87
- ← blank line
88
- Dependency bumps: ← section header
89
- ← blank line
90
- - `@cyanheads/mcp-ts-core` ^0.9.1 → ^0.9.6 ← bullet
91
- ← blank line
92
- Changed: ← only sections with entries
93
- ← blank line
94
- - `format()` output includes `query` in text mode
95
- ← blank line
96
- Added:
97
- ← blank line
98
- - `manifest.json` scaffolded for MCPB bundle support
99
- - Install badges (Claude Desktop, Cursor, VS Code)
100
- ← blank line
101
- <N> tests pass; `bun run devcheck` clean. ← footer
102
-
103
- Never a flat comma-separated string. Always structured markdown with
104
- sections. The tag must scan well as a rendered GitHub Release page.
120
+ via `gh release create --notes-from-tag`. It is a condensed digest of this
121
+ entry, never a copy, and its format is owned by the `release-and-publish`
122
+ skill (step 4, "Create the annotated tag"): a short subject line without the
123
+ version, flat headline bullets — no Keep-a-Changelog section headers, no
124
+ gates line — at most one deps line, issue backlinks, and the changelog link
125
+ last. In release-PR mode the `git-wrapup` skill authors those bullets as the
126
+ PR body's `## Changes` and the tag copies them.
105
127
  -->
106
128
 
107
129
  ## Added
package/dist/index.js CHANGED
@@ -11,6 +11,12 @@ import { initCpscRecallService } from './services/cpsc-recall/cpsc-recall-servic
11
11
  await createApp({
12
12
  name: 'cpsc-recalls-mcp-server',
13
13
  title: 'cpsc-recalls-mcp-server',
14
+ /**
15
+ * Every tool is a single-shot read against the CPSC API — nothing gates on
16
+ * `ctx.requestInput`, so no caller needs a session to answer a mid-handler prompt.
17
+ * `MCP_SESSION_MODE` still overrides this at deploy time.
18
+ */
19
+ sessionMode: 'stateless',
14
20
  tools: [cpscSearchRecalls, cpscGetRecall, cpscGetRecent],
15
21
  resources: [],
16
22
  prompts: [],
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA;;;GAGG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,wDAAwD,CAAC;AACvF,OAAO,EAAE,aAAa,EAAE,MAAM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;CACF,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"cpsc-search-recalls.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/cpsc-search-recalls.tool.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAY,MAAM,+BAA+B,CAAC;AAe3E,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAme5B,CAAC"}
1
+ {"version":3,"file":"cpsc-search-recalls.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/cpsc-search-recalls.tool.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAY,MAAM,+BAA+B,CAAC;AAe3E,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cA0e5B,CAAC"}
@@ -26,6 +26,12 @@ export const cpscSearchRecalls = tool('cpsc_search_recalls', {
26
26
  'Page past limit with offset — total_found and has_more say where the window sits in the full result set. ' +
27
27
  'Use cpsc_get_recall with a recall_number from results to retrieve the full record including complete description, all images, and incident reports.',
28
28
  annotations: { readOnlyHint: true, idempotentHint: true },
29
+ /**
30
+ * `Hazard` is the upstream CPSC query parameter, so a caller working from the
31
+ * saferproducts.gov API docs reaches for that spelling. It maps one-to-one onto
32
+ * `hazard_search`, the working replacement for a parameter CPSC never matches.
33
+ */
34
+ inputAliases: { hazard: 'hazard_search' },
29
35
  input: z.object({
30
36
  product_name: z
31
37
  .string()
@@ -1 +1 @@
1
- {"version":3,"file":"cpsc-search-recalls.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/defin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K,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"cpsc-recall-service.d.ts","sourceRoot":"","sources":["../../../src/services/cpsc-recall/cpsc-recall-service.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAGtD,OAAO,KAAK,EAAE,gBAAgB,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAsB9D,qBAAa,iBAAiB;IAC5B;;;OAGG;IACH,MAAM,CAAC,MAAM,EAAE,gBAAgB,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,CAgBnE;IAED;;;OAGG;IACG,WAAW,CAAC,YAAY,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,SAAS,GAAG,IAAI,CAAC,CAI/E;IAED;;;OAGG;IACH,SAAS,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,CAGhF;IAED,OAAO,CAAC,QAAQ;IAQhB,OAAO,CAAC,YAAY;CAgDrB;AAMD,wBAAgB,qBAAqB,IAAI,IAAI,CAE5C;AAED,wBAAgB,oBAAoB,IAAI,iBAAiB,CAKxD"}
1
+ {"version":3,"file":"cpsc-recall-service.d.ts","sourceRoot":"","sources":["../../../src/services/cpsc-recall/cpsc-recall-service.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAGtD,OAAO,KAAK,EAAE,gBAAgB,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAsB9D,qBAAa,iBAAiB;IAC5B;;;OAGG;IACH,MAAM,CAAC,MAAM,EAAE,gBAAgB,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,CAgBnE;IAED;;;OAGG;IACG,WAAW,CAAC,YAAY,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,SAAS,GAAG,IAAI,CAAC,CAI/E;IAED;;;OAGG;IACH,SAAS,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,CAGhF;IAED,OAAO,CAAC,QAAQ;IAQhB,OAAO,CAAC,YAAY;CA4CrB;AAMD,wBAAgB,qBAAqB,IAAI,IAAI,CAE5C;AAED,wBAAgB,oBAAoB,IAAI,iBAAiB,CAKxD"}
@@ -4,7 +4,7 @@
4
4
  * @module services/cpsc-recall/cpsc-recall-service
5
5
  */
6
6
  import { serviceUnavailable } from '@cyanheads/mcp-ts-core/errors';
7
- import { fetchWithTimeout, requestContextService, withRetry } from '@cyanheads/mcp-ts-core/utils';
7
+ import { fetchWithTimeout, withRetry } from '@cyanheads/mcp-ts-core/utils';
8
8
  const BASE_URL = 'https://www.saferproducts.gov/RestWebServices/Recall';
9
9
  /** Request timeout: 30 s. The API returns full datasets; allow enough time. */
10
10
  const TIMEOUT_MS = 30_000;
@@ -72,12 +72,8 @@ export class CpscRecallService {
72
72
  return `${BASE_URL}?${qs.toString()}`;
73
73
  }
74
74
  fetchRecalls(url, ctx) {
75
- const reqCtx = requestContextService.createRequestContext({
76
- operation: 'CpscRecallService.fetchRecalls',
77
- requestId: ctx.requestId,
78
- });
79
75
  return withRetry(async () => {
80
- const response = await fetchWithTimeout(url, TIMEOUT_MS, reqCtx, {
76
+ const response = await fetchWithTimeout(url, TIMEOUT_MS, ctx, {
81
77
  signal: ctx.signal,
82
78
  });
83
79
  const text = await response.text();
@@ -108,7 +104,7 @@ export class CpscRecallService {
108
104
  return data;
109
105
  }, {
110
106
  operation: 'CpscRecallService.fetchRecalls',
111
- context: reqCtx,
107
+ context: ctx,
112
108
  baseDelayMs: 500,
113
109
  signal: ctx.signal,
114
110
  });
@@ -1 +1 @@
1
- {"version":3,"file":"cpsc-recall-service.js","sourceRoot":"","sources":["../../../src/services/cpsc-recall/cpsc-recall-service.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAGlG,MAAM,QAAQ,GAAG,sDAAsD,CAAC;AACxE,+EAA+E;AAC/E,MAAM,UAAU,GAAG,MAAM,CAAC;AAC1B,+FAA+F;AAC/F,MAAM,uBAAuB,GAAG,GAAG,CAAC;AAEpC;;;;;;;GAOG;AACH,SAAS,cAAc,CAAC,GAAY;IAClC,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,KAAK,IAAI;QAAE,OAAO,IAAI,CAAC;IACzD,MAAM,CAAC,GAAG,GAAyB,CAAC;IACpC,OAAO,CAAC,CAAC,YAAY,IAAI,IAAI,IAAI,CAAC,CAAC,UAAU,IAAI,IAAI,IAAI,CAAC,CAAC,KAAK,IAAI,IAAI,CAAC;AAC3E,CAAC;AAED,MAAM,OAAO,iBAAiB;IAC5B;;;OAGG;IACH,MAAM,CAAC,MAAwB,EAAE,GAAY;QAC3C,MAAM,GAAG,GAAG,IAAI,CAAC,QAAQ,CAAC;YACxB,WAAW,EAAE,MAAM,CAAC,WAAW;YAC/B,YAAY,EAAE,MAAM,CAAC,YAAY;YACjC,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,WAAW,EAAE,MAAM,CAAC,WAAW;YAC/B,WAAW,EAAE,MAAM,CAAC,WAAW;YAC/B,iBAAiB,EAAE,MAAM,CAAC,iBAAiB;YAC3C,MAAM,EAAE,MAAM,CAAC,MAAM;YACrB,eAAe,EAAE,MAAM,CAAC,eAAe;YACvC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AAS,EAAE,CAAC;gBAC3B,MAAM,eAAe,GAAI,QAA+B,EAAE,KAAK,CAAC;gBAChE,MAAM,kBAAkB,CACtB,0DAA0D;oBACxD,CAAC,OAAO,eAAe,KAAK,QAAQ,IAAI,eAAe,CAAC,MAAM,GAAG,CAAC;wBAChE,CAAC,CAAC,KAAK,eAAe,CAAC,KAAK,CAAC,CAAC,EAAE,uBAAuB,CAAC,EAAE;wBAC1D,CAAC,CAAC,GAAG,CAAC;gBACV,iFAAiF;gBACjF,EAAE,SAAS,EAAE,KAAK,EAAE,CACrB,CAAC;YACJ,CAAC;YACD,OAAO,IAAmB,CAAC;QAC7B,CAAC,EACD;YACE,SAAS,EAAE,gCAAgC;YAC3C,OAAO,EAAE,GAAG;YACZ,WAAW,EAAE,GAAG;YAChB,MAAM,EAAE,GAAG,CAAC,MAAM;SACnB,CACF,CAAC;IACJ,CAAC;CACF;AAED,gCAAgC;AAEhC,IAAI,QAAuC,CAAC;AAE5C,MAAM,UAAU,qBAAqB;IACnC,QAAQ,GAAG,IAAI,iBAAiB,EAAE,CAAC;AACrC,CAAC;AAED,MAAM,UAAU,oBAAoB;IAClC,IAAI,CAAC,QAAQ,EAAE,CAAC;QACd,MAAM,IAAI,KAAK,CAAC,6EAA6E,CAAC,CAAC;IACjG,CAAC;IACD,OAAO,QAAQ,CAAC;AAClB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cyanheads/cpsc-recalls-mcp-server",
3
- "version": "0.1.6",
3
+ "version": "0.1.8",
4
4
  "mcpName": "io.github.cyanheads/cpsc-recalls-mcp-server",
5
5
  "description": "Search and retrieve US consumer product recalls from the CPSC (Consumer Product Safety Commission) via MCP. STDIO or Streamable HTTP.",
6
6
  "type": "module",
@@ -24,6 +24,7 @@
24
24
  "rebuild": "bun run scripts/clean.ts && bun run scripts/build.ts",
25
25
  "clean": "bun run scripts/clean.ts",
26
26
  "devcheck": "bun run scripts/devcheck.ts",
27
+ "audit:fix": "bun audit fix",
27
28
  "audit:refresh": "rm -f bun.lock && bun install && bun audit",
28
29
  "tree": "bun run scripts/tree.ts",
29
30
  "list-skills": "bun run scripts/list-skills.ts",
@@ -76,27 +77,27 @@
76
77
  }
77
78
  ],
78
79
  "license": "Apache-2.0",
79
- "packageManager": "bun@1.3.14",
80
+ "packageManager": "bun@1.4.0",
80
81
  "engines": {
81
- "bun": ">=1.3.0",
82
+ "bun": ">=1.4.0",
82
83
  "node": ">=24.0.0"
83
84
  },
84
85
  "publishConfig": {
85
86
  "access": "public"
86
87
  },
87
88
  "dependencies": {
88
- "@cyanheads/mcp-ts-core": "^0.11.0",
89
+ "@cyanheads/mcp-ts-core": "^0.13.6",
89
90
  "pino-pretty": "^13.1.3",
90
- "zod": "^4.4.3"
91
+ "zod": "^4.6.5"
91
92
  },
92
93
  "devDependencies": {
93
- "@biomejs/biome": "^2.5.5",
94
+ "@biomejs/biome": "^2.5.14",
94
95
  "@socketsecurity/bun-security-scanner": "^1.1.2",
95
- "@types/node": "^26.1.1",
96
+ "@types/node": "^26.6.1",
96
97
  "depcheck": "^1.4.7",
97
- "ignore": "^7.0.6",
98
- "tsc-alias": "^1.9.1",
98
+ "ignore": "^7.0.9",
99
+ "tsc-alias": "^1.9.5",
99
100
  "typescript": "^7.0.2",
100
- "vitest": "^4.1.10"
101
+ "vitest": "^5.0.1"
101
102
  }
102
103
  }
package/server.json CHANGED
@@ -6,7 +6,7 @@
6
6
  "url": "https://github.com/cyanheads/cpsc-recalls-mcp-server",
7
7
  "source": "github"
8
8
  },
9
- "version": "0.1.6",
9
+ "version": "0.1.8",
10
10
  "remotes": [
11
11
  {
12
12
  "type": "streamable-http",
@@ -19,7 +19,7 @@
19
19
  "registryBaseUrl": "https://registry.npmjs.org",
20
20
  "identifier": "@cyanheads/cpsc-recalls-mcp-server",
21
21
  "runtimeHint": "bun",
22
- "version": "0.1.6",
22
+ "version": "0.1.8",
23
23
  "packageArguments": [
24
24
  {
25
25
  "type": "positional",
@@ -48,7 +48,7 @@
48
48
  "registryBaseUrl": "https://registry.npmjs.org",
49
49
  "identifier": "@cyanheads/cpsc-recalls-mcp-server",
50
50
  "runtimeHint": "bun",
51
- "version": "0.1.6",
51
+ "version": "0.1.8",
52
52
  "packageArguments": [
53
53
  {
54
54
  "type": "positional",