@withpica/mcp-server 2.96.2 → 2.97.1

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 (75) hide show
  1. package/CHANGELOG.md +105 -0
  2. package/README.md +6 -2
  3. package/dist/lib/changelog.generated.d.ts +2 -2
  4. package/dist/lib/changelog.generated.d.ts.map +1 -1
  5. package/dist/lib/changelog.generated.js +2 -2
  6. package/dist/lib/changelog.generated.js.map +1 -1
  7. package/dist/server-instructions.d.ts +12 -2
  8. package/dist/server-instructions.d.ts.map +1 -1
  9. package/dist/server-instructions.js +13 -2
  10. package/dist/server-instructions.js.map +1 -1
  11. package/dist/tools/arg-aliases.d.ts +59 -0
  12. package/dist/tools/arg-aliases.d.ts.map +1 -0
  13. package/dist/tools/arg-aliases.js +91 -0
  14. package/dist/tools/arg-aliases.js.map +1 -0
  15. package/dist/tools/audio-files.d.ts.map +1 -1
  16. package/dist/tools/audio-files.js +38 -7
  17. package/dist/tools/audio-files.js.map +1 -1
  18. package/dist/tools/credits.js +1 -1
  19. package/dist/tools/credits.js.map +1 -1
  20. package/dist/tools/dashboard.d.ts.map +1 -1
  21. package/dist/tools/dashboard.js +24 -2
  22. package/dist/tools/dashboard.js.map +1 -1
  23. package/dist/tools/deprecations.d.ts +7 -0
  24. package/dist/tools/deprecations.d.ts.map +1 -1
  25. package/dist/tools/deprecations.js +17 -10
  26. package/dist/tools/deprecations.js.map +1 -1
  27. package/dist/tools/discovery.d.ts.map +1 -1
  28. package/dist/tools/discovery.js +99 -66
  29. package/dist/tools/discovery.js.map +1 -1
  30. package/dist/tools/duplicates.d.ts.map +1 -1
  31. package/dist/tools/duplicates.js +29 -3
  32. package/dist/tools/duplicates.js.map +1 -1
  33. package/dist/tools/index.d.ts.map +1 -1
  34. package/dist/tools/index.js +9 -2
  35. package/dist/tools/index.js.map +1 -1
  36. package/dist/tools/metadata.d.ts.map +1 -1
  37. package/dist/tools/metadata.js +48 -10
  38. package/dist/tools/metadata.js.map +1 -1
  39. package/dist/tools/multimedia.d.ts.map +1 -1
  40. package/dist/tools/multimedia.js +33 -5
  41. package/dist/tools/multimedia.js.map +1 -1
  42. package/dist/tools/notes.d.ts.map +1 -1
  43. package/dist/tools/notes.js +24 -2
  44. package/dist/tools/notes.js.map +1 -1
  45. package/dist/tools/people.d.ts.map +1 -1
  46. package/dist/tools/people.js +1 -0
  47. package/dist/tools/people.js.map +1 -1
  48. package/dist/tools/public-filter.d.ts.map +1 -1
  49. package/dist/tools/public-filter.js +1 -1
  50. package/dist/tools/public-filter.js.map +1 -1
  51. package/dist/tools/recovery-hints.d.ts.map +1 -1
  52. package/dist/tools/recovery-hints.js +28 -4
  53. package/dist/tools/recovery-hints.js.map +1 -1
  54. package/dist/tools/releases.d.ts.map +1 -1
  55. package/dist/tools/releases.js +3 -1
  56. package/dist/tools/releases.js.map +1 -1
  57. package/dist/tools/selections.d.ts +42 -0
  58. package/dist/tools/selections.d.ts.map +1 -0
  59. package/dist/tools/selections.js +361 -0
  60. package/dist/tools/selections.js.map +1 -0
  61. package/dist/tools/sessions.d.ts.map +1 -1
  62. package/dist/tools/sessions.js +25 -3
  63. package/dist/tools/sessions.js.map +1 -1
  64. package/dist/tools/subscription.d.ts.map +1 -1
  65. package/dist/tools/subscription.js +8 -2
  66. package/dist/tools/subscription.js.map +1 -1
  67. package/dist/tools/works.d.ts.map +1 -1
  68. package/dist/tools/works.js +1 -0
  69. package/dist/tools/works.js.map +1 -1
  70. package/dist/tools/wrapped-args-envelope.d.ts +58 -0
  71. package/dist/tools/wrapped-args-envelope.d.ts.map +1 -0
  72. package/dist/tools/wrapped-args-envelope.js +66 -0
  73. package/dist/tools/wrapped-args-envelope.js.map +1 -0
  74. package/package.json +17 -3
  75. package/server.json +2 -2
package/CHANGELOG.md CHANGED
@@ -11,6 +11,111 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
11
11
 
