Skip to content

Send a default User-Agent on remote MCP requests - #2254

Merged
RhysSullivan merged 1 commit into
mainfrom
mcp-user-agent
Oct 10, 2026
Merged

RhysSullivan merged 1 commit into
mainfrom
mcp-user-agent

Conversation

@RhysSullivan

@RhysSullivan RhysSullivan commented Oct 10, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Remote MCP requests (Streamable HTTP and SSE) had no User-Agent when the runtime's fetch adds none, as on Cloudflare Workers. Some servers behind Cloudflare answer those with a 403 challenge. This adds User-Agent: executor to the transport's requestInit headers when none is configured, matching the OpenAPI plugin. The SDK applies those headers to every transport request and to OAuth metadata discovery, with or without the HTTP client layer. A configured User-Agent still wins.

Tests are in #2255.

Verification

  • bun run lint, bun run format:check, MCP plugin typecheck and vitest run pass.

@RhysSullivan
RhysSullivan added this pull request to stack #2256 October 10, 2026 16:34
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
executor-marketing 675213b Commit Preview URL

Branch Preview URL
Oct 10 2026, 04:36 PM

@github-actions

github-actions Bot commented Oct 10, 2026 •

Copy link
Copy Markdown
Contributor

Cloudflare preview

Torn down — the PR is closed.

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
executor-cloud 675213b Oct 10 2026, 04:36 PM

@pkg-pr-new

pkg-pr-new Bot commented Oct 10, 2026

Copy link
Copy Markdown

Open in StackBlitz

@executor-js/cli

npm i https://pkg.pr.new/@executor-js/cli@2254

@executor-js/config

npm i https://pkg.pr.new/@executor-js/config@2254

@executor-js/execution

npm i https://pkg.pr.new/@executor-js/execution@2254

@executor-js/sdk

npm i https://pkg.pr.new/@executor-js/sdk@2254

@executor-js/codemode-core

npm i https://pkg.pr.new/@executor-js/codemode-core@2254

@executor-js/runtime-quickjs

npm i https://pkg.pr.new/@executor-js/runtime-quickjs@2254

@executor-js/plugin-file-secrets

npm i https://pkg.pr.new/@executor-js/plugin-file-secrets@2254

@executor-js/plugin-graphql

npm i https://pkg.pr.new/@executor-js/plugin-graphql@2254

@executor-js/plugin-keychain

npm i https://pkg.pr.new/@executor-js/plugin-keychain@2254

@executor-js/plugin-mcp

npm i https://pkg.pr.new/@executor-js/plugin-mcp@2254

@executor-js/plugin-onepassword

npm i https://pkg.pr.new/@executor-js/plugin-onepassword@2254

@executor-js/plugin-openapi

npm i https://pkg.pr.new/@executor-js/plugin-openapi@2254

executor

npm i https://pkg.pr.new/executor@2254

commit: 675213b

@RhysSullivan
RhysSullivan marked this pull request as ready for review October 10, 2026 16:43
@RhysSullivan
RhysSullivan merged commit 6e768da into main Oct 10, 2026
43 of 44 checks passed
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.

1 participant