OAuthClientProviderImpl
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:33
Please note most of these “unused” methods are part of OAuthClientProvider
Implements
Section titled “Implements”OAuthClientProvider
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new OAuthClientProviderImpl(
config):OAuthClientProviderImpl
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:39
Parameters
Section titled “Parameters”config
Section titled “config”OAuthClientProviderConfig
Returns
Section titled “Returns”OAuthClientProviderImpl
Accessors
Section titled “Accessors”clientMetadata
Section titled “clientMetadata”Get Signature
Section titled “Get Signature”get clientMetadata():
object
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:110
Metadata about this OAuth client.
Returns
Section titled “Returns”object
client_name?
Section titled “client_name?”
optionalclient_name?:string
client_uri?
Section titled “client_uri?”
optionalclient_uri?:string
contacts?
Section titled “contacts?”
optionalcontacts?:string[]
grant_types?
Section titled “grant_types?”
optionalgrant_types?:string[]
optionaljwks?:any
jwks_uri?
Section titled “jwks_uri?”
optionaljwks_uri?:string
logo_uri?
Section titled “logo_uri?”
optionallogo_uri?:string
policy_uri?
Section titled “policy_uri?”
optionalpolicy_uri?:string
redirect_uris
Section titled “redirect_uris”redirect_uris:
string[]
response_types?
Section titled “response_types?”
optionalresponse_types?:string[]
scope?
Section titled “scope?”
optionalscope?:string
software_id?
Section titled “software_id?”
optionalsoftware_id?:string
software_statement?
Section titled “software_statement?”
optionalsoftware_statement?:string
software_version?
Section titled “software_version?”
optionalsoftware_version?:string
token_endpoint_auth_method?
Section titled “token_endpoint_auth_method?”
optionaltoken_endpoint_auth_method?:string
tos_uri?
Section titled “tos_uri?”
optionaltos_uri?:string
Implementation of
Section titled “Implementation of”OAuthClientProvider.clientMetadata
redirectUrl
Section titled “redirectUrl”Get Signature
Section titled “Get Signature”get redirectUrl():
string
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:105
The URL to redirect the user agent to after authorization. Return undefined for non-interactive flows that don’t require user interaction (e.g., client_credentials, jwt-bearer).
Returns
Section titled “Returns”string
Implementation of
Section titled “Implementation of”OAuthClientProvider.redirectUrl
Methods
Section titled “Methods”clientInformation()
Section titled “clientInformation()”clientInformation():
Promise<{client_id:string;client_id_issued_at?:number;client_name?:string;client_secret?:string;client_secret_expires_at?:number;client_uri?:string;contacts?:string[];grant_types?:string[];jwks?:any;jwks_uri?:string;logo_uri?:string;policy_uri?:string;redirect_uris:string[];response_types?:string[];scope?:string;software_id?:string;software_statement?:string;software_version?:string;token_endpoint_auth_method?:string;tos_uri?:string; } |undefined>
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:132
Loads information about this OAuth client, as registered already with the
server, or returns undefined if the client is not registered with the
server.
Returns
Section titled “Returns”Promise<{ client_id: string; client_id_issued_at?: number; client_name?: string; client_secret?: string; client_secret_expires_at?: number; client_uri?: string; contacts?: string[]; grant_types?: string[]; jwks?: any; jwks_uri?: string; logo_uri?: string; policy_uri?: string; redirect_uris: string[]; response_types?: string[]; scope?: string; software_id?: string; software_statement?: string; software_version?: string; token_endpoint_auth_method?: string; tos_uri?: string; } | undefined>
Implementation of
Section titled “Implementation of”OAuthClientProvider.clientInformation
codeVerifier()
Section titled “codeVerifier()”codeVerifier():
Promise<string>
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:159
Loads the PKCE code verifier for the current session, necessary to validate the authorization result.
Returns
Section titled “Returns”Promise<string>
Implementation of
Section titled “Implementation of”OAuthClientProvider.codeVerifier
redirectToAuthorization()
Section titled “redirectToAuthorization()”redirectToAuthorization(
authUrl):Promise<void>
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:168
Invoked to redirect the user agent to the given URL to begin the authorization flow.
Parameters
Section titled “Parameters”authUrl
Section titled “authUrl”URL
Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”OAuthClientProvider.redirectToAuthorization
saveClientInformation()
Section titled “saveClientInformation()”saveClientInformation(
clientInformation):Promise<void>
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:124
If implemented, this permits the OAuth client to dynamically register with
the server. Client information saved this way should later be read via
clientInformation().
This method is not required to be implemented if client information is statically known (e.g., pre-registered).
Parameters
Section titled “Parameters”clientInformation
Section titled “clientInformation”client_id
Section titled “client_id”string
client_id_issued_at?
Section titled “client_id_issued_at?”number
client_name?
Section titled “client_name?”string
client_secret?
Section titled “client_secret?”string
client_secret_expires_at?
Section titled “client_secret_expires_at?”number
client_uri?
Section titled “client_uri?”string
contacts?
Section titled “contacts?”string[]
grant_types?
Section titled “grant_types?”string[]
any
jwks_uri?
Section titled “jwks_uri?”string
logo_uri?
Section titled “logo_uri?”string
policy_uri?
Section titled “policy_uri?”string
redirect_uris
Section titled “redirect_uris”string[]
response_types?
Section titled “response_types?”string[]
scope?
Section titled “scope?”string
software_id?
Section titled “software_id?”string
software_statement?
Section titled “software_statement?”string
software_version?
Section titled “software_version?”string
token_endpoint_auth_method?
Section titled “token_endpoint_auth_method?”string
tos_uri?
Section titled “tos_uri?”string
Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”OAuthClientProvider.saveClientInformation
saveCodeVerifier()
Section titled “saveCodeVerifier()”saveCodeVerifier(
codeVerifier):Promise<void>
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:151
Saves a PKCE code verifier for the current session, before redirecting to the authorization flow.
Parameters
Section titled “Parameters”codeVerifier
Section titled “codeVerifier”string
Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”OAuthClientProvider.saveCodeVerifier
saveTokens()
Section titled “saveTokens()”saveTokens(
tokens):Promise<void>
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:138
Stores new OAuth tokens for the current session, after a successful authorization.
Parameters
Section titled “Parameters”tokens
Section titled “tokens”access_token
Section titled “access_token”string
expires_in?
Section titled “expires_in?”number
id_token?
Section titled “id_token?”string
refresh_token?
Section titled “refresh_token?”string
scope?
Section titled “scope?”string
token_type
Section titled “token_type”string
Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”OAuthClientProvider.saveTokens
state()
Section titled “state()”state():
string|Promise<string>
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:100
Returns a OAuth2 state parameter.
Returns
Section titled “Returns”string | Promise<string>
Implementation of
Section titled “Implementation of”OAuthClientProvider.state
tokens()
Section titled “tokens()”tokens(): {
access_token:string;expires_in?:number;id_token?:string;refresh_token?:string;scope?:string;token_type:string; } |undefined
Defined in: _worktrees/docs-release/gaunt-sloth/packages/agent/src/mcp/OAuthClientProviderImpl.ts:145
Loads any existing OAuth tokens for the current session, or returns
undefined if there are no saved tokens.
Returns
Section titled “Returns”{ access_token: string; expires_in?: number; id_token?: string; refresh_token?: string; scope?: string; token_type: string; } | undefined
Implementation of
Section titled “Implementation of”OAuthClientProvider.tokens