12
12
  ## [Unreleased]
13
13
 
14
+ ## [2.97.1] - 2026-09-08
15
+
16
+ ### Added
17
+
18
+ - **`pica_catalog_health_fix` accepts `selections: [{actionId, chosenPersonId}]`**
19
+ — the human choice a `resolve_person` action needs (one of its
20
+ `preview.candidates[].personId`). A selection accepts its action; a choice
21
+ the plan never offered is skipped `guard_blocked` with the reason. Until now
22
+ the applier required a chosen person the tool had no way to pass, so every
23
+ accepted `resolve_person` came back `stale` (feedback 2026-09-05).
24
+ - **`pica_find_duplicates` sees identifier-less copies.** Recordings group on
25
+ title + artist and releases on title + equal track count when the ISRC/UPC
26
+ pass cannot see them (`match_kind: "title_artist"`, keep-separate default);
27
+ a UPC shared by releases with different titles is reported as
28
+ `shared_upc_different_title` — the decision is "correct the UPC", with no
29
+ fold option (feedback 2026-09-05).
30
+
31
+ ### Fixed
32
+
33
+ - **`pica_works_update {collaborators}` is refused with a redirect** to
34
+ `pica_credits_update` / `pica_credit_add`. `works.collaborators` is a
35
+ legacy jsonb mirror; the write showed correct splits on inspect while the
36
+ `work_collaborators` rows every health check reads still disagreed, and the
37
+ health plan then proposed "fixing" them (feedback 2026-09-05).
38
+ - **Accepting a held finding is a typed 409, not `INTERNAL_ERROR`.** The
39
+ apply route now maps every "is already <status>" refusal to
40
+ `PROPOSAL_ALREADY_CLOSED`, and a held one carries the unlock sentence
41
+ (`pica_billing_pay`, offer `unlock`, `entity_id` the work) — a ChatGPT user
42
+ hit "internal server error" three times on 2026-09-04.
43
+ - **`pica_credit_add` never invents a share.** An omitted `share_pct` on a
44
+ composition credit is stored as NULL (unknown), not 0 — a 0 read as a real
45
+ share, so the health plan rescaled the other writer to 100 and the second
46
+ writer's stake vanished (holdout lock, 2026-09-06). For `credit_type:
47
+ "owner"` the share is now REQUIRED (`OWNER_SHARE_REQUIRED`, 422): master
48
+ ownership is recorded as given, never assumed to be 100.
49
+ - **`pica_releases_update` documents the UPC backfill trigger** — it fires
50
+ only on a write to `spotify_album_id`, so re-sending the existing id is the
51
+ way to backfill a UPC (ops issue 9f33cc59).
52
+
53
+ - **`pica_subscription_status` is callable on the hosted connector.** It was
54
+ declared `scope: admin`, `audiences: ["stdio"]` while `pica_billing_pay` was
55
+ `read:catalog` on both surfaces, so a connected agent could mint a pay link
56
+ but not read the plan it would be paying for (`callable_on_this_surface:
57
+ false` on claude.ai, 2026-09-04). Both now share the catalogue-read floor;
58
+ `pica_subscription_manage` stays stdio + admin.
59
+ - **The pay path is visible to an agent that never calls `pica_discover`.**
60
+ The server instructions name `pica_subscription_status` and
61
+ `pica_billing_pay` with the exact `pica_execute` shape inside the first
62
+ 2,000 characters (the observed cut on the claude.ai connector), and the
63
+ `pica_discover` description lists "how do i pay pica" among its example
64
+ queries for clients that surface tool descriptions but not instructions.
65
+
66
+ PR #2118 (`fix/avatar-import-path-2026-09-03`) is merged into the release branch, so its changes ship in the version below; publish in the order mcp-utils → mcp-sdk → mcp-server.
67
+
68
+ ## [2.97.0] - 2026-09-04
69
+
70
+ ⚠️ Publish order: `@withpica/mcp-sdk` 3.14.0 and `@withpica/mcp-utils` 1.29.0
71
+ must be on npm before this release — the dependency floors are now
72
+ `^3.14.0` / `^1.29.0` (this release imports `pageEnvelope`, which only
73
+ exists from mcp-utils 1.29.0; a clean install against 1.28.0 breaks at
74
+ runtime — the 2.96.2 uninstallable incident).
75
+
76
+ ### Added
77
+
78
+ - `pica_multimedia_import_url` accepts `person_id` (sets the person's profile image) and its summary names the outcome — `Imported from URL (via)`, profile-image set/NOT set, work link (PR #2118, merged into this release). Page URLs are followed to their `og:image`.
79
+
80
+ - **Per-tool argument aliasing for `pica_execute`** (`arg-aliases.ts`, D1
81
+ 2026-09-03) — `applyArgAliases` renames a tool's OWN entity id (or an
82
+ explicit `TOOL_ARG_ALIASES` entry, e.g. `pica_skill_get`'s `skill` /
83
+ `skill_name`) to the schema's real required field name, structurally by
84
+ domain (`DOMAIN_ID_ALIASES`) — never a foreign entity's id, never
85
+ overwriting a value already present, and left untouched when more than
86
+ one candidate is present. Fixes the wrong diagnosis `pica_execute` gave in
87
+ all 36 logged cases since July, where an agent sent e.g. `audio_file_id`
88
+ to `pica_audio_update` and was told the client had dropped the field in
89
+ transit.
90
+ - **Shared `WRAPPED_ARGS_MISSING` envelope builder**
91
+ (`wrapped-args-envelope.ts`) — both guards that can reject a
92
+ `pica_execute` call before dispatch (the plain `required`-list guard, and
93
+ the `requiredOneOf` one-of-N guard covering `*_inspect` / `pica_search` /
94
+ bookings / licensing / shows / royalties tools) now build their message
95
+ and `structuredContent` through one function, naming
96
+ `unrecognised_fields` and `aliases_applied` in **both** the text block and
97
+ `structuredContent` instead of asserting "client-side transport loss" for
98
+ a non-empty args object. Empty args still name transport loss — there's
99
+ nothing else an empty resolved-args object could be.
100
+ - **`offset` on `pica_audio_query`, `pica_notes_query`, `pica_sessions_query`**
101
+ (Task 10), each returning a `page` envelope built with
102
+ `@withpica/mcp-utils`'s `pageEnvelope()`. Audio and sessions fall back to
103
+ "page was full" (no total available); notes uses the route's real
104
+ `COUNT` for an exact `has_more`. A new `query-offset-parity` registry
105
+ guard test pins which remaining `_query` tools still lack `offset` so
106
+ each can be fixed and measured in isolation.
107
+
108
+ ### Changed
109
+
110
+ - **Duplicate-release recovery hints point at a fix, not a dead end.**
111
+ `RELEASE_ALREADY_EXISTS` on `pica_releases_create` /
112
+ `pica_releases_create_with_tracks` now names `pica_releases_update` /
113
+ `pica_releases_attach_track` (the message already carries the existing
114
+ release's id) instead of `pica_releases_query`; `pica_releases_attach_track`'s
115
+ own `RELEASE_ALREADY_EXISTS` (a different release already holds the UPC)
116
+ points at `pica_releases_inspect`.
117
+ - **Deprecated alias removal deferred to 2.98.0** — see `metadata.ts`.
118
+
14
119
  ## [2.96.2] - 2026-09-02
15
120
 
16
121
  The MPP pay rail (spec 2026-08-24 WS-B): a new tool that mints a pay link,
package/README.md CHANGED
@@ -65,7 +65,7 @@ Read tools are annotated read-only and are safe to call freely. Write tools repo
65
65
 
66
66
  ## Tools
67
67
 
68
- 330 tools, grouped below by the taxonomy `pica_discover` uses. The server's own `tools/list` is authoritative — not every registered tool is filed under a category yet, so the names below are a map, not a census.
68
+ 335 tools, grouped below by the taxonomy `pica_discover` uses. The server's own `tools/list` is authoritative — not every registered tool is filed under a category yet, so the names below are a map, not a census.
69
69
 
70
70
  **works** — manage your musical works
71
71
 
@@ -235,6 +235,10 @@ Read tools are annotated read-only and are safe to call freely. Write tools repo
235
235
 
236
236
  `pica_royalties_summary`, `pica_royalties_list`, `pica_royalties_get`, `pica_statements_query`, `pica_statements_inspect`, `pica_ingest_statement`, `pica_statements_pending`, `pica_statement_ingest_document`, `pica_royalties_unmatched`, `pica_royalties_attribute`
237
237
 
238
+ **selections** — save, recall, and resolve named catalog selections — persisted predicates over the catalogue with an honest coverage report
239
+
240
+ `pica_selections_create`, `pica_selections_query`, `pica_selections_inspect`, `pica_selections_update`, `pica_selections_delete`
241
+
238
242
  **share links** — create, inspect, update, and delete share links for catalog content
239
243
 
240
244
  `pica_share_links_create`, `pica_share_links_query`, `pica_share_links_inspect`, `pica_share_links_update`, `pica_share_links_delete`
@@ -285,4 +289,4 @@ Read tools are annotated read-only and are safe to call freely. Write tools repo
285
289
 
286
290
  ---
287
291
 
288
- Generated for `@withpica/mcp-server@2.96.2`. © 2024-2026 Withpica Ltd. All rights reserved. MIT licensed.
292
+ Generated for `@withpica/mcp-server@2.97.0`. © 2024-2026 Withpica Ltd. All rights reserved. MIT licensed.