mirror of
https://github.com/router-for-me/CLIProxyAPI.git
synced 2026-02-03 04:50:52 +08:00
- Replaced `config.Config` with `config.SDKConfig` across components for simpler configuration management. - Updated proxy setup functions and handlers to align with `SDKConfig` improvements. - Reorganized handler imports to match new SDK structure.
15 lines
695 B
Go
15 lines
695 B
Go
// Package config provides configuration management for the CLI Proxy API server.
|
|
// It handles loading and parsing YAML configuration files, and provides structured
|
|
// access to application settings including server port, authentication directory,
|
|
// debug settings, proxy configuration, and API keys.
|
|
package config
|
|
|
|
// SDKConfig represents the application's configuration, loaded from a YAML file.
|
|
type SDKConfig struct {
|
|
// ProxyURL is the URL of an optional proxy server to use for outbound requests.
|
|
ProxyURL string `yaml:"proxy-url" json:"proxy-url"`
|
|
|
|
// RequestLog enables or disables detailed request logging functionality.
|
|
RequestLog bool `yaml:"request-log" json:"request-log"`
|
|
}
|