Commit 12ee0ff
docs: update MCP client connection states and API
Updates documentation for PR #672 (feat: enums connection state)
## Changes
- Added new "connected" state to MCPConnectionState enum
- Documented new discoverIfConnected() method for manual capability discovery
- Updated connection state machine documentation with detailed descriptions
- Added note about discovery failures now throwing errors immediately
- Updated getMcpServers() return type to include "connected" state
## API Changes
- New connection state "connected" for servers with transport connected but capabilities not yet discovered
- New method discoverIfConnected(serverId) for refreshing server capabilities
- Discovery failures now throw errors immediately instead of continuing with empty arrays
Related PR: cloudflare/agents#672
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 5e83d1d commit 12ee0ff
File tree
1 file changed
+65
-2
lines changed- src/content/docs/agents/model-context-protocol
1 file changed
+65
-2
lines changedLines changed: 65 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
193 | 193 | | |
194 | 194 | | |
195 | 195 | | |
196 | | - | |
| 196 | + | |
197 | 197 | | |
| 198 | + | |
198 | 199 | | |
199 | 200 | | |
200 | 201 | | |
| |||
228 | 229 | | |
229 | 230 | | |
230 | 231 | | |
231 | | - | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
232 | 289 | | |
233 | 290 | | |
234 | 291 | | |
| |||
278 | 335 | | |
279 | 336 | | |
280 | 337 | | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
281 | 344 | | |
282 | 345 | | |
283 | 346 | | |
| |||
0 commit comments