fix(server): work around Claude Desktop JSON Schema dialect rejection - #42
Merged
antonisobkowicz-asana merged 2 commits intoSep 8, 2026
Merged
Conversation
…patibility @modelcontextprotocol/sdk (1.30.0, latest) always advertises tool schemas with $schema: draft-07, since its tools/list handler never passes a target to the schema converter. Claude Desktop's tool runner only accepts JSON Schema 2020-12 and rejects every call as a result. Wrap the transport's send to relabel the dialect in transit until the upstream fix (modelcontextprotocol/typescript-sdk#2084, #2721) lands in a release; safe here since this server never emits tuple-style items arrays, the one keyword that differs between the two dialects. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This test runs install.sh three times in a row (fresh install, upgrade, no-op rerun), which was intermittently exceeding vitest's default 5s timeout on a loaded machine. No other installer test invokes the script more than twice. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
antonisobkowicz-asana
deleted the
fix/claude-desktop-json-schema-dialect
branch
September 8, 2026 07:59
4 tasks
antonisobkowicz-asana
added a commit
that referenced
this pull request
Sep 8, 2026
## Summary - Bumps `package.json`/`package-lock.json` to 0.4.1 to release the Claude Desktop JSON Schema dialect workaround (#42). ## Test plan - [x] `npm ci` - [x] `npm run check` (typecheck, lint, 380 tests, build) — all passing - [x] `npm audit` — 0 vulnerabilities - [x] `npm pack --dry-run` — tarball contents look correct 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
get_context,search_tickets,list_workspaces, ...) because@modelcontextprotocol/sdk(1.30.0, latest) always advertisestools/listschemas with$schema: draft-07— its handler never passes atargetto the schema converter. Claude Desktop's tool runner only accepts JSON Schema 2020-12.modelcontextprotocol/typescript-sdk#2084and#2721, both open; proposed fixes#2085/#2653not yet merged/released).applyJsonSchemaDialectWorkaround, which wraps the transport'ssendto relabel the declared dialect from draft-07 to 2020-12 in transit, wired intocli.tsright beforeserver.connect(). Safe here because this server never emits tuple-styleitemsarrays — the one keyword whose meaning differs between the two dialects. Marked with aTODOto delete once a released SDK version fixes this upstream.install.shthree times end-to-end (fresh install, upgrade, no-op rerun) — it was intermittently exceeding vitest's default 5s timeout on a loaded machine.Test plan
npx tsc --noEmitnpm run lintnpx vitest run— 380 tests passing, including new coverage for the workaround (dialect relabeling, non-tools/list messages passed through untouched, wiring throughrunCli)🤖 Generated with Claude Code