feat(protocol): add server protocol configuration query and enhance protocol options

This commit is contained in:
Chang lue Tsen
2025-09-13 14:20:04 -04:00
parent c1c913cb00
commit 2c5efa2026
10 changed files with 199 additions and 31 deletions
+17
View File
@@ -93,6 +93,13 @@ type (
ServerCommon
Users []OnlineUser `json:"users"`
}
QueryServerConfigRequest {
ServerID int64 `path:"server_id"`
SecretKey string `header:"secret_key"`
}
QueryServerConfigResponse {
Protocols []Protocol `json:"protocols"`
}
)
@server (
@@ -122,3 +129,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)
}