Skip to content

Conversation

@yasomaru
Copy link
Contributor

@yasomaru yasomaru commented Sep 3, 2025

Add ErrOAuth error type and handling to match TypeScript SDK behavior. OAuth protocol errors now return HTTP 400 instead of 500, providing better error classification for authentication issues.

Changes

  • Add ErrOAuth variable for OAuth-specific protocol errors
  • Update verify function to return 400 for OAuth errors
  • Add test case for OAuth error handling

Fixes compatibility with TypeScript SDK error handling patterns.

@jba jba merged commit 1250a31 into modelcontextprotocol:main Sep 3, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants