@@ -15,6 +15,7 @@ A clear, educational example demonstrating OAuth2 authentication for MCP (Model
1515## 📚 What You'll Learn
1616
1717- ** OAuth2** - Authorization Code flow with PKCE
18+ - ** Dynamic Client Registration (DCR)** - RFC 7591 implementation for automatic client registration
1819- ** MCP Authorization** - Official specification (2025-06-18)
1920- ** Security** - Token validation, CSRF protection, resource indicators
2021- ** MCP SDK** - Building servers with FastMCP and clients with MCP SDK
@@ -39,9 +40,11 @@ make install
3940| ------| ---------| ------------------|
4041| ** [ docs/QUICKSTART.md] ( docs/QUICKSTART.md ) ** | Get running in 5 minutes | You want to try it immediately |
4142| ** [ docs/GITHUB.md] ( docs/GITHUB.md ) ** | GitHub OAuth app setup | Setting up for the first time |
43+ | ** [ docs/INSPECTOR.md] ( docs/INSPECTOR.md ) ** | MCP Inspector setup and testing | You want to test with MCP Inspector |
4244| ** [ docs/FLOW_EXPLAINED.md] ( docs/FLOW_EXPLAINED.md ) ** | Detailed OAuth flow | You want to understand how it works |
4345| ** [ docs/DIAGRAMS.md] ( docs/DIAGRAMS.md ) ** | Visual explanations | You prefer diagrams |
4446| ** [ docs/IMPLEMENTATION.md] ( docs/IMPLEMENTATION.md ) ** | Technical details | You're implementing your own |
47+ | ** [ docs/DYNAMIC_CLIENT_REGISTRATION.md] ( docs/DYNAMIC_CLIENT_REGISTRATION.md ) ** | Dynamic Client Registration (DCR) | You want to understand automatic client registration |
4548
4649## 📁 Project Structure
4750
@@ -75,7 +78,7 @@ mcp-auth/
7578 - OAuth2 endpoints integrated with FastAPI
7679 - Three example tools (calculator, greeter, server_info)
7780 - Token validation middleware
78- - Compatible with both SSE and STDIO transports
81+ - Uses ** HTTP Streaming (NDJSON) ** transport for efficient communication
7982
8083### 2. ** MCP Client** (` mcp_auth_example/client.py ` )
8184 - Built with ** official MCP Python SDK**
@@ -101,22 +104,22 @@ mcp-auth/
101104 - Implements MCP Authorization specification (2025-06-18)
102105 - Exposes OAuth metadata endpoints (RFC 9728, RFC 8414)
103106 - Validates access tokens before serving tools
104- - Provides MCP tools via HTTP/SSE transport
107+ - Provides MCP tools via ** HTTP Streaming (NDJSON) ** transport
105108 - Tools: calculator (add, multiply), greeter (hello, goodbye), server info
106109
107110### 2. ** MCP Client** (` mcp_auth_example/client.py ` )
108111 - Handles OAuth2 flow with GitHub
109112 - Automatically opens browser for user authentication
110113 - Manages access tokens
111114 - Connects to MCP server using ** MCP SDK client**
112- - Makes authenticated requests via MCP protocol (SSE transport)
113- - Demonstrates proper MCP tool invocation
115+ - Makes authenticated requests via MCP protocol (** HTTP Streaming transport** )
116+ - Demonstrates proper MCP tool invocation with NDJSON format
114117
115118### 3. ** Pydantic AI Agent** (` mcp_auth_example/agent.py ` ) ✨ NEW
116119 - Interactive CLI agent powered by ** pydantic-ai**
117120 - Uses ** Anthropic Claude Sonnet 4.5** model
118121 - Automatically authenticates with OAuth2
119- - Connects to MCP server with authenticated tools
122+ - Connects to MCP server with authenticated tools via HTTP Streaming
120123 - Natural language interface to MCP tools
121124 - Example: "What is 15 + 27?" → Uses calculator_add tool
122125
0 commit comments