refactor: 更新项目引用路径从perfect-panel/ppanel-server到perfect-panel/server
Build docker and publish / build (20.15.1) (push) Failing after 6m27s
Build docker and publish / build (20.15.1) (push) Failing after 6m27s
feat: 添加版本和构建时间变量 fix: 修正短信队列类型注释错误 style: 清理未使用的代码和测试文件 docs: 更新安装文档中的下载链接 chore: 迁移数据库脚本添加日志和订阅配置
This commit is contained in:
+35
-8
@@ -11,6 +11,10 @@ info (
|
||||
import "../types.api"
|
||||
|
||||
type (
|
||||
OnlineUser {
|
||||
SID int64 `json:"uid"`
|
||||
IP string `json:"ip"`
|
||||
}
|
||||
ShadowsocksProtocol {
|
||||
Port int `json:"port"`
|
||||
Method string `json:"method"`
|
||||
@@ -44,9 +48,9 @@ type (
|
||||
ServerCommon
|
||||
}
|
||||
GetServerConfigResponse {
|
||||
Basic ServerBasic `json:"basic"`
|
||||
Protocol string `json:"protocol"`
|
||||
Config interface{} `json:"config"`
|
||||
Basic ServerBasic `json:"basic"`
|
||||
Protocol string `json:"protocol"`
|
||||
Config interface{} `json:"config"`
|
||||
}
|
||||
ServerBasic {
|
||||
PushInterval int64 `json:"push_interval"`
|
||||
@@ -60,8 +64,8 @@ type (
|
||||
ServerUser {
|
||||
Id int64 `json:"id"`
|
||||
UUID string `json:"uuid"`
|
||||
SpeedLimit int64 `json:"speed_limit"`
|
||||
DeviceLimit int64 `json:"device_limit"`
|
||||
SpeedLimit int64 `json:"speed_limit"`
|
||||
DeviceLimit int64 `json:"device_limit"`
|
||||
}
|
||||
GetServerUserListRequest {
|
||||
ServerCommon
|
||||
@@ -78,7 +82,6 @@ type (
|
||||
ServerCommon
|
||||
Traffic []UserTraffic `json:"traffic"`
|
||||
}
|
||||
|
||||
ServerPushStatusRequest {
|
||||
ServerCommon
|
||||
Cpu float64 `json:"cpu"`
|
||||
@@ -90,11 +93,25 @@ type (
|
||||
ServerCommon
|
||||
Users []OnlineUser `json:"users"`
|
||||
}
|
||||
QueryServerConfigRequest {
|
||||
ServerID int64 `path:"server_id"`
|
||||
SecretKey string `form:"secret_key"`
|
||||
Protocols []string `form:"protocols,omitempty"`
|
||||
}
|
||||
QueryServerConfigResponse {
|
||||
TrafficReportThreshold int64 `json:"traffic_report_threshold"`
|
||||
IPStrategy string `json:"ip_strategy"`
|
||||
DNS []NodeDNS `json:"dns"`
|
||||
Block []string `json:"block"`
|
||||
Outbound []NodeOutbound `json:"outbound"`
|
||||
Protocols []Protocol `json:"protocols"`
|
||||
Total int64 `json:"total"`
|
||||
}
|
||||
)
|
||||
|
||||
@server (
|
||||
prefix: v1/server
|
||||
group: server
|
||||
prefix: v1/server
|
||||
group: server
|
||||
middleware: ServerMiddleware
|
||||
)
|
||||
service ppanel {
|
||||
@@ -119,3 +136,13 @@ service ppanel {
|
||||
post /online (OnlineUsersRequest)
|
||||
}
|
||||
|
||||
@server (
|
||||
prefix: v2/server
|
||||
group: server
|
||||
)
|
||||
service ppanel {
|
||||
@doc "Get Server Protocol Config"
|
||||
@handler QueryServerProtocolConfig
|
||||
get /:server_id (QueryServerConfigRequest) returns (QueryServerConfigResponse)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user