fix: validate clientMetadataUrl at construction time (fail-fast) (#1653)
Co-authored-by: Luis <reche@Luiss-MacBook-Pro.local> Co-authored-by: Felix Weinberger <3823880+felixweinberger@users.noreply.github.com>
This commit is contained in:
parent
595652ceca
commit
6bec24a14c
1 changed files with 113 additions and 2 deletions
9
.changeset/fix-validate-client-metadata-url.md
Normal file
9
.changeset/fix-validate-client-metadata-url.md
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
'@modelcontextprotocol/client': minor
|
||||
---
|
||||
|
||||
Add `validateClientMetadataUrl()` utility for early validation of `clientMetadataUrl`
|
||||
|
||||
Exports a `validateClientMetadataUrl()` function that `OAuthClientProvider` implementations
|
||||
can call in their constructors to fail fast on invalid URL-based client IDs, instead of
|
||||
discovering the error deep in the auth flow.
|
||||
Loading…
Reference in a new issue