mcp-agent
mcp-agent copied to clipboard
Allow passing headers to SSE server
I have a use-case to pass some headers to the SSE server. The sse_client from mcp.client.sse.sse_client accepts headers in its function signature. Would you be comfortable with adding configurable headers to the config for an sse mcp server? I tried to just put the data I need to pass in the route, like http://mc-server/dataineedtopass/sse. And it works fine, but when the library connects to /messages/ it completely ignores the /dataineedtopass/ part and doesn't preserve it.
I would implement it if you give the goahead.