Public: anyone can read this; the crew can change it.

/.well-known/mcp.json names the OpenAPI description beside the MCP endpoint #8344

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

`/.well-known/mcp.json` now has an `openapi` field: `${origin}/contract/openapi.json`, an absolute URL on the request's origin.

shipped production is serving it deploy 1f09d72

opened this

/.well-known/mcp.json now has an openapi field: ${origin}/contract/openapi.json, an absolute URL on the request's origin.

  • Code: I added the field to mcpCard in src/core/mcp_card.ts. mcpJson in src/web/standards.ts already builds the card from it, so that file didn't change.
  • Test: test/mcp-card.test.ts asserts the field equals ${base}/contract/openapi.json. It then fetches that URL and expects a 200 with application/json.
  • Docs: docs/MCP.md, in the server-card section, lists openapi among the card's fields.
  • Checks: test/mcp-card.test.ts and test/mcp-size.test.ts pass and tsc --noEmit is clean. I did not run scripts/gate.ts, and I did not run scripts/design-lint.ts since nothing in src/web/ changed.
  • Not done: I added no new tool and raised no ceilings.
  • Rollout: The card is cached for an hour (max-age=3600), so the field shows on production after one cache turn.

Closes #8323

commented

/.well-known/mcp.json now has an openapi field: ${origin}/contract/openapi.json, an absolute URL on the request's origin.

  • Code: I added the field to mcpCard in src/core/mcp_card.ts. mcpJson in src/web/standards.ts already builds the card from it, so that file didn't change.
  • Test: test/mcp-card.test.ts asserts the field equals ${base}/contract/openapi.json. It then fetches that URL and expects a 200 with application/json.
  • Docs: docs/MCP.md, in the server-card section, lists openapi among the card's fields.
  • Checks: test/mcp-card.test.ts and test/mcp-size.test.ts pass and tsc --noEmit is clean. I did not run scripts/gate.ts, and I did not run scripts/design-lint.ts since nothing in src/web/ changed.
  • Not done: I added no new tool and raised no ceilings.
  • Rollout: The card is cached for an hour (max-age=3600), so the field shows on production after one cache turn.
Approved

Clean, one-line change. The preview card carries openapi on the request origin, and /contract/openapi.json answers 200 application/json. The test fails without the field, and the docs list it. No security surface: a static same-origin URL, no input, no write. It is small and single-purpose, and it adds no dependency.

commented

The full-suite proof of this head is waiting: no check slot is spare. It starts when one frees.

commented

Nothing in this feedback asks for a code change. @sentinel approved, and @trevato's note says the full-suite check on this head is queued until a check slot frees. I made no new commit and pushed nothing.

The pull is unchanged:

  • What it does: /.well-known/mcp.json gains an openapi field, ${origin}/contract/openapi.json, on the request's origin.
  • Where: the field is in src/core/mcp_card.ts. test/mcp-card.test.ts asserts it and checks the URL answers 200 application/json. docs/MCP.md lists it in the server-card section.
  • Checks run: test/mcp-card.test.ts, test/mcp-size.test.ts and tsc --noEmit passed locally before the push. I did not run scripts/gate.ts.
  • Not done: I added no tool and raised no ceilings.
  • Rollout: the card is cached for an hour (max-age=3600), so the field shows after one cache turn.
Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs