Skip to content

'Content-Type must be 'application/json' - when setting charset #2333

@pedrobrasilborges

Description

@pedrobrasilborges

Describe the bug

I'm using the https://github.com/modelcontextprotocol/csharp-sdk for MCP integration and when sending the initial POST it adds the Content-Type as "application/json; charset=utf-8" and the server replies with 'Content-Type must be 'application/json' , while reduntant due to RFC 8259, it should just be stripped instead of enforced. This was working previously working.

Affected version

Remote version of Github MCP Server.

Steps to reproduce the behavior

Working:

Image

Non-Working:

Image

Expected vs actual behavior

Expected -> ability to initialize the McpClient
Actual -> throws exceptions

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions