Documentation
¶
Overview ¶
internal/auth/apikey.go 从配置文件读取 API Key
internal/auth/auth.go 认证链:按优先级依次尝试获取 API Key
internal/auth/keychain_other.go 非 macOS 平台的 CC OAuth 占位实现
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadCCOAuthToken ¶
LoadCCOAuthToken 非 macOS 平台暂不支持 CC OAuth TODO: Linux 支持通过 libsecret / secret-tool 读取
func ReadAPIKeyFromFile ¶
ReadAPIKeyFromFile 从 JSON 文件读取 API Key(公开导出版本)
func ResolveAPIKey ¶
ResolveAPIKey 按优先级解析 API Key 优先级:环境变量 > 配置文件 > CC OAuth Token
func SaveCredentials ¶
SaveCredentials 将 API Key 写入 JSON 凭据文件 自动创建父目录
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.