Spaces:
Paused
Paused
Download internal/cmd/auth_manager.go from shimen/shinmenapi: direct link, hf CLI and curl.
- Browser
- Download file 913 Bytes
-
https://huggingface.co/spaces/shimen/shinmenapi/resolve/main/internal/cmd/auth_manager.go
- Command line
-
hf download hf://spaces/shimen/shinmenapi/internal/cmd/auth_manager.go
-
curl -L -o auth_manager.go https://huggingface.co/spaces/shimen/shinmenapi/resolve/main/internal/cmd/auth_manager.go
913 Bytes
| package cmd | |
| import ( | |
| sdkAuth "github.com/router-for-me/CLIProxyAPI/v6/sdk/auth" | |
| ) | |
| // newAuthManager creates a new authentication manager instance with all supported | |
| // authenticators and a file-based token store. It initializes authenticators for | |
| // Gemini, Codex, Claude, Qwen, IFlow, Antigravity, and GitHub Copilot providers. | |
| // | |
| // Returns: | |
| // - *sdkAuth.Manager: A configured authentication manager instance | |
| func newAuthManager() *sdkAuth.Manager { | |
| store := sdkAuth.GetTokenStore() | |
| manager := sdkAuth.NewManager(store, | |
| sdkAuth.NewGeminiAuthenticator(), | |
| sdkAuth.NewCodexAuthenticator(), | |
| sdkAuth.NewClaudeAuthenticator(), | |
| sdkAuth.NewQwenAuthenticator(), | |
| sdkAuth.NewIFlowAuthenticator(), | |
| sdkAuth.NewAntigravityAuthenticator(), | |
| sdkAuth.NewKimiAuthenticator(), | |
| sdkAuth.NewKiroAuthenticator(), | |
| sdkAuth.NewGitHubCopilotAuthenticator(), | |
| sdkAuth.NewKiloAuthenticator(), | |
| ) | |
| return manager | |
| } | |