github.com/sagernet/sing-box@v1.9.0-rc.20/option/experimental.go (about)

     1  package option
     2  
     3  type ExperimentalOptions struct {
     4  	CacheFile *CacheFileOptions `json:"cache_file,omitempty"`
     5  	ClashAPI  *ClashAPIOptions  `json:"clash_api,omitempty"`
     6  	V2RayAPI  *V2RayAPIOptions  `json:"v2ray_api,omitempty"`
     7  	Debug     *DebugOptions     `json:"debug,omitempty"`
     8  }
     9  
    10  type CacheFileOptions struct {
    11  	Enabled     bool     `json:"enabled,omitempty"`
    12  	Path        string   `json:"path,omitempty"`
    13  	CacheID     string   `json:"cache_id,omitempty"`
    14  	StoreFakeIP bool     `json:"store_fakeip,omitempty"`
    15  	StoreRDRC   bool     `json:"store_rdrc,omitempty"`
    16  	RDRCTimeout Duration `json:"rdrc_timeout,omitempty"`
    17  }
    18  
    19  type ClashAPIOptions struct {
    20  	ExternalController       string   `json:"external_controller,omitempty"`
    21  	ExternalUI               string   `json:"external_ui,omitempty"`
    22  	ExternalUIDownloadURL    string   `json:"external_ui_download_url,omitempty"`
    23  	ExternalUIDownloadDetour string   `json:"external_ui_download_detour,omitempty"`
    24  	Secret                   string   `json:"secret,omitempty"`
    25  	DefaultMode              string   `json:"default_mode,omitempty"`
    26  	ModeList                 []string `json:"-"`
    27  
    28  	// Deprecated: migrated to global cache file
    29  	CacheFile string `json:"cache_file,omitempty"`
    30  	// Deprecated: migrated to global cache file
    31  	CacheID string `json:"cache_id,omitempty"`
    32  	// Deprecated: migrated to global cache file
    33  	StoreMode bool `json:"store_mode,omitempty"`
    34  	// Deprecated: migrated to global cache file
    35  	StoreSelected bool `json:"store_selected,omitempty"`
    36  	// Deprecated: migrated to global cache file
    37  	StoreFakeIP bool `json:"store_fakeip,omitempty"`
    38  }
    39  
    40  type V2RayAPIOptions struct {
    41  	Listen string                    `json:"listen,omitempty"`
    42  	Stats  *V2RayStatsServiceOptions `json:"stats,omitempty"`
    43  }
    44  
    45  type V2RayStatsServiceOptions struct {
    46  	Enabled   bool     `json:"enabled,omitempty"`
    47  	Inbounds  []string `json:"inbounds,omitempty"`
    48  	Outbounds []string `json:"outbounds,omitempty"`
    49  	Users     []string `json:"users,omitempty"`
    50  }