Skip to main content

Module openai_chatgpt_oauth

Module openai_chatgpt_oauth 

Source
Expand description

OpenAI ChatGPT subscription OAuth flow and secure session storage.

This module mirrors the Codex CLI login flow closely enough for VT Code:

  • OAuth authorization-code flow with PKCE
  • refresh-token exchange
  • token exchange for an OpenAI API-key-style bearer token
  • secure storage in keyring or encrypted file storage

Re-exports§

pub use super::credentials::AuthCredentialsStoreMode;

Structs§

OpenAIChatGptAuthHandle
Runtime auth state shared by OpenAI provider instances.
OpenAIChatGptSession
Stored OpenAI ChatGPT subscription session.
OpenAICredentialOverview

Enums§

OpenAIChatGptAuthStatus
Generic auth status reused by slash auth/status output.
OpenAIResolvedAuth
OpenAI auth resolution chosen for the current runtime.
OpenAIResolvedAuthSource

Functions§

clear_openai_chatgpt_session
clear_openai_chatgpt_session_with_mode
exchange_openai_chatgpt_code_for_tokens
Exchange an authorization code for OAuth tokens.
generate_openai_oauth_state
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_openai_chatgpt_session
load_openai_chatgpt_session_with_mode
parse_openai_chatgpt_manual_callback_input
refresh_openai_chatgpt_session_from_refresh_token
refresh_openai_chatgpt_session_with_mode
resolve_openai_auth
Resolve the active OpenAI auth source for the current configuration.
save_openai_chatgpt_session
save_openai_chatgpt_session_with_mode
summarize_openai_credentials