examples/auth/propelauth_oauth/README.md
Demonstrates FastMCP server protection with PropelAuth OAuth.
Create a PropelAuth Account:
Configure Allowed MCP Clients:
Configure Scopes:
read:user_data)Generate Introspection Credentials:
Note Your Auth URL:
https://auth.yourdomain.com)Create a .env file:
# Required PropelAuth credentials
PROPELAUTH_AUTH_URL=https://auth.yourdomain.com
PROPELAUTH_INTROSPECTION_CLIENT_ID=your-client-id
PROPELAUTH_INTROSPECTION_CLIENT_SECRET=your-client-secret
BASE_URL=http://127.0.0.1:8000/
# Optional: additional scopes tokens must include (comma-separated)
# PROPELAUTH_REQUIRED_SCOPES=read:user_data
Start the server:
# From this directory
uv run python server.py
The server will start on http://127.0.0.1:8000/mcp with PropelAuth OAuth authentication enabled.
Test with client:
uv run python client.py
The client.py will: