Update protocol version

* This fixes #378
* In types.ts
  - set LATEST_PROTOCOL_VERSION to "2025-03-26"
  - add "2025-03-26" to SUPPORTED_PROTOCOL_VERSIONS
* In auth.test.ts
  - in test "returns metadata when discovery succeeds"
    - expect "MCP-Protocol-Version" to be "2025-03-26"
This commit is contained in:
cliffhall 2025-04-25 09:16:28 -04:00
commit 3a9a6c944b

View file

@ -39,7 +39,7 @@ describe("OAuth Authorization", () => {
const [url, options] = calls[0];
expect(url.toString()).toBe("https://auth.example.com/.well-known/oauth-authorization-server");
expect(options.headers).toEqual({
"MCP-Protocol-Version": "2024-11-05"
"MCP-Protocol-Version": "2025-03-26"
});
});
@ -478,4 +478,4 @@ describe("OAuth Authorization", () => {
).rejects.toThrow("Dynamic client registration failed");
});
});
});
});