mirror of
https://github.com/router-for-me/CLIProxyAPI.git
synced 2026-02-03 04:50:52 +08:00
Add support for Generative Language API Key and improve client initialization
- Added `GlAPIKey` support in configuration to enable Generative Language API. - Integrated `GenerativeLanguageAPIKey` handling in client and API handlers. - Updated response translators to manage generative language responses properly. - Enhanced HTTP client initialization logic with proxy support for API requests. - Refactored streaming and non-streaming flows to account for generative language-specific logic.
This commit is contained in:
@@ -20,6 +20,8 @@ type Config struct {
|
||||
ApiKeys []string `yaml:"api-keys"`
|
||||
// QuotaExceeded defines the behavior when a quota is exceeded.
|
||||
QuotaExceeded ConfigQuotaExceeded `yaml:"quota-exceeded"`
|
||||
// GlAPIKey is the API key for the generative language API.
|
||||
GlAPIKey []string `yaml:"generative-language-api-key"`
|
||||
}
|
||||
|
||||
type ConfigQuotaExceeded struct {
|
||||
|
||||
Reference in New Issue
Block a user