Skip to content

Conversation

@mattzcarey
Copy link
Contributor

@mattzcarey mattzcarey commented Jan 9, 2026

closes #1356

Motivation and Context

How Has This Been Tested?

Breaking Changes

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update

Checklist

  • I have read the MCP Documentation
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have added or updated documentation as needed

Additional context

@mattzcarey mattzcarey requested a review from a team as a code owner January 9, 2026 11:59
@changeset-bot
Copy link

changeset-bot bot commented Jan 9, 2026

🦋 Changeset detected

Latest commit: 17d8fd3

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@modelcontextprotocol/server Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new
Copy link

pkg-pr-new bot commented Jan 9, 2026

Open in StackBlitz

npm i https://pkg.pr.new/modelcontextprotocol/typescript-sdk/@modelcontextprotocol/client@1373
npm i https://pkg.pr.new/modelcontextprotocol/typescript-sdk/@modelcontextprotocol/server@1373

commit: 17d8fd3

@mattzcarey mattzcarey changed the title Fix-json-header-notifs fix(server): application/json header for notifictions Jan 9, 2026
@DePasqualeOrg
Copy link

@mattzcarey, I'm curious about the reasoning for this, since I'm referring to the TypeScript SDK in my development of this Swift SDK. Since notification responses have an empty body, specifying a content type seems unnecessary, and it isn't mentioned in the spec. The TypeScript SDK also doesn't include a content type for DELETE 200 responses. Are there clients that expect this in practice?

@mattzcarey
Copy link
Contributor Author

@mattzcarey, I'm curious about the reasoning for this, since I'm referring to the TypeScript SDK in my development of this Swift SDK. Since notification responses have an empty body, specifying a content type seems unnecessary, and it isn't mentioned in the spec. The TypeScript SDK also doesn't include a content type for DELETE 200 responses. Are there clients that expect this in practice?

Hey this closed an issue which was effecting people using the Java client. Please see the issue this closed

@mattzcarey
Copy link
Contributor Author

Happy to revisit this if you think it was misplaced.

@DePasqualeOrg
Copy link

It looks like the Java client now handles the previous (correct) behavior of the TypeScript HTTP server correctly and will log a warning about a non-compliant response with the new behavior from this PR.

So unless I'm misunderstanding something, this should probably be reverted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SHOULD Send with 'application/json' content-type in notifications responses

4 participants