Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API interface { GetNodeInfo() (nodeInfo *NodeInfo, err error) GetUserList() (userList *[]UserInfo, err error) ReportNodeStatus(nodeStatus *NodeStatus) (err error) ReportNodeOnlineUsers(onlineUser *[]OnlineUser) (err error) ReportUserTraffic(userTraffic *[]UserTraffic) (err error) Describe() ClientInfo GetNodeRule() (ruleList *[]DetectRule, err error) ReportIllegal(detectResultList *[]DetectResult) (err error) Debug() }
API is the interface for different panel's api.
type Config ¶
type Config struct { APIHost string `mapstructure:"ApiHost"` NodeID int `mapstructure:"NodeID"` Key string `mapstructure:"ApiKey"` NodeType string `mapstructure:"NodeType"` EnableVless bool `mapstructure:"EnableVless"` EnableXTLS bool `mapstructure:"EnableXTLS"` Timeout int `mapstructure:"Timeout"` SpeedLimit float64 `mapstructure:"SpeedLimit"` DeviceLimit int `mapstructure:"DeviceLimit"` RuleListPath string `mapstructure:"RuleListPath"` DisableCustomConfig bool `mapstructure:"DisableCustomConfig"` }
API config
type DetectResult ¶
type DetectRule ¶
type NodeInfo ¶
type NodeInfo struct { NodeType string // Must be V2ray, Trojan, and Shadowsocks NodeID int Port uint32 SpeedLimit uint64 // Bps AlterID uint16 TransportProtocol string FakeType string Host string Path string EnableTLS bool TLSType string EnableVless bool CypherMethod string ServiceName string Header json.RawMessage }
type NodeStatus ¶
Node status
type OnlineUser ¶
Click to show internal directories.
Click to hide internal directories.