Getmcpauth
FreeNot checkedDrop-in OAuth 2.1 + Dynamic Client Registration token verification for Python MCP servers, backed by mcpauth.
About
Drop-in OAuth 2.1 + Dynamic Client Registration token verification for Python MCP servers, backed by mcpauth.
README
Drop-in OAuth 2.1 + Dynamic Client Registration (RFC 7591) token verification for Python MCP servers, backed by mcpauth.
Implements the official mcp SDK's TokenVerifier protocol — the official SDK ships a full bearer-auth middleware stack (BearerAuthBackend, RequireAuthMiddleware) but no ready-made verifier that actually checks a token against a real authorization server. This package is that verifier.
Install
pip install getmcpauth
Usage
import os
from mcp.server.fastmcp import FastMCP
from getmcpauth import McpAuthTokenVerifier, build_auth_settings
mcp = FastMCP(
"my-server",
token_verifier=McpAuthTokenVerifier(
"https://getmcpauth.dev/api/oauth/introspect",
registration_secret=os.environ["MCPAUTH_SECRET"],
),
auth=build_auth_settings(
"https://getmcpauth.dev",
resource_server_url="https://my-server.example.com",
),
)
Get a registration_secret by creating a project at getmcpauth.dev/dashboard.
API
McpAuthTokenVerifier— implementsmcp.server.auth.provider.TokenVerifier. Successful verifications are cached in-process (default 30s) so a chatty agent conversation doesn't trigger a network round trip on every tool call.build_auth_settings(issuer_url, *, resource_server_url, required_scopes=None)— builds anAuthSettingsforFastMCPwith Dynamic Client Registration enabled.required_scope_for_call(body)/is_authorized(required_scope, granted_scopes)/check_batch(bodies, granted_scopes)— helpers for MCP-native tool scoping (tool:<name>scope strings mapped directly totools/callrequests).
Full docs: getmcpauth.dev/docs
Development
pip install -e ".[test]"
pytest
License
MIT
Install Getmcpauth in Claude Desktop, Claude Code & Cursor
unyly install getmcpauthInstalls into Claude Desktop, Claude Code, Cursor & VS Code — handles npx, uvx and build-from-source repos for you.
First time? Get the CLI: curl -fsSL https://unyly.org/install | sh
Or configure manually
Run in your terminal:
claude mcp add getmcpauth -- uvx getmcpauthFAQ
Is Getmcpauth MCP free?
Yes, Getmcpauth MCP is free — one-click install via Unyly at no cost.
Does Getmcpauth need an API key?
No, Getmcpauth runs without API keys or environment variables.
Is Getmcpauth hosted or self-hosted?
A hosted option is available: Unyly runs the server in the cloud, no local setup required.
How do I install Getmcpauth in Claude Desktop, Claude Code or Cursor?
Open Getmcpauth on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.
Related MCPs
GitHub
PRs, issues, code search, CI status
by GitHubFilesystem
Secure file operations with configurable access controls.
Memory
Knowledge graph-based persistent memory system.
Template MCP Server
A CLI tool to create a new Model Context Protocol server project with TypeScript support, dual transport options, and an extensible structure
by mcpdotdirectCompare Getmcpauth with
Not sure what to pick?
Find your stack in 60 seconds
Author?
Embed badge for your README
Browse similar
All development MCPs
