Skip to main content

Module auth

Module auth 

Source
Expand description

Authentication module for VT Code.

This module provides:

  • OAuth flows for OpenRouter and other providers
  • ACP authentication method handling
  • Authentication configuration management

Re-exports§

pub use auth_handler::AuthHandler;
pub use auth_handler::AuthMethod;

Modules§

auth_handler
Authentication handler for different ACP auth methods.

Structs§

OAuthCallbackPage
OpenRouterOAuthConfig
Configuration for OpenRouter OAuth authentication.
OpenRouterToken
Stored OAuth token with metadata.
PkceChallenge
PKCE challenge pair containing verifier and challenge strings.

Enums§

AuthStatus
OAuth authentication status.
OAuthProvider
OAuthResult

Functions§

clear_oauth_token
exchange_code_for_token
Exchange an authorization code for an API key.
generate_pkce_challenge
Generate a cryptographically secure PKCE challenge pair.
get_auth_status
get_auth_url
Generate the OAuth authorization URL.
load_oauth_token
Load an OAuth token from storage using the default mode.
run_oauth_callback_server
save_oauth_token
Save an OAuth token to encrypted storage using the default mode.