@cyanheads/seerr-mcp-server 0.1.3 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/AGENTS.md +40 -23
  2. package/CLAUDE.md +40 -23
  3. package/Dockerfile +4 -1
  4. package/README.md +50 -55
  5. package/changelog/0.1.x/0.1.4.md +34 -0
  6. package/changelog/template.md +9 -26
  7. package/dist/index.d.ts +3 -0
  8. package/dist/index.d.ts.map +1 -1
  9. package/dist/index.js +10 -0
  10. package/dist/index.js.map +1 -1
  11. package/dist/mcp-server/resources/definitions/index.d.ts +1 -0
  12. package/dist/mcp-server/resources/definitions/index.d.ts.map +1 -1
  13. package/dist/mcp-server/resources/definitions/request.resource.d.ts +2 -0
  14. package/dist/mcp-server/resources/definitions/request.resource.d.ts.map +1 -1
  15. package/dist/mcp-server/resources/definitions/request.resource.js +2 -0
  16. package/dist/mcp-server/resources/definitions/request.resource.js.map +1 -1
  17. package/dist/mcp-server/tools/definitions/get-media.tool.d.ts +2 -0
  18. package/dist/mcp-server/tools/definitions/get-media.tool.d.ts.map +1 -1
  19. package/dist/mcp-server/tools/definitions/get-media.tool.js +2 -0
  20. package/dist/mcp-server/tools/definitions/get-media.tool.js.map +1 -1
  21. package/dist/mcp-server/tools/definitions/index.d.ts +3 -0
  22. package/dist/mcp-server/tools/definitions/index.d.ts.map +1 -1
  23. package/dist/mcp-server/tools/definitions/request-media.tool.d.ts +2 -0
  24. package/dist/mcp-server/tools/definitions/request-media.tool.d.ts.map +1 -1
  25. package/dist/mcp-server/tools/definitions/request-media.tool.js +2 -0
  26. package/dist/mcp-server/tools/definitions/request-media.tool.js.map +1 -1
  27. package/dist/mcp-server/tools/definitions/request-status.tool.d.ts +2 -0
  28. package/dist/mcp-server/tools/definitions/request-status.tool.d.ts.map +1 -1
  29. package/dist/mcp-server/tools/definitions/request-status.tool.js +2 -0
  30. package/dist/mcp-server/tools/definitions/request-status.tool.js.map +1 -1
  31. package/package.json +20 -9
  32. package/server.json +3 -3
package/AGENTS.md CHANGED
@@ -1,11 +1,11 @@
1
1
  # Developer Protocol
2
2
 
3
3
  **Server:** seerr-mcp-server
