Skip to content

feat(MCP Client Tool Node): Add support for HTTP Streamable Transport - #15454

Merged
RomanDavydchuk merged 5 commits into
n8n-io:masterfrom
KGuillaume-chaps:master
Jul 18, 2025
Merged

feat(MCP Client Tool Node): Add support for HTTP Streamable Transport#15454
RomanDavydchuk merged 5 commits into
n8n-io:masterfrom
KGuillaume-chaps:master

Conversation

@KGuillaume-chaps

Copy link
Copy Markdown
Contributor

Summary

This PR adds support for the now recommended HTTP Streamable Transport for the MCP Protocol.

It also keeps the compatibility with the deprecated SSE transport, in order to not break existing instances.

Related Linear tickets, Github issues, and Community forum posts

Review / Merge checklist

  • PR title and summary are descriptive. (conventions)
  • Docs updated or follow-up ticket created.
  • Tests included.
  • PR Labeled with release/backport (if the PR is an urgent fix that needs to be backported)

@CLAassistant

CLAassistant commented May 16, 2025

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mrge found 2 issues across 1 file. Review them in mrge.io

Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/utils.ts
requestInit: { headers },
});
await client.connect(transport);
console.log('Connected using Streamable HTTP transport');

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using console.log instead of the logger system that's used elsewhere in the codebase

@n8n-assistant n8n-assistant Bot added community Authored by a community member in linear DEPRECATED labels May 16, 2025
@Joffcom

Joffcom commented May 16, 2025

Copy link
Copy Markdown
Member

Hey @KGuillaume-chaps,

Thanks for the PR, We have created "GHC-2033" as the internal reference to get this reviewed.

One of us will be in touch if there are any changes needed, in most cases this is normally within a couple of weeks but it depends on the current workload of the team.

@bholagabbar

Copy link
Copy Markdown

I'd wager this is the highest requested feature ? I don't see a lot of registries supporting SSE anymore, would be great to have Streaming HTTP support in soon!

@netroy

netroy commented May 26, 2025

Copy link
Copy Markdown
Contributor

I'd wager this is the highest requested feature ?

It has 123 votes. So, definitely not in the top 10 most requested features.

I don't see a lot of registries supporting SSE anymore

Do you have source for that claim?
The official registry repo still supports SSE.
plus, SSE transport is deprecated, and not actually removed.

Considering how the Websocket transport was initially implemented in the MCP SDK and then dropped without any serious community conversation around it, I'd suggest that everyone working on this to go slowly, not surrender to the MCP mania, and avoid rushing MCP related features at a priority, to avoid maintainer burnout 🙏🏽.

I'll bring this PR up internally to see if someone can review this as soon as there is someone available.

@bholagabbar

Copy link
Copy Markdown

@netroy appreciate you escalating this internally!

But this feels like a pretty out-of-touch take. SSE might be “technically” supported, but top registries like smithery.ai have already moved to streaming HTTP — and do not support SSE.

And let’s be honest — citing “maintainer burnout” when n8n has raised $60M+ doesn’t hold water. This isn’t a volunteer project. If community-backed protocol features like MCP streaming are being stalled, that’s a product/org decision — not a resourcing issue.

Streaming HTTP is where the ecosystem’s going. Happy to be proven wrong if you can point to any robust registry still backing SSE at scale. I don't need to cite data sources to prove my point, my anecdotal evidence is already reflected on your community threads.

Thanks again for pushing this forward.

@jezweb

jezweb commented May 27, 2025

Copy link
Copy Markdown

Yep I agree, this is needed else n8n will become much less useful as a backend for ai apps.

@mrgoonie

mrgoonie commented Jun 3, 2025

Copy link
Copy Markdown

@netroy it's a top 3 most voted feature now

@netroy

netroy commented Jun 3, 2025

Copy link
Copy Markdown
Contributor

Streamable HTTP transport support is already being added for servers here.
The team will get to the Client support right after that.

