syntax = "v1" info ( title: "用户接口" ) type ( UserInfoResp { Id int64 `json:"id"` Email string `json:"email"` Avatar string `json:"avatar"` Balance int64 `json:"balance"` Commission int64 `json:"commission"` IsAdmin bool `json:"is_admin"` } UpdatePasswordReq { OldPassword string `json:"old_password"` NewPassword string `json:"new_password"` } UserSubscribeResp { Id int64 `json:"id"` SubscribeId int64 `json:"subscribe_id"` Name string `json:"name"` ExpireAt string `json:"expire_at"` Traffic int64 `json:"traffic"` UsedTraffic int64 `json:"used_traffic"` Token string `json:"token"` } ) @server ( prefix: /api/v1/user group: user jwt: JwtAuth ) service ppanel-api { @handler GetUserInfoHandler get /info returns (UserInfoResp) @handler UpdateUserPasswordHandler post /password (UpdatePasswordReq) @handler GetUserSubscribeHandler get /subscribe returns ([]UserSubscribeResp) }