feat: enums connection state and standardise tool discovery#26690
Closed
agents-git-bot[bot] wants to merge 1 commit into
Closed
feat: enums connection state and standardise tool discovery#26690agents-git-bot[bot] wants to merge 1 commit into
agents-git-bot[bot] wants to merge 1 commit into
Conversation
agents-git-bot
Bot
requested review from
elithrar,
irvinebroque,
rita3ko,
thomasgauvin and
threepointone
as code owners
November 21, 2025 18:49
Contributor
|
This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:
|
agents-git-bot
Bot
force-pushed
the
sync-docs-pr-672
branch
from
November 21, 2025 18:54
c0ca5d7 to
7f9565b
Compare
Contributor
agents-git-bot
Bot
force-pushed
the
sync-docs-pr-672
branch
from
November 23, 2025 13:32
7f9565b to
eb32b10
Compare
agents-git-bot
Bot
force-pushed
the
sync-docs-pr-672
branch
from
November 24, 2025 14:01
eb32b10 to
12ee0ff
Compare
Contributor
Author
|
Added additional enhancements to the documentation:
The documentation now includes:
|
agents-git-bot
Bot
force-pushed
the
sync-docs-pr-672
branch
from
November 25, 2025 18:16
e9c93e1 to
b66c921
Compare
agents-git-bot
Bot
force-pushed
the
sync-docs-pr-672
branch
from
November 26, 2025 14:25
6f491e5 to
0aab361
Compare
Updates documentation for PR cloudflare/agents#672 ## Changes - Updated addMcpServer() return type to discriminated union - Added MCPConnectionState enum documentation - Documented new "connected" state in connection lifecycle - Added connection state transition diagrams - Documented new discovery behavior with timeout and cancellation - Created comprehensive changelog with migration guide ## Breaking Changes - MCPClientConnection.init() no longer auto-discovers capabilities - addMcpServer() return type changed to discriminated union - New "connected" state added to connection lifecycle 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
agents-git-bot
Bot
force-pushed
the
sync-docs-pr-672
branch
from
November 26, 2025 14:38
a241181 to
3a95eef
Compare
Contributor
Author
Updated DocumentationThis PR has been updated with comprehensive documentation for the MCP connection state improvements: Changes Made
Migration Guide HighlightsThe changelog includes detailed migration guidance for:
All documentation follows Cloudflare's style guide and uses appropriate components. 🤖 Generated with Claude Code |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documentation sync for cloudflare/agents PR #672: feat: enums connection state and standardise tool discovery
This update documents breaking API changes and new features related to MCP connection state management and discovery improvements.
Breaking Changes
addMcpServer()Return Type Changed{ id: string; authUrl: string | undefined }{ id: string; state: MCPConnectionState.AUTHENTICATING; authUrl: string }{ id: string; state: MCPConnectionState.READY; authUrl?: undefined }Error Handling Now Required
addMcpServer()now throws errors on connection/discovery failuresClientConnection.init()Behavior ChangedMCPClientManagerNew Features
MCPConnectionStateEnumimport { MCPConnectionState } from "agents"New Connection State:
connectedNew Method:
discoverIfConnected()MCPClientManagerDocumentation Updates
Connection States Section
MCPConnectionStateenumUpdated Examples
MCPConnectionStateenumresult.statevsresult.authUrlType Signatures
addMcpServer()signature to show discriminated uniontypeof MCPConnectionState.AUTHENTICATINGgetMcpServers()Updatesconnectedstate to state field documentationTest Plan
Related PR
cloudflare/agents#672
🤖 Generated with Claude Code