Files
Andrew Khadder c48c1ec283 feat(server): add OAuth provider setup hook
Providers can now pass an optional `setup(host)` to `oauthCustomProvider`.
The server invokes it once while mounting, after the canonical resource is
resolved and before the first request is served. The host exposes the
resolved resource and base path, `use` for `mcp:` middleware, `registerTool`
and `registerResource` for provider-owned registrations (throwing on name
collisions), `route` for extra public GET routes such as alternate
well-known paths, and `instructions` to rewrite the `initialize` text
without mutating the caller's config.

This is the seam a consent-gated authorization server (e.g. Lane) needs:
a per-call policy check, a step-up tool, and a root-path protected-resource
document, all installed by the provider rather than by every app.

Claude-Session: https://claude.ai/code/session_01LbyvZbHpjatcnsgZSfLf2p
2026-09-09 13:27:15 -07:00
..
2026-08-05 10:26:37 -07:00