Interactive OpenAI Codex OAuth login for standalone LLMProxy releases.
The browser-facing OAuth protocol returns JSON/string-keyed provider data.
This module owns that external boundary and converts successful token responses
into LLMProxy.Providers.OpenAICodex.OAuth credentials for storage.
Summary
Types
@type post_fun() :: (String.t(), keyword() -> {:ok, Req.Response.t()} | {:error, term()})
Functions
@spec exchange_code(String.t(), String.t(), post_fun()) :: {:ok, LLMProxy.Providers.OpenAICodex.OAuth.t()} | {:error, term()}
@spec new_state() :: String.t()
@spec new_verifier() :: String.t()
@spec parse_token_response(map() | String.t()) :: {:ok, LLMProxy.Providers.OpenAICodex.OAuth.t()} | {:error, term()}