inspector/core/react
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Cliff Hall 9b558afee1
feat(web): display negotiated MCP protocol version on ServerCard (#1324) (#1442)
* feat(web): show negotiated MCP protocol version on ServerCard (#1324)

Add optional protocolVersion to ConnectionState and render it as a
dimmed "MCP <version>" label at the end of the transport-badge/
description row on ServerCard, shown only when connected. The value
is plumbed through useInspectorClient as part of #1324.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* feat(core,web): surface negotiated protocolVersion end-to-end (#1324)

Plumb the MCP protocol version negotiated during initialize from the
InspectorClient through to the ServerCard so the active connected card
displays "MCP <version>".

The SDK Client doesn't expose protocolVersion; it stamps it onto the
transport via setProtocolVersion. MessageTrackingTransport now captures
it (and forwards to the base transport when present), so it works for
stdio too — whose base transport has no setProtocolVersion.

- core: MessageTrackingTransport captures + exposes protocolVersion;
  InspectorClient stores it, exposes getProtocolVersion(), dispatches a
  protocolVersionChange event, and clears it on disconnect.
- core: useInspectorClient subscribes and returns protocolVersion.
- web: App reads it from the hook (drops the hard-coded "2025-06-18")
  and InspectorView splices it onto the active server's connection.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* refactor(web): decouple initializeResult from protocolVersion (#1324 review)

Gate the initializeResult memo on serverInfo only, not protocolVersion.
initializeResult also drives the connected ViewHeader and Connection Info
modal, so requiring the version risked hiding the whole connected surface
in the edge case where it's absent. protocolVersion now flows through as
the optional field it already is everywhere downstream ('' reads as
unknown; the ServerCard label and modal value both tolerate it).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* refactor(web): drop redundant connected-check in InspectorView splice (#1324 review)

initializeResult is derived from connectionStatus in App's memo, so a
truthy initializeResult.protocolVersion already implies a live
connection — the extra connectionStatus === 'connected' guard in the
splice was redundant. ServerCard keeps its own status guard (dumb-
component robustness). No behavior change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-08 07:40:02 -04:00
..
useFetchRequestLog.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
useInspectorClient.ts feat(web): display negotiated MCP protocol version on ServerCard (#1324) (#1442) 2026-06-08 07:40:02 -04:00
useManagedPrompts.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
useManagedRequestorTasks.ts feat(web): wire up MCP task support — Tasks screen, Run-as-task, status toasts (#1422) (#1424) 2026-06-04 08:49:47 -04:00
useManagedResources.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
useManagedResourceTemplates.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
useManagedTools.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
useMessageLog.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
usePagedPrompts.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
usePagedRequestorTasks.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
usePagedResources.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
usePagedResourceTemplates.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
usePagedTools.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00
usePendingClientRequests.ts feat(web): render pending sampling/elicitation requests (#1407) (#1411) 2026-06-02 17:52:20 -04:00
useResourceSubscriptions.ts Expose live resource subscriptions via a hook (#1325) (#1326) 2026-05-19 20:15:51 -04:00
useSandboxUrl.ts feat(apps): render running MCP Apps end-to-end (#1370) (#1403) 2026-06-01 18:01:44 -04:00
useServers.ts feat(servers): hot-reload server list on external mcp.json edits (#1345) (#1357) 2026-05-25 11:30:05 -04:00
useSettingsDraft.ts fix(servers): make settings form re-render on every keystroke (#1361) (#1362) 2026-05-26 13:42:14 -04:00
useStderrLog.ts feat(core): port v1.5 hook layer (#1243) (#1300) 2026-05-13 17:43:07 -04:00