4
- **Version:** 0.1.3
5
- **Framework:** [@cyanheads/mcp-ts-core](https://www.npmjs.com/package/@cyanheads/mcp-ts-core) `^0.12.3`
6
- **Engines:** Bun ≥1.3.0, Node ≥24.0.0
4
+ **Version:** 0.1.4
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
7
  **MCP SDK:** `@modelcontextprotocol/server` ^2.0.0
8
- **Zod:** ^4.4.3
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
 
@@ -19,7 +19,7 @@ A workflow MCP server over a self-hosted Jellyseerr/Overseerr instance: **search
19
19
 
20
20
  **Two invariants that must never regress:**
21
21
 
22
- 1. **Guarded write.** `seerr_request_media` is the only mutation. It defaults to `mode: preview` (resolve + validate, no POST); the real write fires only on `mode: request` and only once the handler is re-entered with a schema-valid acceptance on `ctx.inputs`, with `destructiveHint: true` surfacing the risk in client-side approval flows. There is no branch that proceeds without an acceptance — a client that never answers leaves the write un-run. Capability validation (4K/seasons/partial) runs locally against cached settings before any POST. `MCP_SESSION_MODE` must resolve to `stateful`: the round trip needs a live session for 2025-era clients, and `stateless` refuses it.
22
+ 1. **Guarded write.** `seerr_request_media` is the only mutation. It defaults to `mode: preview` (resolve + validate, no POST); the real write fires only on `mode: request` and only once the handler is re-entered with a schema-valid acceptance on `ctx.inputs`, with `destructiveHint: true` surfacing the risk in client-side approval flows. There is no branch that proceeds without an acceptance — a client that never answers leaves the write un-run. Capability validation (4K/seasons/partial) runs locally against cached settings before any POST. The session mode must resolve to `stateful`: the round trip needs a live session for 2025-era clients, and `stateless` refuses it. `src/index.ts` declares `sessionMode: { default: 'stateful', require: 'stateful' }`, so a `stateless` HTTP deployment fails startup with a `ConfigurationError` instead of degrading the tool; stdio is never refused.
23
23
  2. **PII/infra redaction.** Every raw Jellyseerr payload is projected through `src/services/seerr/normalizers.ts` — the single choke point — before output. It allow-lists fields: `User` → `{ id, displayName }`, and drops operator email, Plex/Jellyfin tokens, `serviceUrl`, `vapidPublic`, and filesystem paths (gated behind `includePaths`). The base URL and API key live only in config and never appear in output. Redaction lives in normalizers, not `format()`, so both `structuredContent` and `content[]` are clean. `ctx.log` is a third output surface — it is dual-sink as of mcp-ts-core 0.12.0, mirroring every call to the client as `notifications/message` — so log only classified reasons and the caller's own inputs, never a raw upstream or network message.
24
24
 
25
25
  The authoritative tool surface, live API quirks, and status-decoding tables are in [`docs/design.md`](docs/design.md).
@@ -158,6 +158,7 @@ await createApp({
158
158
  title: 'seerr-mcp-server',
159
159
  tools: allToolDefinitions,
160
160
  resources: allResourceDefinitions,
161
+ sessionMode: { default: 'stateful', require: 'stateful' },
161
162
  instructions:
162
163
  'Local Seerr request workflow. Search first (seerr_search_media), confirm the exact title ' +
163
164
  '(seerr_get_media), then request via seerr_request_media — which defaults to mode:preview and ' +
@@ -170,6 +171,12 @@ await createApp({
170
171
 
171
172
  `instructions` is optional server-level orientation, sent on every `initialize` as session-level context. Use it for deployment guidance instead of repeating the same context across tool descriptions. Client adoption is uneven, but there's no downside when set.
172
173
 
174
+ ### Session posture and shutdown
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). `require: 'stateful'` is set here because `seerr_request_media` asks the caller for input mid-handler via `ctx.requestInput`: startup 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. This server declares none: `SeerrService` holds only config strings and issues per-call `fetch`es, and the settings cache lives in `ctx.state`, which the framework disposes.
179
+
173
180
  ---
174
181
 
175
182
  ## Context
@@ -195,7 +202,7 @@ Handlers receive a unified `ctx` object. Key properties:
195
202
 
196
203
  Handlers throw — the framework catches, classifies, and formats.
197
204
 
198
- **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 descriptive metadata for the agent's next move ( 5 words, lint-validated); for the wire `data.recovery.hint` (mirrored into `content[]` text), pass explicitly at the throw site when dynamic context matters: `ctx.fail('reason', msg, { recovery: { hint: '...' } })`. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`) bubble freely and don't need declaring.
205
+ **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. Spread `ctx.recoveryFor('reason')` into 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 — this server's `media_not_found` / `request_not_found` entries are all raised by the `services/seerr/errors.ts` classifier and carry the marker. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`, `RequestCancelled`) bubble freely and don't need declaring.
199
206
 
200
207
  ```ts
201
208
  import { JsonRpcErrorCode } from '@cyanheads/mcp-ts-core/errors';
@@ -207,7 +214,7 @@ errors: [
207
214
  ],
208
215
  async handler(input, ctx) {
209
216
  const item = await db.find(input.id);
210
- if (!item) throw ctx.fail('no_match', `No item ${input.id}`);
217
+ if (!item) throw ctx.fail('no_match', `No item ${input.id}`, { ...ctx.recoveryFor('no_match') });
211
218
  return item;
212
219
  }
213
220
  ```
@@ -270,9 +277,9 @@ src/
270
277
 
271
278
  ## Skills
272
279
 
273
- 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.
280
+ 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.
274
281
 
275
- **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.
282
+ **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.
276
283
 
277
284
  Available skills:
278
285
 
@@ -292,8 +299,9 @@ Available skills:
292
299
  | `security-pass` | Audit server for MCP-flavored security gaps: output injection, scope blast radius, input sinks, tenant isolation |
293
300
  | `code-simplifier` | Post-session cleanup against `git diff` — modernize syntax, consolidate duplication, align with the codebase |
294
301
  | `polish-docs-meta` | Finalize docs, README, metadata, and agent protocol for shipping |
295
- | `git-wrapup` | Land working-tree changes as a versioned commit + annotated tag — version bump, changelog, verify, tag. Local only. |
296
- | `release-and-publish` | Push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
302
+ | `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 |
303
+ | `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 |
304
+ | `release-and-publish` | Fast-forward merge (release PR mode) + tag + push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
297
305
  | `maintenance` | Investigate changelogs, adopt upstream changes, sync skills to agent dirs |
298
306
  | `orchestrations` | Chain task skills into a gated multi-phase pipeline — build-out, QA-fix, update-ship — when you can spawn sub-agents |
299
307
  | `report-issue-framework` | File a bug or feature request against `@cyanheads/mcp-ts-core` via `gh` CLI |
@@ -301,7 +309,7 @@ Available skills:
301
309
  | `api-auth` | Auth modes, scopes, JWT/OAuth |
302
310
  | `api-canvas` | DataCanvas: register tabular data, run SQL, export, plus the `spillover()` helper for big result sets — Tier 3 opt-in |
303
311
  | `api-config` | AppConfig, parseConfig, env vars |
304
- | `api-context` | Context interface, logger, state, progress |
312
+ | `api-context` | Context interface, RequestContext, logger, state, multi-round-trip input |
305
313
  | `api-errors` | McpError, JsonRpcErrorCode, error patterns |
306
314
  | `api-linter` | Definition linter rule catalog — invoked by `bun run lint:mcp` and `devcheck` |
307
315
  | `api-mirror` | MirrorService — persistent self-refreshing local mirror of a bulk upstream dataset (not used by this server) |
@@ -311,7 +319,7 @@ Available skills:
311
319
  | `api-telemetry` | OTel catalog: spans, metrics, completion logs, env config, cardinality rules |
312
320
  | `api-workers` | Cloudflare Workers runtime |
313
321
 
314
- **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 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.
322
+ **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.
315
323
 
316
324
  When you complete a skill's checklist, check the boxes and add a completion timestamp at the end (e.g., `Completed: 2026-03-11`).
317
325
 
@@ -327,7 +335,8 @@ When you complete a skill's checklist, check the boxes and add a completion time
327
335
  | `bun run rebuild` | Clean + build |
328
336
  | `bun run clean` | Remove build artifacts |
329
337
  | `bun run devcheck` | Lint + format + typecheck + security + changelog sync |
330
- | `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. |
338
+ | `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` |
339
+ | `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` |
331
340
  | `bun run lint:mcp` | Run the MCP definition linter standalone (rule catalog: `api-linter` skill) |
332
341
  | `bun run lint:packaging` | Packaging surface checks — `server.json`/`manifest.json` env-var parity (run by devcheck) |
333
342
  | `bun run list-skills` | Print the skill registry |
@@ -341,15 +350,17 @@ When you complete a skill's checklist, check the boxes and add a completion time
341
350
  | `bun run changelog:check` | Verify `CHANGELOG.md` is in sync (used by devcheck) |
342
351
  | `bun run bundle` | Build, pack, and clean a `.mcpb` for one-click Claude Desktop install |
343
352
 
353
+ **CI is one file.** `.github/workflows/codeql.yml` 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.
354
+
344
355
  ---
345
356
 
346
357
  ## Bundling
347
358
 
348
- `npm 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 dependency-shipped agent docs (`node_modules/**` `skills/`, `.claude/`, `.agents/`, `SKILL.md`) that root-anchored `.mcpbignore` patterns cannot reach. 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.
359
+ `npm 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.
349
360
 
350
- **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.
361
+ **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": ""`.
351
362
 
352
- **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`.
363
+ **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`.
353
364
 
354
365
  ---
355
366
 
@@ -363,23 +374,29 @@ Each per-version file opens with YAML frontmatter:
363
374
  ---
364
375
  summary: "One-line headline, ≤350 chars" # required — powers the rollup index
365
376
  breaking: false # optional — true flags breaking changes
366
- security: false # optional — true flags security fixes
377
+ security: false # optional — true ONLY for a source-code security fix, never a dependency CVE bump
367
378
  ---
368
379
 
369
380
  # 0.1.0 — YYYY-MM-DD
370
381
  ...
371
382
  ```
372
383
 
373
- `breaking: true` renders a `· ⚠️ Breaking` badge — use it when consumers must update code on upgrade (signature changes, removed APIs, config renames). `security: true` renders a `· 🛡️ Security` badge and pairs with a `## Security` body section. When both are set, badges render `· ⚠️ Breaking · 🛡️ Security`.
384
+ `breaking: true` renders a `· ⚠️ Breaking` badge — use it when consumers must update code on upgrade (signature changes, removed APIs, config renames). `security: true` renders a `· 🛡️ Security` badge and pairs with a `## Security` body section — set it only for a security fix in this server's *own source code*, never for a routine dependency or transitive CVE bump (record those under `## Dependencies`). When both are set, badges render `· ⚠️ Breaking · 🛡️ Security`.
374
385
 
375
386
  `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.
376
387
 
377
- **Section order** (Keep a Changelog): Added, Changed, Deprecated, Removed, Fixed, Security. Include only sections with entries — don't ship empty headers.
388
+ **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.
378
389
 
379
390
  **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.
380
391
 
381
392
  ---
382
393
 
394
+ ## Publishing
395
+
396
+ **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.
397
+
398
+ ---
399
+
383
400
  ## Imports
384
401
 
385
402
  ```ts
@@ -406,7 +423,7 @@ import { getMyService } from '@/services/my-domain/my-service.js';
406
423
  - [ ] If wrapping external API: tests include at least one sparse payload case with omitted upstream fields
407
424
  - [ ] Registered in `createApp()` arrays (directly or via barrel exports)
408
425
  - [ ] Tests use `createMockContext()` from `@cyanheads/mcp-ts-core/testing`
409
- - [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = package name; `interface.shortDescription` from `package.json` description
410
- - [ ] `.codex-plugin/mcp.json` updated — server name key matches `package.json` name; env vars added for any required API keys
411
- - [ ] `.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
426
+ - [ ] `.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
427
+ - [ ] `.codex-plugin/mcp.json` updated — server name key is the unscoped repo name; every user-supplied variable (API key, 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
428
+ - [ ] `.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`
412
429
  - [ ] `npm run devcheck` passes
package/CLAUDE.md CHANGED
@@ -1,11 +1,11 @@
1
1
  # Developer Protocol
2
2
 
3
3
  **Server:** seerr-mcp-server
4
- **Version:** 0.1.3
5
- **Framework:** [@cyanheads/mcp-ts-core](https://www.npmjs.com/package/@cyanheads/mcp-ts-core) `^0.12.3`
6
- **Engines:** Bun ≥1.3.0, Node ≥24.0.0
4
+ **Version:** 0.1.4
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
7
  **MCP SDK:** `@modelcontextprotocol/server` ^2.0.0
8
- **Zod:** ^4.4.3
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
 
@@ -19,7 +19,7 @@ A workflow MCP server over a self-hosted Jellyseerr/Overseerr instance: **search
19
19
 
20
20
  **Two invariants that must never regress:**
21
21
 
22
- 1. **Guarded write.** `seerr_request_media` is the only mutation. It defaults to `mode: preview` (resolve + validate, no POST); the real write fires only on `mode: request` and only once the handler is re-entered with a schema-valid acceptance on `ctx.inputs`, with `destructiveHint: true` surfacing the risk in client-side approval flows. There is no branch that proceeds without an acceptance — a client that never answers leaves the write un-run. Capability validation (4K/seasons/partial) runs locally against cached settings before any POST. `MCP_SESSION_MODE` must resolve to `stateful`: the round trip needs a live session for 2025-era clients, and `stateless` refuses it.
22
+ 1. **Guarded write.** `seerr_request_media` is the only mutation. It defaults to `mode: preview` (resolve + validate, no POST); the real write fires only on `mode: request` and only once the handler is re-entered with a schema-valid acceptance on `ctx.inputs`, with `destructiveHint: true` surfacing the risk in client-side approval flows. There is no branch that proceeds without an acceptance — a client that never answers leaves the write un-run. Capability validation (4K/seasons/partial) runs locally against cached settings before any POST. The session mode must resolve to `stateful`: the round trip needs a live session for 2025-era clients, and `stateless` refuses it. `src/index.ts` declares `sessionMode: { default: 'stateful', require: 'stateful' }`, so a `stateless` HTTP deployment fails startup with a `ConfigurationError` instead of degrading the tool; stdio is never refused.
23
23
  2. **PII/infra redaction.** Every raw Jellyseerr payload is projected through `src/services/seerr/normalizers.ts` — the single choke point — before output. It allow-lists fields: `User` → `{ id, displayName }`, and drops operator email, Plex/Jellyfin tokens, `serviceUrl`, `vapidPublic`, and filesystem paths (gated behind `includePaths`). The base URL and API key live only in config and never appear in output. Redaction lives in normalizers, not `format()`, so both `structuredContent` and `content[]` are clean. `ctx.log` is a third output surface — it is dual-sink as of mcp-ts-core 0.12.0, mirroring every call to the client as `notifications/message` — so log only classified reasons and the caller's own inputs, never a raw upstream or network message.
24
24
 
25
25
  The authoritative tool surface, live API quirks, and status-decoding tables are in [`docs/design.md`](docs/design.md).
@@ -158,6 +158,7 @@ await createApp({
158
158
  title: 'seerr-mcp-server',
159
159
  tools: allToolDefinitions,
160
160
  resources: allResourceDefinitions,
161
+ sessionMode: { default: 'stateful', require: 'stateful' },
161
162
  instructions:
162
163
  'Local Seerr request workflow. Search first (seerr_search_media), confirm the exact title ' +
163
164
  '(seerr_get_media), then request via seerr_request_media — which defaults to mode:preview and ' +
@@ -170,6 +171,12 @@ await createApp({
170
171
 
171
172
  `instructions` is optional server-level orientation, sent on every `initialize` as session-level context. Use it for deployment guidance instead of repeating the same context across tool descriptions. Client adoption is uneven, but there's no downside when set.
172
173
 
174
+ ### Session posture and shutdown
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). `require: 'stateful'` is set here because `seerr_request_media` asks the caller for input mid-handler via `ctx.requestInput`: startup 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. This server declares none: `SeerrService` holds only config strings and issues per-call `fetch`es, and the settings cache lives in `ctx.state`, which the framework disposes.
179
+
173
180
  ---
174
181
 
175
182
  ## Context
@@ -195,7 +202,7 @@ Handlers receive a unified `ctx` object. Key properties:
195
202
 
196
203
  Handlers throw — the framework catches, classifies, and formats.
197
204
 
198
- **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 descriptive metadata for the agent's next move ( 5 words, lint-validated); for the wire `data.recovery.hint` (mirrored into `content[]` text), pass explicitly at the throw site when dynamic context matters: `ctx.fail('reason', msg, { recovery: { hint: '...' } })`. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`) bubble freely and don't need declaring.
205
+ **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. Spread `ctx.recoveryFor('reason')` into 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 — this server's `media_not_found` / `request_not_found` entries are all raised by the `services/seerr/errors.ts` classifier and carry the marker. Baseline codes (`InternalError`, `ServiceUnavailable`, `Timeout`, `ValidationError`, `SerializationError`, `RequestCancelled`) bubble freely and don't need declaring.
199
206
 
200
207
  ```ts
201
208
  import { JsonRpcErrorCode } from '@cyanheads/mcp-ts-core/errors';
@@ -207,7 +214,7 @@ errors: [
207
214
  ],
208
215
  async handler(input, ctx) {
209
216
  const item = await db.find(input.id);
210
- if (!item) throw ctx.fail('no_match', `No item ${input.id}`);
217
+ if (!item) throw ctx.fail('no_match', `No item ${input.id}`, { ...ctx.recoveryFor('no_match') });
211
218
  return item;
212
219
  }
213
220
  ```
@@ -270,9 +277,9 @@ src/
270
277
 
271
278
  ## Skills
272
279
 
273
- 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.
280
+ 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.
274
281
 
275
- **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.
282
+ **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.
276
283
 
277
284
  Available skills:
278
285
 
@@ -292,8 +299,9 @@ Available skills:
292
299
  | `security-pass` | Audit server for MCP-flavored security gaps: output injection, scope blast radius, input sinks, tenant isolation |
293
300
  | `code-simplifier` | Post-session cleanup against `git diff` — modernize syntax, consolidate duplication, align with the codebase |
294
301
  | `polish-docs-meta` | Finalize docs, README, metadata, and agent protocol for shipping |
295
- | `git-wrapup` | Land working-tree changes as a versioned commit + annotated tag — version bump, changelog, verify, tag. Local only. |
296
- | `release-and-publish` | Push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
302
+ | `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 |
303
+ | `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 |
304
+ | `release-and-publish` | Fast-forward merge (release PR mode) + tag + push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
297
305
  | `maintenance` | Investigate changelogs, adopt upstream changes, sync skills to agent dirs |
298
306
  | `orchestrations` | Chain task skills into a gated multi-phase pipeline — build-out, QA-fix, update-ship — when you can spawn sub-agents |
299
307
  | `report-issue-framework` | File a bug or feature request against `@cyanheads/mcp-ts-core` via `gh` CLI |
@@ -301,7 +309,7 @@ Available skills:
301
309
  | `api-auth` | Auth modes, scopes, JWT/OAuth |
302
310
  | `api-canvas` | DataCanvas: register tabular data, run SQL, export, plus the `spillover()` helper for big result sets — Tier 3 opt-in |
303
311
  | `api-config` | AppConfig, parseConfig, env vars |
304
- | `api-context` | Context interface, logger, state, progress |
312
+ | `api-context` | Context interface, RequestContext, logger, state, multi-round-trip input |
305
313
  | `api-errors` | McpError, JsonRpcErrorCode, error patterns |
306
314
  | `api-linter` | Definition linter rule catalog — invoked by `bun run lint:mcp` and `devcheck` |
307
315
  | `api-mirror` | MirrorService — persistent self-refreshing local mirror of a bulk upstream dataset (not used by this server) |
@@ -311,7 +319,7 @@ Available skills:
311
319
  | `api-telemetry` | OTel catalog: spans, metrics, completion logs, env config, cardinality rules |
312
320
  | `api-workers` | Cloudflare Workers runtime |
313
321
 
314
- **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 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.
322
+ **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.
315
323
 
316
324
  When you complete a skill's checklist, check the boxes and add a completion timestamp at the end (e.g., `Completed: 2026-03-11`).
317
325
 
@@ -327,7 +335,8 @@ When you complete a skill's checklist, check the boxes and add a completion time
327
335
  | `bun run rebuild` | Clean + build |
328
336
  | `bun run clean` | Remove build artifacts |
329
337
  | `bun run devcheck` | Lint + format + typecheck + security + changelog sync |
330
- | `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. |
338
+ | `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` |
339
+ | `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` |
331
340
  | `bun run lint:mcp` | Run the MCP definition linter standalone (rule catalog: `api-linter` skill) |
332
341
  | `bun run lint:packaging` | Packaging surface checks — `server.json`/`manifest.json` env-var parity (run by devcheck) |
333
342
  | `bun run list-skills` | Print the skill registry |
@@ -341,15 +350,17 @@ When you complete a skill's checklist, check the boxes and add a completion time
341
350
  | `bun run changelog:check` | Verify `CHANGELOG.md` is in sync (used by devcheck) |
342
351
  | `bun run bundle` | Build, pack, and clean a `.mcpb` for one-click Claude Desktop install |
343
352
 
353
+ **CI is one file.** `.github/workflows/codeql.yml` 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.
354
+
344
355
  ---
345
356
 
346
357
  ## Bundling
347
358
 
348
- `npm 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 dependency-shipped agent docs (`node_modules/**` `skills/`, `.claude/`, `.agents/`, `SKILL.md`) that root-anchored `.mcpbignore` patterns cannot reach. 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.
359
+ `npm 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.
349
360
 
350
- **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.
361
+ **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": ""`.
351
362
 
352
- **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`.
363
+ **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`.
353
364
 
354
365
  ---
355
366
 
@@ -363,23 +374,29 @@ Each per-version file opens with YAML frontmatter:
363
374
  ---
364
375
  summary: "One-line headline, ≤350 chars" # required — powers the rollup index
365
376
  breaking: false # optional — true flags breaking changes
366
- security: false # optional — true flags security fixes
377
+ security: false # optional — true ONLY for a source-code security fix, never a dependency CVE bump
367
378
  ---
368
379
 
369
380
  # 0.1.0 — YYYY-MM-DD
370
381
  ...
371
382
  ```
372
383
 
373
- `breaking: true` renders a `· ⚠️ Breaking` badge — use it when consumers must update code on upgrade (signature changes, removed APIs, config renames). `security: true` renders a `· 🛡️ Security` badge and pairs with a `## Security` body section. When both are set, badges render `· ⚠️ Breaking · 🛡️ Security`.
384
+ `breaking: true` renders a `· ⚠️ Breaking` badge — use it when consumers must update code on upgrade (signature changes, removed APIs, config renames). `security: true` renders a `· 🛡️ Security` badge and pairs with a `## Security` body section — set it only for a security fix in this server's *own source code*, never for a routine dependency or transitive CVE bump (record those under `## Dependencies`). When both are set, badges render `· ⚠️ Breaking · 🛡️ Security`.
374
385
 
375
386
  `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.
376
387
 
377
- **Section order** (Keep a Changelog): Added, Changed, Deprecated, Removed, Fixed, Security. Include only sections with entries — don't ship empty headers.
388
+ **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.
378
389
 
379
390
  **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.
380
391
 
381
392
  ---
382
393
 
394
+ ## Publishing
395
+
396
+ **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.
397
+
398
+ ---
399
+
383
400
  ## Imports
384
401
 
385
402
  ```ts
@@ -406,7 +423,7 @@ import { getMyService } from '@/services/my-domain/my-service.js';
406
423
  - [ ] If wrapping external API: tests include at least one sparse payload case with omitted upstream fields
407
424
  - [ ] Registered in `createApp()` arrays (directly or via barrel exports)
408
425
  - [ ] Tests use `createMockContext()` from `@cyanheads/mcp-ts-core/testing`
409
- - [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = package name; `interface.shortDescription` from `package.json` description
410
- - [ ] `.codex-plugin/mcp.json` updated — server name key matches `package.json` name; env vars added for any required API keys
411
- - [ ] `.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
426
+ - [ ] `.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
427
+ - [ ] `.codex-plugin/mcp.json` updated — server name key is the unscoped repo name; every user-supplied variable (API key, 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
428
+ - [ ] `.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`
412
429
  - [ ] `npm run devcheck` passes
package/Dockerfile CHANGED
@@ -3,8 +3,11 @@
3
3
  #
4
4
  # This stage installs all dependencies (including dev), builds the TypeScript
5
5
  # source code into JavaScript, and prepares the production assets.
6
+ # The build stage pins to the BUILD platform, never the target: it emits
7
+ # architecture-independent JavaScript, so running it emulated buys nothing and
8
+ # costs a QEMU amd64 compile that Bun exhausts memory on.
6
9
  # ==============================================================================
7
- FROM oven/bun:1.4.0 AS build
10
+ FROM --platform=$BUILDPLATFORM oven/bun:1.4.0 AS build
8
11
 
9
12
  WORKDIR /usr/src/app
10
13
 
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.3-blue.svg?style=flat-square)](./CHANGELOG.md) [![License](https://img.shields.io/badge/License-Apache%202.0-orange.svg?style=flat-square)](./LICENSE) [![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/seerr-mcp-server?style=flat-square&logo=npm&logoColor=white)](https://www.npmjs.com/package/@cyanheads/seerr-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/)
10
+ [![Version](https://img.shields.io/badge/Version-0.1.4-blue.svg?style=flat-square)](./CHANGELOG.md) [![License](https://img.shields.io/badge/License-Apache%202.0-orange.svg?style=flat-square)](./LICENSE) [![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/seerr-mcp-server?style=flat-square&logo=npm&logoColor=white)](https://www.npmjs.com/package/@cyanheads/seerr-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
 
@@ -21,16 +21,11 @@
21
21
 
22
22
  ---
23
23
 
24
- A workflow MCP server over a self-hosted [Jellyseerr](https://github.com/Fallenbagel/jellyseerr) / [Overseerr](https://overseerr.dev/) instance — the request layer that fronts Jellyfin/Plex/Emby plus Radarr and Sonarr. The unit of work is not "download a movie"; it is **search → resolve the exact TMDB-backed title → check availability and request state → create a guarded request that Radarr/Sonarr act on.** Jellyseerr owns permissions, quotas, routing, and status; this server never touches Radarr/Sonarr directly.
24
+ ## Overview
25
25
 
26
- Two properties make it safe to hand an agent:
26
+ Jellyseerr and Overseerr media-request workflow: search TMDB-backed titles, confirm the exact match, check availability and request state, and create a guarded request that Radarr/Sonarr act on. Jellyseerr owns permissions, quotas, routing, and status — this server never calls Radarr/Sonarr directly. Runs as a stdio process or a local Streamable HTTP server.
27
27
 
28
- - **Guarded writes.** The one mutating tool (`seerr_request_media`) defaults to `mode: preview` — it resolves the title and returns the exact payload that _would_ be submitted without writing anything. The real request fires only on `mode: request`, which asks for an explicit confirmation and submits only once that confirmation comes back accepted.
29
- - **Operator-safe output.** Every payload passes through one normalization layer ([`src/services/seerr/normalizers.ts`](./src/services/seerr/normalizers.ts)) that allow-lists the fields it emits, so operator email, Plex/Jellyfin tokens and media-server IDs, and internal `serviceUrl` hosts never reach the model — requesters are projected to `{ id, displayName }`. Redaction is always on; filesystem paths are the single opt-in, behind `includePaths`.
30
-
31
- ## Tools
32
-
33
- Six tools covering the request workflow — discover (`search`) → confirm (`get`) → understand routing (`service_options`) → request (`request_media`) → track (`request_status` / `list_requests`):
28
+ ### Tools
34
29
 
35
30
  | Tool | Description |
36
31
  |:---|:---|
@@ -41,89 +36,89 @@ Six tools covering the request workflow — discover (`search`) → confirm (`ge
41
36
  | `seerr_request_status` | Fetch one request by ID — title, decoded request + media availability (incl. 4K), requester, routing summary, and a state-tuned next-step hint. |
42
37
  | `seerr_service_options` | Summarize configured Radarr/Sonarr services, default quality profiles, and instance capability flags (4K, partial requests, specials, media server). Filesystem paths redacted unless `includePaths`. |
43
38
 
44
- Every status field is decoded to `{ raw, label }` — both the numeric code Jellyseerr returns and a human label — so an agent never has to hardcode the enum mapping.
39
+ ### Resources
40
+
41
+ | Resource | Description |
42
+ |:---|:---|
43
+ | `seerr://request/{requestId}` | Read-once summary of one request — decoded status, media availability, requester, and routing. Mirrors `seerr_request_status`. |
44
+
45
+ All request data is also reachable via tools — request enumeration is the job of `seerr_list_requests` (the tool-only access path).
45
46
 
46
- ### `seerr_search_media`
47
+ ## Capability reference
47
48
 
48
- Title disambiguation entry point. Wraps `GET /search`, filters to movies and TV (people are always excluded), and decodes availability when the title is tracked.
49
+ ### `seerr_search_media` <sub>tool</sub>
49
50
 
50
- - Free-text title queries matched against TMDB; `movie` / `tv` / `all` media-type filter
51
- - Decoded availability (`status`, plus `status4k` when 4K is enabled) for tracked titles only
52
- - Pagination by page, with a per-call result `limit` to cap output size
53
- - Optional ISO 639-1 `language` for localized titles/overviews
51
+ - Free-text title query matched against TMDB; `mediaType` filters to `movie` / `tv` / `all` (people always excluded)
52
+ - Decoded availability (`status`, plus `status4k` when 4K is enabled) only for titles Jellyseerr already tracks
53
+ - `page` pagination (1–1000); `limit` caps returned results per call (1–20, default 10)
54
+ - Optional ISO 639-1 `language` override for localized titles/overviews
54
55
  - Empty results are a normal success — returns `[]` with a guidance notice, not an error
55
56
 
56
57
  ---
57
58
 
58
- ### `seerr_get_media`
59
-
60
- Confirm the exact title before a write. Wraps `GET /movie/{id}` or `GET /tv/{id}`, optionally a season's episodes.
59
+ ### `seerr_get_media` <sub>tool</sub>
61
60
 
62
61
  - Availability plus any existing open request for the title (avoids duplicate requests)
63
62
  - TV: omit `seasonNumber` for a per-season summary, or pass one to fetch that season's episode list (season 0 is Specials)
64
- - A TMDB ID that doesn't resolve surfaces as a clean `media_not_found` with a search-recovery hint (Jellyseerr's raw HTTP 500 is classified in the service layer)
63
+ - A TMDB ID that doesn't resolve surfaces as a typed `media_not_found` with a search-recovery hint (Jellyseerr's raw HTTP 500 is classified in the service layer)
65
64
 
66
65
  ---
67
66
 
68
- ### `seerr_list_requests`
69
-
70
- Review recent requests and their lifecycle. Wraps `GET /request`.
67
+ ### `seerr_list_requests` <sub>tool</sub>
71
68
 
72
69
  - Lifecycle `filter` (pending, processing, available, failed, …), `mediaType`, and `requestedById` filters
73
70
  - Sort by created (`added`) or last-changed (`modified`), ascending or descending
74
- - `take` / `skip` pagination; the enrichment trailer echoes the filter set the server applied
71
+ - `take` (1–100, default 20) / `skip` pagination; the enrichment trailer echoes the applied filter set
75
72
  - Requester is PII-redacted to `{ id, displayName }`
76
- - Titles aren't on request objects. `includeTitles: true` joins them from the media records one lookup per _distinct_ title on the page, so a 4K and a non-4K request for one film cost one call. Default is off, keeping the call to a single upstream read. Rows that can't be resolved keep every other field and are disclosed in the notice
73
+ - Titles aren't on request objects `includeTitles: true` joins them from media records (one lookup per distinct title, default off); unresolved rows keep every other field and are disclosed in the notice
77
74
 
78
75
  ---
79
76
 
80
- ### `seerr_request_media`
77
+ ### `seerr_request_media` <sub>tool</sub>
81
78
 
82
- The only mutation in the surface, and it is triple-guarded:
79
+ - **Guarded write.** `mode: preview` (default) resolves the title and returns the exact `POST /request` payload that would be submitted, with no write; `mode: request` submits only after an explicit confirmation round comes back accepted — declining, cancelling, or an invalid answer cancels before submission (`request_cancelled`), and `destructiveHint: true` flags the risk to client approval flows
80
+ - Runs `stateful` by design — a 2025-era client answers the confirmation over a live session, which `stateless` can't hold open. The server declares that posture itself, so an HTTP deployment that sets `MCP_SESSION_MODE=stateless` fails at startup rather than serving an unusable tool
81
+ - Capability validation (4K enabled? seasons valid? partial requests allowed?) runs locally against cached instance settings before any POST, so a bad request fails with a typed error instead of a failed write
82
+ - TV requests take `seasons: "all"` or an explicit list (e.g. `[1, 2]`); season 0 (Specials) is rejected unless the instance enables it
83
+ - Optional routing overrides — `serverId`, `profileId`, `rootFolder`, `languageProfileId` — omit to use Jellyseerr's defaults (recommended)
84
+ - An existing request for the title surfaces in the output; a duplicate rejection from Jellyseerr maps to a typed `duplicate_request` pointing back at it
83
85
 
84
- 1. **`mode: preview` (default)** resolves the title and returns the exact `POST /request` payload that _would_ be submitted — no write. A sloppy call shows the payload and changes nothing.
85
- 2. **`mode: request`** asks for an explicit confirmation and submits only once it comes back accepted. Declining, cancelling, or answering with anything the confirmation schema rejects cancels before submission (`request_cancelled`) — there is no branch that proceeds without an acceptance, so a client that never answers leaves the write un-run.
86
- 3. **`destructiveHint: true`** surfaces the risk in client-side approval flows.
86
+ ---
87
87
 
88
- Over HTTP this needs `MCP_SESSION_MODE` to resolve to `stateful` (the default `auto` does): 2025-era clients answer the confirmation over a live session, which `stateless` has no way to hold open.
88
+ ### `seerr_request_status` <sub>tool</sub>
89
89
 
90
- - Capability validation (4K enabled? seasons valid? partial requests allowed?) runs **locally** against cached instance settings _before_ any POST, so a bad request fails with an actionable typed error instead of a failed write
91
- - TV requests take `seasons: "all"` or an explicit list (e.g. `[1, 2]`); Specials are excluded unless the instance enables them
92
- - Optional routing overrides (`serverId`, `profileId`, `rootFolder`, `languageProfileId`) omit to use Jellyseerr's defaults (recommended)
93
- - An existing request for the title is surfaced in the output; a duplicate rejection from Jellyseerr maps to a typed `duplicate_request` pointing back at it
90
+ - Wraps `GET /request/{id}`; `requestId` comes from `seerr_request_media`'s `created.requestId` or `seerr_list_requests`
91
+ - Returns decoded `requestStatus` and `mediaStatus`/`mediaStatus4k`, requester (`{ id, displayName }`), and a routing summary (`serverId`, `profileName`, `is4k` — no filesystem paths)
92
+ - `title` is joined from the media detail endpoint on every call (no opt-in flag needed) and omitted when the request has no `tmdbId` or the lookup fails
93
+ - `stateGuidance` returns a next-step hint tuned to the current status
94
+ - A missing request ID surfaces as a typed `request_not_found` (Jellyseerr's raw HTTP 404 is classified in the service layer)
94
95
 
95
96
  ---
96
97
 
97
- ### `seerr_service_options`
98
-
99
- Lets an agent reason about request capability and routing without a separate status tool. Fans out service + settings + version reads with `Promise.allSettled`, so one failed leg degrades to a disclosed notice rather than failing the call.
98
+ ### `seerr_service_options` <sub>tool</sub>
100
99
 
101
100
  - Instance capability summary: Jellyseerr version, media server, and the `movie4kEnabled` / `series4kEnabled` / `partialRequestsEnabled` / `specialEpisodesEnabled` flags
102
101
  - Per-service routing: server ID, default-server flag, 4K capability, and the active + available quality profiles (IDs and names, safe to surface)
103
102
  - Filesystem root-folder paths and free space are operator-private — omitted unless `includePaths: true`
103
+ - One failed service leg (Radarr/Sonarr detail, settings, or version) degrades to a disclosed notice instead of failing the whole call
104
104
 
105
- ## Resource and prompt
105
+ ---
106
106
 
107
- | Type | Name | Description |
108
- |:---|:---|:---|
109
- | Resource | `seerr://request/{requestId}` | Read-once summary of one request — title, decoded status + media availability + routing. Mirrors `seerr_request_status`. |
107
+ ### `seerr://request/{requestId}` <sub>resource</sub>
110
108
 
111
- All request data is also reachable via tools request _enumeration_ is the job of `seerr_list_requests` (filterable, the tool-only access path), so the collection is intentionally not exposed as a resource. There are no prompts; the guarded-write workflow lives in the tool, not a prompt template.
109
+ - Mirrors `seerr_request_status`same `projectRequestDetail` redaction choke point and title join, so the output is identical and equally PII-clean
110
+ - `requestId` comes from `seerr_request_media` or `seerr_list_requests`
111
+ - No per-read options — title is always joined (one request, one extra read); absent when there's no `tmdbId` or the lookup fails
112
+ - A missing request ID surfaces as a typed `request_not_found`
112
113
 
113
114
  ## Features
114
115
 
115
- Built on [`@cyanheads/mcp-ts-core`](https://www.npmjs.com/package/@cyanheads/mcp-ts-core):
116
-
117
- - Declarative tool and resource definitions — single file per primitive, framework handles registration and validation
118
- - Unified error handling — handlers throw, framework catches, classifies, and formats
119
- - Pluggable auth: `none`, `jwt`, `oauth`
120
- - Swappable storage backends: `in-memory`, `filesystem`, `Supabase`, `Cloudflare KV/R2/D1`
121
- - Structured logging with optional OpenTelemetry tracing
122
- - STDIO and Streamable HTTP transports
116
+ 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.
123
117
 
124
- Jellyseerr-specific:
118
+ Seerr-specific:
125
119
 
126
120
  - Read + guarded-request only — admin-scope endpoints (approve/decline, retry, edit/delete, media/file deletion, user/settings/sync) are excluded by design, not by API limitation
121
+ - PII/infra redaction centralized in one normalizer choke point — requesters project to `{ id, displayName }`; operator email, Plex/Jellyfin tokens, and `serviceUrl` never reach output; filesystem paths are opt-in via `includePaths`
127
122
  - Status decoding centralized in one helper — request and media statuses (including the separate 4K availability) decode to `{ raw, label }` everywhere, forward-compatible with new Jellyseerr status codes
128
123
  - Capability validation against cached instance settings catches most bad requests before they reach the API
129
124
  - A short-TTL settings cache avoids a round-trip on every preview
@@ -135,7 +130,7 @@ Agent-friendly output:
135
130
 
136
131
  ## Getting started
137
132
 
138
- This server connects to your own Jellyseerr/Overseerr instance — there is no public hosted endpoint. Add the following to your MCP client configuration file, pointing `SEERR_BASE_URL` at your instance and supplying its API key.
133
+ Add the following to your MCP client configuration file, pointing `SEERR_BASE_URL` at your own Jellyseerr or Overseerr instance and supplying its API key.
139
134
 
140
135
  ```json
141
136
  {
@@ -184,7 +179,7 @@ MCP_TRANSPORT_TYPE=http MCP_HTTP_PORT=3010 SEERR_BASE_URL=http://localhost:5055
184
179
 
185
180
  ### Prerequisites
186
181
 
187
- - [Bun v1.3.2](https://bun.sh/) or higher (or Node.js v24+).
182
+ - [Bun v1.4.0](https://bun.sh/) or higher (or Node.js v24+).
188
183
  - A running Jellyseerr or Overseerr instance, and its API key (Settings → General → API Key).
189
184
 
190
185
  ### Installation
@@ -292,7 +287,7 @@ See [`CLAUDE.md`/`AGENTS.md`](./CLAUDE.md) for development guidelines and archit
292
287
 
293
288
  ## Contributing
294
289
 
295
- Issues and pull requests are welcome. Run checks and tests before submitting:
290
+ Issues are welcome. Run checks and tests before submitting:
296
291
 
297
292
  ```sh
298
293
  bun run devcheck
@@ -0,0 +1,34 @@
1
+ ---
2
+ summary: "Adopts mcp-ts-core 0.13.6: the HTTP session posture is declared in src/ so a stateless deployment fails startup instead of serving an unusable guarded write, argument rejections reach callers as InvalidParams with a recovery hint, and the framework skill tree moves to framework-skills/."
3
+ breaking: true
4
+ security: false
5
+ ---
6
+
7
+ # 0.1.4 — 2026-09-20
8
+
9
+ ## Added
10
+
11
+ - **`createApp({ sessionMode })`** — `{ default: 'stateful', require: 'stateful' }` in `src/index.ts`. `seerr_request_media` gates its write on `ctx.requestInput`, which a 2025-era client can only answer over a live session, so an HTTP deployment resolving to `stateless` now raises a `ConfigurationError` at startup rather than serving an unusable tool. A stdio start is never refused.
12
+ - **`bun run audit:fix`** — `bun audit fix`, the first step of transitive-advisory triage ahead of `audit:refresh`.
13
+ - **`funding`** in `package.json` — GitHub Sponsors and Buy Me a Coffee.
14
+
15
+ ## Changed
16
+
17
+ - **An argument rejection is `InvalidParams` (`-32602`)**, not `ValidationError` (`-32007`). It carries `data.reason: "invalid_arguments"` and appends a `Recovery: …` line to `content[0].text`.
18
+ - **Tool error text closes with `(reason <reason> · not retryable)`** whenever the error carries a `reason` or a boolean `retryable` — every typed failure in this surface does. `structuredContent` is unchanged.
19
+ - **An unrecognized argument key is reconciled before it is rejected** — one differing from a declared key only in case style (`media_type` → `mediaType`) is rewritten, a built-in set of client-added root keys is dropped, and a JSON-stringified array retries the parse once. Anything still unresolved is rejected by name as before.
20
+ - **The upstream request URL no longer reaches `error.data`** on an unclassified Jellyseerr status; the message names the host only. This server never passes `includeUrl: true`, so the instance base URL and API key stay off every client-facing surface.
21
+ - **Engines floor is Bun ≥1.4.0** (was ≥1.3.0), matching the framework.
22
+ - **Development skills live in `framework-skills/`, not `skills/`** — plugin hosts auto-load a root `skills/`, which handed them to every agent installing the server. The `.claude/skills/` mirror keeps its name.
23
+ - **`media_not_found` and `request_not_found` contract entries carry `thrownBy: 'service'`** — both are raised by the `src/services/seerr/errors.ts` classifier rather than a handler `ctx.fail`, which is what the new `error-contract-unthrown` lint rule reads.
24
+ - **`.env.example` sets `MCP_SESSION_MODE=stateful` actively** instead of documenting it commented out.
25
+
26
+ ## Dependencies
27
+
28
+ - `@cyanheads/mcp-ts-core` ^0.12.3 → ^0.13.6
29
+ - `zod` ^4.4.3 → ^4.6.5
30
+ - `@biomejs/biome` 2.5.10 → 2.5.14
31
+ - `@types/node` 26.2.0 → 26.6.1
32
+ - `ignore` ^7.0.6 → ^7.0.9
33
+ - `tsc-alias` ^1.9.2 → ^1.9.5
34
+ - `vitest` ^4.1.11 → ^5.0.1
@@ -6,8 +6,8 @@
6
6
 
7
7
  # Required. One-line GitHub Release-style headline. 350 character cap — a
8
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
10
- # headline, like a tag's theme line. Quotes required: unquoted YAML treats
9
+ # unrelated changes with commas/semicolons into an inventory — pick the one
10
+ # headline the release is about. Quotes required: unquoted YAML treats
11
11
  # `: ` inside the value as a key separator and fails GitHub's strict parser.
12
12
  summary: ""
13
13
 
@@ -117,30 +117,13 @@ security: false
117
117
  in that unrelated item's metadata.
118
118
 
119
119
  TAG ANNOTATIONS — the annotated tag body renders as the GitHub Release body
120
- via `gh release create --notes-from-tag`. The tag is a derivative of this
121
- changelog entry a condensed, scannable version, not a copy. Format:
122
-
123
- <themeomit version number, GitHub prepends it>
124
- blank line
125
- <1-2 sentence context: what this release does>
126
- blank line
127
- Dependency bumps: ← section header
128
- ← blank line
129
- - `@cyanheads/mcp-ts-core` ^0.9.1 → ^0.9.6 ← bullet
130
- ← blank line
131
- Changed: ← only sections with entries
132
- ← blank line
133
- - `format()` output includes `query` in text mode
134
- ← blank line
135
- Added:
136
- ← blank line
137
- - `manifest.json` scaffolded for MCPB bundle support
138
- - Install badges (Claude Desktop, Cursor, VS Code)
139
- ← blank line
140
- <N> tests pass; `bun run devcheck` clean. ← footer
141
-
142
- Never a flat comma-separated string. Always structured markdown with
143
- 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.
144
127
  -->
145
128
 
146
129
  ## Added
package/dist/index.d.ts CHANGED
@@ -3,6 +3,9 @@
3
3
  * @fileoverview seerr-mcp-server MCP server entry point. Wires the SeerrService in
4
4
  * setup() and registers the six tools + one resource. Identity is name + title
5
5
  * only (the hyphenated machine name) — description derives from package.json.
6
+ * The HTTP session posture is declared here rather than left to a deployment's
7
+ * MCP_SESSION_MODE, because seerr_request_media's confirmation round is not
8
+ * optional to this server's guarantee.
6
9
  * @module index
7
10
  */
8
11
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA;;;;;GAKG"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA;;;;;;;;GAQG"}
package/dist/index.js CHANGED
@@ -3,6 +3,9 @@
3
3
  * @fileoverview seerr-mcp-server MCP server entry point. Wires the SeerrService in
4
4
  * setup() and registers the six tools + one resource. Identity is name + title
5
5
  * only (the hyphenated machine name) — description derives from package.json.
6
+ * The HTTP session posture is declared here rather than left to a deployment's
7
+ * MCP_SESSION_MODE, because seerr_request_media's confirmation round is not
8
+ * optional to this server's guarantee.
6
9
  * @module index
7
10
  */
8
11
  import { createApp } from '@cyanheads/mcp-ts-core';
@@ -14,6 +17,13 @@ await createApp({
14
17
  title: 'seerr-mcp-server',
15
18
  tools: allToolDefinitions,
16
19
  resources: allResourceDefinitions,
20
+ /**
21
+ * The guarded write gates on `ctx.requestInput`, which a 2025-era HTTP client can
22
+ * only answer over a live session. `require: 'stateful'` turns a `stateless`
23
+ * deployment into a startup ConfigurationError instead of a silently unusable
24
+ * `seerr_request_media`; a stdio start is never refused.
25
+ */
26
+ sessionMode: { default: 'stateful', require: 'stateful' },
17
27
  instructions: 'Local Seerr request workflow. Search first (seerr_search_media), confirm the exact title ' +
18
28
  '(seerr_get_media), then request via seerr_request_media — which defaults to mode:preview and ' +
19
29
  'only writes on mode:request. "Download X" means "create a Seerr request for X"; never bypass to Radarr/Sonarr.',
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA;;;;;GAKG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EAAE,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAErE,MAAM,SAAS,CAAC;IACd,IAAI,EAAE,kBAAkB;IACxB,KAAK,EAAE,kBAAkB;IACzB,KAAK,EAAE,kBAAkB;IACzB,SAAS,EAAE,sBAAsB;IACjC,YAAY,EACV,2FAA2F;QAC3F,+FAA+F;QAC/F,gHAAgH;IAClH,KAAK,CAAC,IAAI;QACR,gBAAgB,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;IAC9C,CAAC;CACF,CAAC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA;;;;;;;;GAQG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EAAE,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AAC7E,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAErE,MAAM,SAAS,CAAC;IACd,IAAI,EAAE,kBAAkB;IACxB,KAAK,EAAE,kBAAkB;IACzB,KAAK,EAAE,kBAAkB;IACzB,SAAS,EAAE,sBAAsB;IACjC;;;;;OAKG;IACH,WAAW,EAAE,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,UAAU,EAAE;IACzD,YAAY,EACV,2FAA2F;QAC3F,+FAA+F;QAC/F,gHAAgH;IAClH,KAAK,CAAC,IAAI;QACR,gBAAgB,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;IAC9C,CAAC;CACF,CAAC,CAAC"}
@@ -44,5 +44,6 @@ export declare const allResourceDefinitions: import("@cyanheads/mcp-ts-core").Re
44
44
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
45
45
  readonly when: "No request exists with the given ID (Seerr returns HTTP 404 \"Request not found.\").";
46
46
  readonly recovery: "List requests with seerr_list_requests to find a valid requestId, then retry.";
47
+ readonly thrownBy: "service";
47
48
  }]>[];
48
49
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAAyB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAAyB,CAAC"}
@@ -53,5 +53,7 @@ export declare const seerrRequestResource: import("@cyanheads/mcp-ts-core").Reso
53
53
  readonly code: JsonRpcErrorCode.NotFound;
54
54
  readonly when: "No request exists with the given ID (Seerr returns HTTP 404 \"Request not found.\").";
55
55
  readonly recovery: "List requests with seerr_list_requests to find a valid requestId, then retry.";
56
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
57
+ readonly thrownBy: "service";
56
58
  }]>;
57
59
  //# sourceMappingURL=request.resource.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"request.resource.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/request.resource.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAY,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAMjE,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoE/B,CAAC"}
1
+ {"version":3,"file":"request.resource.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/request.resource.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAY,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAMjE,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAuD3B,yGAAyG;;GAe7G,CAAC"}
@@ -66,6 +66,8 @@ export const seerrRequestResource = resource('seerr://request/{requestId}', {
66
66
  code: JsonRpcErrorCode.NotFound,
67
67
  when: 'No request exists with the given ID (Seerr returns HTTP 404 "Request not found.").',
68
68
  recovery: 'List requests with seerr_list_requests to find a valid requestId, then retry.',
69
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
70
+ thrownBy: 'service',
69
71
  },
70
72
  ],
71
73
  async handler(params, ctx) {
@@ -1 +1 @@
1
- {"version":3,"file":"request.resource.js","sourceRoot":"","sources":["../../../../src/mcp-server/resources/definitions/request.resource.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,QAAQ,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACjE,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AACvE,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AACvD,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAEjE,MAAM,CAAC,MAAM,oBAAoB,GAAG,QAAQ,CAAC,6BAA6B,EAAE;IAC1E,IAAI,EAAE,eAAe;IACrB,KAAK,EAAE,2BAA2B;IAClC,WAAW,EACT,qMAAqM;IACvM,QAAQ,EAAE,kBAAkB;IAC5B,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,SAAS,EAAE,CAAC;aACT,MAAM,EAAE;aACR,KAAK,CAAC,OAAO,CAAC;aACd,QAAQ,CAAC,6EAA6E,CAAC;KAC3F,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iBAAiB,CAAC;QACjD,SAA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MAAM,EAAE,GAAG;QACvB,MAAM,KAAK,GAAG,eAAe,EAAE,CAAC;QAChC,MAAM,GAAG,GAAG,MAAM,KAAK,CAAC,UAAU,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,SAAS,EAAE,EAAE,CAAC,EAAE,GAAG,CAAC,CAAC;QAC/E,MAAM,MAAM,GAAG,MAAM,mBAAmB,CAAC,oBAAoB,CAAC,GAAG,CAAC,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC;QAChF,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,6BAA6B,EAAE;YAC3C,SAAS,EAAE,MAAM,CAAC,SAAS;YAC3B,aAAa,EAAE,MAAM,CAAC,KAAK,KAAK,SAAS;SAC1C,CAAC,CAAC;QACH,OAAO,MAAM,CAAC;IAChB,CAAC;CACF,CAAC,CAAC"}
@@ -62,5 +62,7 @@ export declare const getMediaTool: import("@cyanheads/mcp-ts-core").ToolDefiniti
62
62
  readonly code: JsonRpcErrorCode.NotFound;
63
63
  readonly when: "The TMDB ID does not resolve to a movie/show (Seerr returns HTTP 500 \"Unable to retrieve movie.\").";
64
64
  readonly recovery: "Call seerr_search_media to find the correct tmdbId, then retry with the exact ID and matching mediaType.";
65
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
66
+ readonly thrownBy: "service";
65
67
  }], undefined>;
66
68
  //# sourceMappingURL=get-media.tool.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"get-media.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/get-media.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAiBjE,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAsMvB,CAAC"}
1
+ {"version":3,"file":"get-media.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/get-media.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAiBjE,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IA0FnB,yGAAyG;;cA8G7G,CAAC"}
@@ -96,6 +96,8 @@ export const getMediaTool = tool('seerr_get_media', {
96
96
  code: JsonRpcErrorCode.NotFound,
97
97
  when: 'The TMDB ID does not resolve to a movie/show (Seerr returns HTTP 500 "Unable to retrieve movie.").',
98
98
  recovery: 'Call seerr_search_media to find the correct tmdbId, then retry with the exact ID and matching mediaType.',
99
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
100
+ thrownBy: 'service',
99
101
  },
100
102
  ],
101
103
  async handler(input, ctx) {
@@ -1 +1 @@
1
- {"version":3,"file":"get-media.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/get-media.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACjE,OAAO,EACL,kBAAkB,EAClB,aAAa,EACb,iBAAiB,EACjB,YAAY,GACb,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAEnE,wDAAwD;AACxD,SAAS,MAAM,CAAC,IAAwB;IACtC,IAAI,CAAC,IAAI;QAAE,OAAO;IAClB,MAAM,IAAI,GAAG,MAAM,CAAC,QAAQ,CA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,CAAC,CAAC,aAAa,IAAI,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,OAAO,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;gBACvF,IAAI,CAAC,CAAC,QAAQ;oBAAE,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;YAChD,CAAC;QACH,CAAC;QACD,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
@@ -76,6 +76,7 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
76
76
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
77
77
  readonly when: "tmdbId does not resolve to a movie/show (Seerr 500 \"Unable to retrieve movie.\").";
78
78
  readonly recovery: "Run seerr_search_media to get the correct tmdbId and retry with the matching mediaType.";
79
+ readonly thrownBy: "service";
79
80
  }, {
80
81
  readonly reason: "seasons_required";
81
82
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
@@ -200,6 +201,7 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
200
201
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
201
202
  readonly when: "The TMDB ID does not resolve to a movie/show (Seerr returns HTTP 500 \"Unable to retrieve movie.\").";
202
203
  readonly recovery: "Call seerr_search_media to find the correct tmdbId, then retry with the exact ID and matching mediaType.";
204
+ readonly thrownBy: "service";
203
205
  }], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
204
206
  filter: import("zod").ZodDefault<import("zod").ZodEnum<{
205
207
  all: "all";
@@ -310,6 +312,7 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
310
312
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
311
313
  readonly when: "No request exists with the given ID (Seerr returns HTTP 404 \"Request not found.\").";
312
314
  readonly recovery: "List requests with seerr_list_requests to find a valid requestId, then retry.";
315
+ readonly thrownBy: "service";
313
316
  }], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
314
317
  service: import("zod").ZodDefault<import("zod").ZodEnum<{
315
318
  all: "all";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AASH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAO9B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AASH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAO9B,CAAC"}
@@ -91,6 +91,8 @@ export declare const requestMediaTool: import("@cyanheads/mcp-ts-core").ToolDefi
91
91
  readonly code: JsonRpcErrorCode.NotFound;
92
92
  readonly when: "tmdbId does not resolve to a movie/show (Seerr 500 \"Unable to retrieve movie.\").";
93
93
  readonly recovery: "Run seerr_search_media to get the correct tmdbId and retry with the matching mediaType.";
94
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
95
+ readonly thrownBy: "service";
94
96
  }, {
95
97
  readonly reason: "seasons_required";
96
98
  readonly code: JsonRpcErrorCode.InvalidParams;
@@ -1 +1 @@
1
- {"version":3,"file":"request-media.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/request-media.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAuB,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAY,MAAM,+BAA+B,CAAC;AA0B3E,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cA6X3B,CAAC"}
1
+ {"version":3,"file":"request-media.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/request-media.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAuB,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAY,MAAM,+BAA+B,CAAC;AA0B3E,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAgJvB,yGAAyG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cA+O7G,CAAC"}
@@ -156,6 +156,8 @@ export const requestMediaTool = tool('seerr_request_media', {
156
156
  code: JsonRpcErrorCode.NotFound,
157
157
  when: 'tmdbId does not resolve to a movie/show (Seerr 500 "Unable to retrieve movie.").',
158
158
  recovery: 'Run seerr_search_media to get the correct tmdbId and retry with the matching mediaType.',
159
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
160
+ thrownBy: 'service',
159
161
  },
160
162
  {
161
163
  reason: 'seasons_required',
@@ -1 +1 @@
1
- {"version":3,"file":"request-media.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/request-media.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAC3E,OAAO,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AACpE,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,SAAS,EACT,UAAU,GACX,MAAM,4BAA4B,CAAC;AAGpC,wFAAwF;AACxF,MAAM,WAAW,GAAG,SAAS,CAAC;AAE9B;;;;;GAKG;AACH,MAAM,aAAa,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7B,SAAS,EAAE,CAAC;SACT,OAAO,EAAE;SACT,QAAQ,CAAC,0EAA0E,CAAC;CACxF,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,CAAC,qBAAqB,EAAE;IAC1D,KAAK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I,CAAC;IAChC,OAAO,4CAA4C,CAAC,IAAI,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;AACxE,CAAC"}
@@ -53,5 +53,7 @@ export declare const requestStatusTool: import("@cyanheads/mcp-ts-core").ToolDef
53
53
  readonly code: JsonRpcErrorCode.NotFound;
54
54
  readonly when: "No request exists with the given ID (Seerr returns HTTP 404 \"Request not found.\").";
55
55
  readonly recovery: "List requests with seerr_list_requests to find a valid requestId, then retry.";
56
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
57
+ readonly thrownBy: "service";
56
58
  }], undefined>;
57
59
  //# sourceMappingURL=request-status.tool.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"request-status.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/request-status.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAMjE,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cA4G5B,CAAC"}
1
+ {"version":3,"file":"request-status.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/request-status.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAMjE,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IA8DxB,yGAAyG;;cAgD7G,CAAC"}
@@ -69,6 +69,8 @@ export const requestStatusTool = tool('seerr_request_status', {
69
69
  code: JsonRpcErrorCode.NotFound,
70
70
  when: 'No request exists with the given ID (Seerr returns HTTP 404 "Request not found.").',
71
71
  recovery: 'List requests with seerr_list_requests to find a valid requestId, then retry.',
72
+ /** Raised by the service-layer classifier in `services/seerr/errors.ts`, not by a handler `ctx.fail`. */
73
+ thrownBy: 'service',
72
74
  },
73
75
  ],
74
76
  async handler(input, ctx) {
@@ -1 +1 @@
1
- {"version":3,"file":"request-status.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/request-status.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACjE,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AACvE,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAEjE,MAAM,CAAC,MAAM,iBAAiB,GAAG,IAAI,CAAC,sBAAsB,EAAE;IAC5D,KAAK,EAAE,kCAAkC;IACzC,WAAW,EACT,uRAAuR;IACzR,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IACxD,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC;QACd,SAAS,EAAE,CAAC;aACT,MAAM,EAAE;aACR,GAAG,EAAE;aACL,QAAQ,EAAE;aACV,QAAQ,CACP,wGAAwG,CACzG;KACJ,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC;QACf,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iBAAiB,CAAC;QACjD,SAAS,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,cAAc,CAAC;QAC3D,KAAK,EAAE,CAAC;aACL,MAAM,EAAE;aACR,Q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AAS,EAAE,CAAC,CAAC;QAC1E,IAAI,MAAM,CAAC,SAAS;YAAE,UAAU,CAAC,IAAI,CAAC,gBAAgB,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC;QAC1E,IAAI,UAAU,CAAC,MAAM,GAAG,CAAC;YAAE,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;QAC9D,IAAI,MAAM,CAAC,aAAa,EAAE,CAAC;YACzB,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YACf,KAAK,CAAC,IAAI,CAAC,KAAK,MAAM,CAAC,aAAa,EAAE,CAAC,CAAC;QAC1C,CAAC;QACD,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
1
+ {"version":3,"file":"request-status.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/request-status.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACjE,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AACvE,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAEjE,MAAM,CAAC,MAAM,iBAAiB,GAAG,IAAI,CAAC,sBAAsB,EAAE;IAC5D,KAAK,EAAE,kCAAkC;IACzC,WAAW,EACT,uRAAuR;IACzR,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE;IACxD,KAAK,EAAE,C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IAAI,CAAC,gBAAgB,MAAM,CAAC,OAAO,CAAC,WAAW,EAAE,CAAC,CAAC;QAC3F,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;QAEhC,IAAI,MAAM,CAAC,OAAO,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC;YAC7C,KAAK,CAAC,IAAI,CAAC,gBAAgB,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QAC1D,MAAM,UAAU,GAAa,EAAE,CAAC;QAChC,IAAI,MAAM,CAAC,SAAS;YAAE,UAAU,CAAC,IAAI,CAAC,gBAAgB,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC;QAC1E,IAAI,MAAM,CAAC,SAAS;YAAE,UAAU,CAAC,IAAI,CAAC,gBAAgB,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC;QAC1E,IAAI,UAAU,CAAC,MAAM,GAAG,CAAC;YAAE,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;QAC9D,IAAI,MAAM,CAAC,aAAa,EAAE,CAAC;YACzB,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YACf,KAAK,CAAC,IAAI,CAAC,KAAK,MAAM,CAAC,aAAa,EAAE,CAAC,CAAC;QAC1C,CAAC;QACD,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cyanheads/seerr-mcp-server",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "Search Jellyseerr/Overseerr, check availability, and create guarded media requests via MCP. STDIO or Streamable HTTP.",
5
5
  "mcpName": "io.github.cyanheads/seerr-mcp-server",
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",
@@ -62,27 +63,37 @@
62
63
  "url": "https://github.com/cyanheads/seerr-mcp-server/issues"
63
64
  },
64
65
  "license": "Apache-2.0",
66
+ "funding": [
67
+ {
68
+ "type": "github",
69
+ "url": "https://github.com/sponsors/cyanheads"
70
+ },
71
+ {
72
+ "type": "buy_me_a_coffee",
73
+ "url": "https://www.buymeacoffee.com/cyanheads"
74
+ }
75
+ ],
65
76
  "packageManager": "bun@1.4.0",
66
77
  "engines": {
67
- "bun": ">=1.3.0",
78
+ "bun": ">=1.4.0",
68
79
  "node": ">=24.0.0"
69
80
  },
70
81
  "publishConfig": {
71
82
  "access": "public"
72
83
  },
73
84
  "dependencies": {
74
- "@cyanheads/mcp-ts-core": "^0.12.3",
85
+ "@cyanheads/mcp-ts-core": "^0.13.6",
75
86
  "pino-pretty": "^13.1.3",
76
- "zod": "^4.4.3"
87
+ "zod": "^4.6.5"
77
88
  },
78
89
  "devDependencies": {
79
- "@biomejs/biome": "2.5.10",
90
+ "@biomejs/biome": "2.5.14",
80
91
  "@socketsecurity/bun-security-scanner": "^1.1.2",
81
- "@types/node": "26.2.0",
92
+ "@types/node": "26.6.1",
82
93
  "depcheck": "^1.4.7",
83
- "ignore": "^7.0.6",
84
- "tsc-alias": "^1.9.2",
94
+ "ignore": "^7.0.9",
95
+ "tsc-alias": "^1.9.5",
85
96
  "typescript": "^7.0.2",
86
- "vitest": "^4.1.11"
97
+ "vitest": "^5.0.1"
87
98
  }
88
99
  }
package/server.json CHANGED
@@ -6,14 +6,14 @@
6
6
  "url": "https://github.com/cyanheads/seerr-mcp-server",
7
7
  "source": "github"
8
8
  },
9
- "version": "0.1.3",
9
+ "version": "0.1.4",
10
10
  "packages": [
11
11
  {
12
12
  "registryType": "npm",
13
13
  "registryBaseUrl": "https://registry.npmjs.org",
14
14
  "identifier": "@cyanheads/seerr-mcp-server",
15
15
  "runtimeHint": "bun",
16
- "version": "0.1.3",
16
+ "version": "0.1.4",
17
17
  "packageArguments": [
18
18
  {
19
19
  "type": "positional",
@@ -61,7 +61,7 @@
61
61
  "registryBaseUrl": "https://registry.npmjs.org",
62
62
  "identifier": "@cyanheads/seerr-mcp-server",
63
63
  "runtimeHint": "bun",
64
- "version": "0.1.3",
64
+ "version": "0.1.4",
65
65
  "packageArguments": [
66
66
  {
67
67
  "type": "positional",