Skip to main content

Module auth

Module auth 

Source

Structs§

CopilotAuthConfig
CredentialStorage
Generic credential storage interface.
CustomApiKeyStorage
Custom API Key storage for provider-specific keys.
OAuthCallbackPage
OpenAIChatGptAuthHandle
Runtime auth state shared by OpenAI provider instances.
OpenAIChatGptSession
Stored OpenAI ChatGPT subscription session.
OpenAICredentialOverview
OpenRouterOAuthConfig
Configuration for OpenRouter OAuth authentication.
OpenRouterToken
Stored OAuth token with metadata.
PkceChallenge
PKCE challenge pair containing verifier and challenge strings.

Enums§

AuthCallbackOutcome
AuthCredentialsStoreMode
Preferred storage backend for credentials.
AuthStatus
OAuth authentication status.
OAuthProvider
OpenAIChatGptAuthStatus
Generic auth status reused by slash auth/status output.
OpenAIResolvedAuth
OpenAI auth resolution chosen for the current runtime.
OpenAIResolvedAuthSource

Functions§

clear_custom_api_keys
Clear all custom API keys from secure storage.
clear_oauth_token
clear_oauth_token_with_mode
Clear the stored OAuth token from all storage locations.
clear_openai_chatgpt_session
clear_openai_chatgpt_session_with_mode
exchange_code_for_token
Exchange an authorization code for an API key.
exchange_openai_chatgpt_code_for_tokens
Exchange an authorization code for OAuth tokens.
generate_pkce_challenge
Generate a cryptographically secure PKCE challenge pair.
get_auth_status
get_auth_status_with_mode
Get the current OAuth authentication status.
get_auth_url
Generate the OAuth authorization URL.
get_openai_chatgpt_auth_status
get_openai_chatgpt_auth_status_with_mode
get_openai_chatgpt_auth_url
Build the OpenAI ChatGPT OAuth authorization URL.
load_custom_api_keys
Load all custom API keys from secure storage.
load_oauth_token
Load an OAuth token from storage using the default mode.
load_oauth_token_with_mode
Load an OAuth token from storage with specified mode.
load_openai_chatgpt_session
load_openai_chatgpt_session_with_mode
migrate_custom_api_keys_to_keyring
Migrate plain-text API keys from config to secure storage.
refresh_openai_chatgpt_session_with_mode
resolve_openai_auth
Resolve the active OpenAI auth source for the current configuration.
run_auth_code_callback_server
save_oauth_token
Save an OAuth token to encrypted storage using the default mode.
save_oauth_token_with_mode
Save an OAuth token to encrypted storage with specified mode.
save_openai_chatgpt_session
save_openai_chatgpt_session_with_mode
summarize_openai_credentials