1#![allow(clippy::unreachable, clippy::map_err_ignore)]
2#![allow(missing_docs)]
3mod auth_service;
6mod config;
7pub mod credentials;
8pub mod mcp_oauth;
9pub mod oauth_server;
10pub mod openai_chatgpt_oauth;
11pub mod openrouter_oauth;
12pub mod pkce;
13mod storage_paths;
14
15pub use auth_service::OpenAIAccountAuthService;
16pub use config::{AuthConfig, CopilotAuthConfig, OpenAIAuthConfig, OpenAIPreferredMethod};
17pub use credentials::{
18 AuthCredentialsStoreMode, CredentialStorage, CustomApiKeyStorage, clear_custom_api_keys,
19 load_custom_api_keys, migrate_custom_api_keys_to_keyring,
20};
21pub use mcp_oauth::{
22 McpOAuthConfig, McpOAuthLoginCompletion, McpOAuthPreparedLogin, McpOAuthService,
23 McpOAuthStatus, McpOAuthToken,
24};
25pub use oauth_server::{
26 AuthCallbackOutcome, AuthCodeCallbackServer, OAuthCallbackPage, OAuthProvider,
27 run_auth_code_callback_server, start_auth_code_callback_server,
28};
29pub use openai_chatgpt_oauth::{
30 OpenAIChatGptAuthHandle, OpenAIChatGptAuthStatus, OpenAIChatGptSession,
31 OpenAIChatGptSessionRefresher, OpenAICredentialOverview, OpenAIResolvedAuth,
32 OpenAIResolvedAuthSource, clear_openai_chatgpt_session, clear_openai_chatgpt_session_with_mode,
33 exchange_openai_chatgpt_code_for_tokens, generate_openai_oauth_state,
34 get_openai_chatgpt_auth_status, get_openai_chatgpt_auth_status_with_mode,
35 get_openai_chatgpt_auth_url, load_openai_chatgpt_session,
36 load_openai_chatgpt_session_with_mode, parse_openai_chatgpt_manual_callback_input,
37 refresh_openai_chatgpt_session_with_mode, resolve_openai_auth, save_openai_chatgpt_session,
38 save_openai_chatgpt_session_with_mode, summarize_openai_credentials,
39};
40pub use openrouter_oauth::{
41 AuthStatus, OpenRouterOAuthConfig, OpenRouterToken, clear_oauth_token,
42 clear_oauth_token_with_mode, exchange_code_for_token, get_auth_status,
43 get_auth_status_with_mode, get_auth_url, load_oauth_token, load_oauth_token_with_mode,
44 save_oauth_token, save_oauth_token_with_mode,
45};
46pub use pkce::{PkceChallenge, generate_pkce_challenge};