@netroy

netroy commented Jun 3, 2025

Copy link
Copy Markdown
Contributor

also, please don't @ mention to summon me, unless I am somehow the only one that can help 🙏🏽 .

@ShireenMissi ShireenMissi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @KGuillaume-chaps for the PR 🙏
I left some comments. also please add test for the changed lines pf code

Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/utils.ts Outdated
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/utils.ts Outdated
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/utils.ts Outdated
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/utils.ts Outdated
@KGuillaume-chaps

Copy link
Copy Markdown
Contributor Author

I'm not sure what to test for or how to run the test suite.

On my machine running npm run test fails with the following message :

image

@EdouardCourty

EdouardCourty commented Jun 23, 2025

Copy link
Copy Markdown

Hi there, I've been running my production cluster on this branch for the past weeks, can't wait for it to be merged 🙏

@pgrimaud

Copy link
Copy Markdown

Looks great, thanks for the contribution! 🙌 Hope to see it merged soon. 🚀

@xindoo

xindoo commented Jun 28, 2025

Copy link
Copy Markdown

Looking forward to getting this merged

@anand-chandrashekar

Copy link
Copy Markdown

👍 Please do consider prioritizing this request.

@dangaiden

Copy link
Copy Markdown

Looking forward to this feature to be released!

@grantmagdanz

Copy link
Copy Markdown

Excited for this to get in :)

@vladzloteanu

Copy link
Copy Markdown

Excellent, will update my n8n in the next minutes this gets released! :)

@tiagorgt

tiagorgt commented Jul 8, 2025

Copy link
Copy Markdown

I'm looking forward to it

@rfiala

rfiala commented Jul 9, 2025

Copy link
Copy Markdown

any ETA when this will be merged? thinking about self-hosting n8n and using a non-verified community node. However i would ideally want to avoid this.

@ferrants

Copy link
Copy Markdown

@rfiala , which community node are you considering for this? me too.

also considering running off of this branch to give some evidence that this is ready to merge

@rfiala

rfiala commented Jul 11, 2025

Copy link
Copy Markdown

@rfiala , which community node are you considering for this? me too.

also considering running off of this branch to give some evidence that this is ready to merge

i just moved to a self-hosted instance and installed this one:
https://github.com/nerding-io/n8n-nodes-mcp

however i feel this is not exactly what i need as i need to add an explicit "execute tool" method for every tool available which i find weird. i thought it would work exactly the same as the mcp client on n8n where the agent decides which tool it is using

@RomanDavydchuk
RomanDavydchuk requested review from RomanDavydchuk and removed request for elsmr July 14, 2025 16:18
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/McpClientTool.node.ts Outdated
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/utils.ts

@RomanDavydchuk RomanDavydchuk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for incorporating the changes I've requested! I took another look and tested the code manually, looks like it works, good job. There are just a few more small changes I'd like you to make, once those are in, I think this can be merged

Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/loadOptions.ts Outdated
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/McpClientTool.node.ts Outdated
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/utils.ts Outdated
Comment thread packages/@n8n/nodes-langchain/nodes/mcp/McpClientTool/McpClientTool.node.ts Outdated
@anand-chandrashekar

Copy link
Copy Markdown

We are cheering you guys on @KGuillaume-chaps , @RomanDavydchuk . Thank you!

@KGuillaume-chaps

Copy link
Copy Markdown
Contributor Author

All the linting issues should be fixed :)

@RomanDavydchuk RomanDavydchuk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@RomanDavydchuk
RomanDavydchuk merged commit a5d14a2 into n8n-io:master Jul 18, 2025
14 checks passed
@github-actions github-actions Bot mentioned this pull request Jul 21, 2025
@janober

janober commented Jul 21, 2025

Copy link
Copy Markdown
Member

Got released with n8n@1.104.0

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

Labels

community Authored by a community member in linear DEPRECATED Released

Projects

None yet

Development

Successfully merging this pull request may close these issues.