Documentation Index
Fetch the complete documentation index at: https://docs.mcp-use.com/llms.txt
Use this file to discover all available pages before exploring further.
View the source code for this module on GitHub: https://github.com/mcp-use/mcp-use/blob/main/libraries/python/mcp_use/client/auth/oauth.py
ClientRegistrationResponse
from mcp_use.client.auth.oauth import ClientRegistrationResponse
Attributes
MCP client instance
MCP client instance
MCP client instance
MCP client instance
List of items
List of items
List of items
MCP client instance
String value
method init
Create a new model by parsing and validating input data from keyword arguments.Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be
validated to form a valid model.self is explicitly positional-only to allow self as a field name.ParametersSignatureParameter value
def __init__(data: Any):
FileTokenStorage
from mcp_use.client.auth.oauth import FileTokenStorage
OAuth
from mcp_use.client.auth.oauth import OAuth
method init
Initialize OAuth handler.ParametersSignatureThe MCP server URLToken storage implementation. Defaults to FileTokenStorageOAuth scopes to requestOAuth client ID. If not provided, will attempt dynamic registrationOAuth client secret (for confidential clients)Port for local callback server, if empty, 8080 is usedOAuth client provider to prevent metadata discoveryField used to authenticate with CIMD
def __init__(server_url: str, token_storage: mcp_use.client.auth.oauth.FileTokenStorage | None = None, scope: str | None = None, client_id: str | None = None, client_secret: str | None = None, callback_port: int | None = None, oauth_provider: mcp_use.client.auth.oauth.OAuthClientProvider | None = None, client_metadata_url: str | None = None):
OAuthClientProvider
from mcp_use.client.auth.oauth import OAuthClientProvider
method init
Create a new model by parsing and validating input data from keyword arguments.Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be
validated to form a valid model.self is explicitly positional-only to allow self as a field name.ParametersSignatureParameter value
def __init__(data: Any):
ProtectedResourceMetadata
from mcp_use.client.auth.oauth import ProtectedResourceMetadata
method init
Create a new model by parsing and validating input data from keyword arguments.Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be
validated to form a valid model.self is explicitly positional-only to allow self as a field name.ParametersSignatureParameter value
def __init__(data: Any):
ServerOAuthMetadata
from mcp_use.client.auth.oauth import ServerOAuthMetadata
Attributes
Parameter value
Parameter value
Parameter value
Parameter value
Parameter value
Parameter value
Parameter value
Parameter value
List of items
List of items
List of items
List of items
List of items
List of items
List of items
MCP client instance
method init
Create a new model by parsing and validating input data from keyword arguments.Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be
validated to form a valid model.self is explicitly positional-only to allow self as a field name.ParametersSignatureParameter value
def __init__(data: Any):
TokenData
from mcp_use.client.auth.oauth import TokenData
method init
Create a new model by parsing and validating input data from keyword arguments.Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be
validated to form a valid model.self is explicitly positional-only to allow self as a field name.ParametersSignatureParameter value
def __init__(data: Any):