Repository navigation
Releases
v0.5.5 - Recover proxied OAuth sessions and stabilize stream cancellation
Fixes OAuth recovery and stream cancellation for proxied connections.
v0.5.4 — Accept fragmented chunked responses
Valid chunked HTTP responses are no longer reported as premature closes when their final marker is split across multiple socket events. This includes 3+1+1 splits and empty data events. Genuinely truncated responses still fail.
The corrected detector ships in both proxy entry bundles, allowing wrappers to consume the package without applying their own compiled-bundle workaround.
After upgrading, sign in once again. OAuth credentials are stored by proxy version. Node.js 18 or newer is required.
Fix by @Michelleeby; release preparation by @galatanovidiu.
Full comparison: v0.5.3...v0.5.4
v0.5.3 — Refresh tokens and coordinate OAuth sign-ins
This release refreshes expired OAuth tokens and shares authorization across concurrent proxy processes, reducing repeated browser sign-ins.
After upgrading, sign in once again. Credentials are stored by proxy version, so this release uses a new token directory. Node.js 18 or newer is required.
- Refresh expired tokens and save rotated credentials atomically. Temporary refresh failures preserve saved credentials instead of immediately opening a browser.
- Coordinate sign-in and rejected-token recovery across processes, so concurrent clients reuse the resulting credentials.
- Validate authorization-server metadata, bind credentials to their issuer, and handle MCP authentication challenges and scope upgrades.
- Validate callback state, issuer, and origin, and report callback errors promptly.
Changes: #143 and #144 by @galatanovidiu.
Full comparison: v0.5.2...v0.5.3
v0.5.2 — Re-authenticate after a revoked token, quieter startup
Patch release with four fixes. The token store is namespaced by package version, so users authenticate again after upgrading.
Fixed
- When WordPress rejects the stored OAuth token before its local expiry, the proxy opens the sign-in page and retries once with the new token instead of failing on every start. Only a 401 that refuses a bearer token triggers this; a 401 asking for other credentials is reported as before. (#136, #141)
- The OAuth callback server fails startup when its port is already taken instead of opening a browser tab that redirects to a dead port. (#138)
- Startup no longer logs
WordPress transport errorwithInvalid state: Controller is already closedorThis operation was abortedwhen the SDK releases unread response bodies or aborts the event stream on close. (#140)
Changed
- The MCP SDK dependency moved from 1.26.0 to 1.31.0. (#131)
Full changelog: v0.5.1...v0.5.2
Contributors
- @gavande1 — re-sign-in after a rejected token (#136)
- @galatanovidiu — callback port failure (#138), quieter startup (#140), Bearer challenge guard (#141), release (#142)
- @dependabot — MCP SDK update (#131)
v0.5.1 — Proxy environment variables work without USE_SYSTEM_PROXY
Proxy environment variables now work on their own. Before, SOCKS_PROXY, HTTPS_PROXY, ALL_PROXY and HTTP_PROXY were ignored unless USE_SYSTEM_PROXY=true was also set, so on a network that requires a proxy the connection timed out and the client saw no tools.
Upgrade notes
- Proxy variables in your environment now apply. If
HTTPS_PROXYorHTTP_PROXYis set in the environment that launches the proxy, for example for other tools, WordPress requests now go through that proxy as well. Add hosts toNO_PROXYto connect to them directly. (#133) - The token store is namespaced by package version, so upgrading to 0.5.1 requires users to authenticate again.
Fixed
SOCKS_PROXY,HTTPS_PROXY,ALL_PROXYandHTTP_PROXYroute requests withoutUSE_SYSTEM_PROXY.USE_SYSTEM_PROXY=truenow only enables detection of the macOS system PAC file or SOCKS proxy, which is used when none of those variables is set.NO_PROXYworks as before. (#133)
Documentation
- The README documents the proxy variables and explains when to connect a client to WordPress directly instead of using the proxy. (#132, #133)
Full changelog: v0.5.0...v0.5.1
v0.5.0 — Pass-through proxy and 2026-07-28 support
The proxy now forwards MCP traffic between the client and WordPress unchanged, instead of running its own MCP server in between. The client and WordPress negotiate the protocol version directly, so newer clients, including 2026-07-28, work through the proxy. This release also fixes OAuth with a dynamically selected callback port, bounds OAuth and PAC waits, and identifies the client in the User-Agent.
Breaking changes
- Only standard MCP Adapter endpoints are supported. The simple-format protocol of the archived
wordpress-mcpplugin, and the automatic fallback to it, are removed. A bare-domainWP_API_URL(for examplehttps://example.com) now resolves to/?rest_route=/mcp/mcp-adapter-default-serverinstead of/wp/v2/wpmcp. A full endpoint URL is still used exactly as given. (#121) - Expired sessions are passed to the client. If WordPress rejects the session, the client gets the error instead of the proxy re-running
initializeon its own. (#121) /lib: theuseJsonRpcargument ofwpRequestis ignored, because every request is now JSON-RPC. While the proxy runs,wpRequestand tool-call hooks use the proxy's own connection. (#121)/lib: the minimum@modelcontextprotocol/sdkversion is now^1.26.0. (#121)
Upgrade notes
- The token store is namespaced by package version, so upgrading from 0.4.x to 0.5.0 requires users to authenticate again.
- With the implicit OAuth flow, the browser login must now finish within
OAUTH_TIMEOUT_MS(default 30 seconds), the same limit the PKCE flow already used. Before, the implicit flow waited up to 5 minutes. (#104)
Changed
- Pass-through forwarding. Messages,
_meta, request ID0, unknown methods and server-to-client requests reach the other side unchanged. The proxy reads theinitializeresponse only to send the negotiatedMCP-Protocol-Versionand the session ID on later requests. This fixes requests failing afterinitializeagainst MCP Adapter 0.7.0 because of a fixedMCP-Protocol-Version: 2025-06-18header (#120). (#121) 2026-07-28HTTP headers. For2026-07-28requests, the proxy buildsMCP-Protocol-Version,Mcp-Method,Mcp-NameandMcp-Param-*from the message body. It learnsx-mcp-headertool annotations from thetools/listresults it forwards. Anotifications/cancelledfor a pending2026-07-28request closes that request's HTTP stream. (#121)- User-Agent. Requests to WordPress and the OAuth endpoints now send
User-Agent: <client>/<version> mcp-wordpress-remote/<version>, with the client taken from its MCPclientInfo, instead of Node's defaultnode. AUser-AgentinCUSTOM_HEADERSstill takes precedence. (#128, closes #111)
Fixed
- OAuth with a dynamic callback port. Client registration and the token exchange now use the port the callback server actually listens on, instead of a
:0placeholder that authorization servers rejected. A failed authorization attempt now releases the callback port, so the next attempt can start. (#108) - Implicit OAuth no longer blocks
initializefor 5 minutes when the browser callback never arrives, for example in a headless environment. The client gets theconnectionFailedfallback response withinOAUTH_TIMEOUT_MS. Waiting behind another process's auth lock uses the same limit. (#104, closes #103) - PAC loading is bounded. On macOS, an unreachable PAC URL no longer stalls startup. The download gives up after
PROXY_PAC_TIMEOUT_MS(default 5000) and the proxy falls back to the system SOCKS proxy or a direct connection. (#129) - JSON-RPC errors that WordPress returns with a non-2xx HTTP status now reach the client as normal error responses. (#121)
New configuration
OAUTH_TIMEOUT_MS: time to wait for the browser OAuth login (default30000). (#104, #127)PROXY_PAC_TIMEOUT_MS: timeout for the PAC download and resolver setup (default5000). (#129)
Dependencies were updated through Dependabot (#110, #112, #113, #114, #117, #118, #119, #122, #123, #124, #125, #126).
Contributors
Thanks to everyone who contributed to this release:
- @galatanovidiu: pass-through proxy (#121), User-Agent (#128), follow-ups (#127, #129)
- @lezama: OAuth callback port fix (#108)
- @erikiva: callback port selection before client registration and tests (#108)
- @chubes4: bounded implicit OAuth waits (#104) and the report in #103
- @Michelleeby: PAC timeout (#129, from #116)
And to the people who reported issues fixed here: @lhero-org (#120) and @alisadiq90 (#111).
Full changelog: v0.4.0...v0.5.0
v0.4.0 — Post-tool-call hooks for embedding packages
Added: post-tool-call hooks for embedding packages (#92)
Embedding packages can now register registerToolCallHook from @automattic/mcp-wordpress-remote/lib to run best-effort side effects after a tool call completes while reusing the proxy's authenticated WordPress request context. Hook failures are isolated, so telemetry or auditing integrations cannot delay or break the original tool call.
Upgrade note
The token store is namespaced by package version. Upgrading from 0.3.x to 0.4.0 requires users to authenticate again.
Full changelog: v0.3.5...v0.4.0
v0.3.5
Fix: reuse persisted OAuth DCR client registration (#80)
The proxy was re-registering a new Dynamic Client Registration (DCR) client on every connect, causing OAuth flows to accumulate stale registrations and occasionally fail on stricter servers. The proxy now reuses the persisted client registration when one exists, only re-registering if the stored credentials are missing or invalid.
Fix: MCP_WORDPRESS_REMOTE_VERSION constant not bumped (#85)
`serverInfo.version` in MCP `initialize` responses was reporting `0.3.4` instead of `0.3.5` due to a hardcoded version constant in `config.ts` that was missed during the release bump.
Full changelog: v0.3.4...v0.3.5
v0.3.4
Fix: prefer explicit proxy env vars over macOS system proxy (#78)
An explicit SOCKS_PROXY / HTTPS_PROXY / ALL_PROXY / HTTP_PROXY now takes precedence over the auto-detected macOS system PAC.
Before this release, the system PAC was consulted first and could synthesize a socks5h:// proxy (DNS resolved at the proxy), silently overriding an operator's explicit socks5:// (client-side DNS). The reorder restores client-side DNS when the operator asks for it, which also lets local /etc/hosts entries be honored. Default behavior with no explicit env var is unchanged: PAC still wins and still forces socks5h://.
Full changelog: v0.3.3...v0.3.4
v0.3.3
Everything merged since 0.3.1 (0.3.2 was tagged but never published, so its changes ship here too).
Connection-failure handling (#61, #76)
- Failures are no longer silent. ERROR-level logs always reach stderr with the underlying code and an actionable hint (TLS trust, DNS, refused, timeout).
- No more faked success. A failed
initializereturns a degraded result advertising onlyexperimental.connectionFailed, so SDK clients complete the handshake and can detect the degraded state; later calls return a structured JSON-RPC error withdata(reason,code,detail,hint). - Bounded handshake — no ~60s hang. Requests use
AbortSignal.timeout:WP_API_INIT_TIMEOUT_MS(default 25s) forinitialize,WP_API_TIMEOUT_MS(default 120s) for tool calls. Timeouts skip the simple-transport fallback so a stalled upstream fails once, not twice. - Faithful error forwarding. WordPress JSON-RPC error codes pass through unchanged (e.g.
-32602stays-32602); HTTP-status errors map to sensible MCP codes (401 → -32010). Previously everything flattened to-32603. - TLS docs. Recommends
NODE_EXTRA_CA_CERTS/NODE_USE_SYSTEM_CAfor locally-trusted CAs (mkcert/DDEV/corporate/VPN);NODE_TLS_REJECT_UNAUTHORIZED=0only as an insecure last resort.
Other fixes
- Logging: preserve the
Errormessage and stack in log output — errors previously serialized to{}, hiding the real cause (#75). - SOCKS proxy: synthesized SOCKS proxy URLs now use
socks5h://(remote DNS resolution), fixing IPv6 SOCKS proxy handling (#63).
Dependencies
- Bump
@modelcontextprotocol/sdk1.10.1 → 1.26.0 (#72). - Dependabot security & maintenance updates: rollup → 4.61.0 (#71), js-yaml → 3.14.2 (#73), ip-address → 10.2.0 (#69), tmp → 0.2.6 (#66), picomatch → 2.3.2 (#70), path-to-regexp/express, minimatch, playwright (dev), and grouped updates (#65, #68, #74).
Maintenance
- Realign
MCP_WORDPRESS_REMOTE_VERSION(proxy's reportedserverInfo.version) with the package version; it had drifted to 0.3.0 (#77).
New environment variables
WP_API_INIT_TIMEOUT_MS(default25000)WP_API_TIMEOUT_MS(default120000)LOG_TO_STDERR(defaultfalse; ERROR-level logs always go to stderr)
Validation
Unit/integration tests, a local stub harness, a real WordPress.com endpoint (OAuth + SOCKS), MCP Inspector, and clean-environment release probes.
Contributors
- @galatanovidiu — connection-failure handling (#76), logging fix (#75), release (#77)
- @luismulinari — SOCKS5h IPv6 fix (#63)
Dependency updates via Dependabot.
Thanks to @adamslowe for the detailed report in #61, and @NigelAmyes for additional reproduction details.
Full changelog: v0.3.1...v0.3.3