fix(api): standardize formatting and add missing newlines in API files
This commit is contained in:
parent
987e25e7ac
commit
1a849fd461
@ -76,3 +76,4 @@ service ppanel {
|
||||
@handler GetAdsDetail
|
||||
get /detail (GetAdsDetailRequest) returns (Ads)
|
||||
}
|
||||
|
||||
|
||||
@ -73,3 +73,4 @@ service ppanel {
|
||||
@handler GetAnnouncement
|
||||
get /detail (GetAnnouncementRequest) returns (Announcement)
|
||||
}
|
||||
|
||||
|
||||
@ -25,7 +25,6 @@ type (
|
||||
GetAuthMethodListResponse {
|
||||
List []AuthMethodConfig `json:"list"`
|
||||
}
|
||||
|
||||
TestSmsSendRequest {
|
||||
AreaCode string `json:"area_code" validate:"required"`
|
||||
Telephone string `json:"telephone" validate:"required"`
|
||||
@ -70,3 +69,4 @@ service ppanel {
|
||||
@handler GetEmailPlatform
|
||||
get /email_platform returns (PlatformResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -85,3 +85,4 @@ service ppanel {
|
||||
@handler QueryTicketWaitReply
|
||||
get /ticket returns (TicketWaitRelpyResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -82,3 +82,4 @@ service ppanel {
|
||||
@handler GetCouponList
|
||||
get /list (GetCouponListRequest) returns (GetCouponListResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -7,3 +7,4 @@ info(
|
||||
email: "tension@ppanel.com"
|
||||
version: "0.0.1"
|
||||
)
|
||||
|
||||
|
||||
@ -37,3 +37,4 @@ service ppanel {
|
||||
@handler GetMessageLogList
|
||||
get /message/list (GetMessageLogListRequest) returns (GetMessageLogListResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -65,3 +65,4 @@ service ppanel {
|
||||
@handler UpdateOrderStatus
|
||||
put /status (UpdateOrderStatusRequest)
|
||||
}
|
||||
|
||||
|
||||
@ -78,3 +78,4 @@ service ppanel {
|
||||
@handler GetPaymentPlatform
|
||||
get /platform returns (PlatformResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -187,3 +187,4 @@ service ppanel {
|
||||
@handler GetRuleGroupList
|
||||
get /rule_group_list returns (GetRuleGroupResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -88,13 +88,10 @@ type (
|
||||
GroupId int64 `form:"group_id,omitempty"`
|
||||
Search string `form:"search,omitempty"`
|
||||
}
|
||||
|
||||
SubscribeItem {
|
||||
Subscribe
|
||||
|
||||
Sold int64 `json:"sold"`
|
||||
}
|
||||
|
||||
GetSubscribeListResponse {
|
||||
List []SubscribeItem `json:"list"`
|
||||
Total int64 `json:"total"`
|
||||
@ -161,3 +158,4 @@ service ppanel {
|
||||
@handler SubscribeSort
|
||||
post /sort (SubscribeSortRequest)
|
||||
}
|
||||
|
||||
|
||||
@ -202,3 +202,4 @@ service ppanel {
|
||||
@handler UpdateVerifyCodeConfig
|
||||
put /verify_code_config (VerifyCodeConfig)
|
||||
}
|
||||
|
||||
|
||||
@ -59,3 +59,4 @@ service ppanel {
|
||||
@handler CreateTicketFollow
|
||||
post /follow (CreateTicketFollowRequest)
|
||||
}
|
||||
|
||||
|
||||
@ -21,7 +21,6 @@ type (
|
||||
group: admin/tool
|
||||
middleware: AuthMiddleware
|
||||
)
|
||||
|
||||
service ppanel {
|
||||
@doc "Get System Log"
|
||||
@handler GetSystemLog
|
||||
@ -31,3 +30,4 @@ service ppanel {
|
||||
@handler RestartSystem
|
||||
get /restart
|
||||
}
|
||||
|
||||
|
||||
@ -275,3 +275,4 @@ service ppanel {
|
||||
@handler GetUserLoginLogs
|
||||
get /login/logs (GetUserLoginLogsRequest) returns (GetUserLoginLogsResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -20,3 +20,4 @@ service ppanel {
|
||||
@handler QueryAnnouncement
|
||||
get /list (QueryAnnouncementRequest) returns (QueryAnnouncementResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -101,3 +101,4 @@ service ppanel {
|
||||
@handler GetAppConfig
|
||||
post /config (AppConfigRequest) returns (AppConfigResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -15,7 +15,6 @@ import "../types.api"
|
||||
group: app/document
|
||||
middleware: AppMiddleware,AuthMiddleware
|
||||
)
|
||||
|
||||
service ppanel {
|
||||
@doc "Get document list"
|
||||
@handler QueryDocumentList
|
||||
@ -25,3 +24,4 @@ service ppanel {
|
||||
@handler QueryDocumentDetail
|
||||
get /detail (QueryDocumentDetailRequest) returns (Document)
|
||||
}
|
||||
|
||||
|
||||
@ -15,11 +15,9 @@ type (
|
||||
Total int64 `json:"total"`
|
||||
List []ServerRuleGroup `json:"list"`
|
||||
}
|
||||
|
||||
AppUserSubscbribeNodeRequest {
|
||||
Id int64 `form:"id" validate:"required"`
|
||||
}
|
||||
|
||||
AppUserSubscbribeNodeResponse {
|
||||
List []AppUserSubscbribeNode `json:"list"`
|
||||
}
|
||||
@ -30,9 +28,7 @@ type (
|
||||
group: app/node
|
||||
middleware: AppMiddleware,AuthMiddleware
|
||||
)
|
||||
|
||||
service ppanel {
|
||||
|
||||
@doc "Get Node list"
|
||||
@handler GetNodeList
|
||||
get /list (AppUserSubscbribeNodeRequest) returns (AppUserSubscbribeNodeResponse)
|
||||
@ -40,5 +36,5 @@ service ppanel {
|
||||
@doc "Get rule group list"
|
||||
@handler GetRuleGroupList
|
||||
get /rule_group_list returns (AppRuleGroupListResponse)
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -54,3 +54,4 @@ service ppanel {
|
||||
@handler QueryOrderList
|
||||
get /list (QueryOrderListRequest) returns (QueryOrderListResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -20,3 +20,4 @@ service ppanel {
|
||||
@handler GetAvailablePaymentMethods
|
||||
get /methods returns (GetAvailablePaymentMethodsResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -14,24 +14,19 @@ type (
|
||||
QueryUserSubscribeResp {
|
||||
Data []UserSubscribeData `json:"data"`
|
||||
}
|
||||
|
||||
UserSubscribeData {
|
||||
SubscribeId int64 `json:"subscribe_id"`
|
||||
UserSubscribeId int64 `json:"user_subscribe_id"`
|
||||
}
|
||||
|
||||
UserSubscribeResetPeriodRequest {
|
||||
UserSubscribeId int64 `json:"user_subscribe_id"`
|
||||
}
|
||||
|
||||
UserSubscribeResetPeriodResponse {
|
||||
Status bool `json:"status"`
|
||||
}
|
||||
|
||||
AppUserSubscribeRequest {
|
||||
ContainsNodes *bool `form:"contains_nodes"`
|
||||
}
|
||||
|
||||
AppUserSubscbribeResponse {
|
||||
List []AppUserSubcbribe `json:"list"`
|
||||
}
|
||||
@ -42,7 +37,6 @@ type (
|
||||
group: app/subscribe
|
||||
middleware: AppMiddleware,AuthMiddleware
|
||||
)
|
||||
|
||||
service ppanel {
|
||||
@doc "Get subscribe list"
|
||||
@handler QuerySubscribeList
|
||||
@ -68,3 +62,4 @@ service ppanel {
|
||||
@handler ResetUserSubscribePeriod
|
||||
post /reset/period (UserSubscribeResetPeriodRequest) returns (UserSubscribeResetPeriodResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -33,12 +33,10 @@ type (
|
||||
Method string `json:"method" validate:"required" validate:"required,oneof=email telephone device"`
|
||||
Code string `json:"code"`
|
||||
}
|
||||
|
||||
GetUserOnlineTimeStatisticsResponse {
|
||||
WeeklyStats []WeeklyStat `json:"weekly_stats"`
|
||||
ConnectionRecords ConnectionRecords `json:"connection_records"`
|
||||
}
|
||||
|
||||
WeeklyStat {
|
||||
Day int `json:"day"`
|
||||
DayName string `json:"day_name"`
|
||||
@ -84,5 +82,5 @@ service ppanel {
|
||||
@doc "Query User Affiliate Count"
|
||||
@handler QueryUserAffiliate
|
||||
get /affiliate/count returns (QueryUserAffiliateCountResponse)
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -13,9 +13,9 @@ info(
|
||||
group: app/ws
|
||||
middleware: AuthMiddleware
|
||||
)
|
||||
|
||||
service ppanel {
|
||||
@doc "App heartbeat"
|
||||
@handler AppWs
|
||||
get /:userid/:identifier
|
||||
}
|
||||
|
||||
|
||||
@ -54,12 +54,10 @@ type (
|
||||
OAuthLoginResponse {
|
||||
Redirect string `json:"redirect"`
|
||||
}
|
||||
|
||||
OAuthLoginGetTokenRequest {
|
||||
Method string `json:"method" validate:"required"` // google, facebook, apple, telegram, github etc.
|
||||
Callback interface{} `json:"callback" validate:"required"`
|
||||
}
|
||||
|
||||
// login request
|
||||
TelephoneLoginRequest {
|
||||
Telephone string `json:"telephone" validate:"required"`
|
||||
@ -163,3 +161,4 @@ service ppanel {
|
||||
@handler AppleLoginCallback
|
||||
post /callback/apple (AppleLoginCallbackRequest)
|
||||
}
|
||||
|
||||
|
||||
@ -75,7 +75,6 @@ type (
|
||||
Code string `json:"code" validate:"required"`
|
||||
Type uint8 `json:"type" validate:"required"`
|
||||
}
|
||||
|
||||
CheckVerificationCodeRespone {
|
||||
Status bool `json:"status"`
|
||||
}
|
||||
@ -122,3 +121,4 @@ service ppanel {
|
||||
@handler CheckVerificationCode
|
||||
post /check_verification_code (CheckVerificationCodeRequest) returns (CheckVerificationCodeRespone)
|
||||
}
|
||||
|
||||
|
||||
@ -78,7 +78,6 @@ type (
|
||||
ServerCommon
|
||||
Traffic []UserTraffic `json:"traffic"`
|
||||
}
|
||||
|
||||
ServerPushStatusRequest {
|
||||
ServerCommon
|
||||
Cpu float64 `json:"cpu"`
|
||||
@ -118,3 +117,4 @@ service ppanel {
|
||||
@handler PushOnlineUsers
|
||||
post /online (OnlineUsersRequest)
|
||||
}
|
||||
|
||||
|
||||
@ -20,3 +20,4 @@ service ppanel {
|
||||
@handler QueryAnnouncement
|
||||
get /list (QueryAnnouncementRequest) returns (QueryAnnouncementResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -15,7 +15,6 @@ import "../types.api"
|
||||
group: public/document
|
||||
middleware: AuthMiddleware
|
||||
)
|
||||
|
||||
service ppanel {
|
||||
@doc "Get document list"
|
||||
@handler QueryDocumentList
|
||||
@ -25,3 +24,4 @@ service ppanel {
|
||||
@handler QueryDocumentDetail
|
||||
get /detail (QueryDocumentDetailRequest) returns (Document)
|
||||
}
|
||||
|
||||
|
||||
@ -48,3 +48,4 @@ service ppanel {
|
||||
@handler QueryOrderList
|
||||
get /list (QueryOrderListRequest) returns (QueryOrderListResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -20,3 +20,4 @@ service ppanel {
|
||||
@handler GetAvailablePaymentMethods
|
||||
get /methods returns (GetAvailablePaymentMethodsResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -93,3 +93,4 @@ service ppanel {
|
||||
@handler PurchaseCheckout
|
||||
post /order/checkout (CheckoutOrderRequest) returns (CheckoutOrderResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -28,3 +28,4 @@ service ppanel {
|
||||
@handler QueryApplicationConfig
|
||||
get /application/config returns (ApplicationResponse)
|
||||
}
|
||||
|
||||
|
||||
@ -66,3 +66,4 @@ service ppanel {
|
||||
@handler CreateUserTicket
|
||||
post / (CreateUserTicketRequest)
|
||||
}
|
||||
|
||||
|
||||
@ -28,7 +28,6 @@ type (
|
||||
List []UserBalanceLog `json:"list"`
|
||||
Total int64 `json:"total"`
|
||||
}
|
||||
|
||||
CommissionLog {
|
||||
Id int64 `json:"id"`
|
||||
UserId int64 `json:"user_id"`
|
||||
@ -77,37 +76,30 @@ type (
|
||||
ResetUserSubscribeTokenRequest {
|
||||
UserSubscribeId int64 `json:"user_subscribe_id"`
|
||||
}
|
||||
|
||||
GetLoginLogRequest {
|
||||
Page int `form:"page"`
|
||||
Size int `form:"size"`
|
||||
}
|
||||
|
||||
GetLoginLogResponse {
|
||||
List []UserLoginLog `json:"list"`
|
||||
Total int64 `json:"total"`
|
||||
}
|
||||
|
||||
GetSubscribeLogRequest {
|
||||
Page int `form:"page"`
|
||||
Size int `form:"size"`
|
||||
}
|
||||
|
||||
GetSubscribeLogResponse {
|
||||
List []UserSubscribeLog `json:"list"`
|
||||
Total int64 `json:"total"`
|
||||
}
|
||||
|
||||
UpdateBindMobileRequest {
|
||||
AreaCode string `json:"area_code" validate:"required"`
|
||||
Mobile string `json:"mobile" validate:"required"`
|
||||
Code string `json:"code" validate:"required"`
|
||||
}
|
||||
|
||||
UpdateBindEmailRequest {
|
||||
Email string `json:"email" validate:"required"`
|
||||
}
|
||||
|
||||
VerifyEmailRequest {
|
||||
Email string `json:"email" validate:"required"`
|
||||
Code string `json:"code" validate:"required"`
|
||||
@ -208,3 +200,4 @@ service ppanel {
|
||||
@handler UpdateBindEmail
|
||||
put /bind_email (UpdateBindEmailRequest)
|
||||
}
|
||||
|
||||
|
||||
@ -7,6 +7,7 @@ info(
|
||||
email: "tension@ppanel.com"
|
||||
version: "0.0.1"
|
||||
)
|
||||
|
||||
import (
|
||||
"./admin/system.api"
|
||||
"./admin/user.api"
|
||||
@ -24,3 +25,4 @@ import (
|
||||
"./admin/log.api"
|
||||
"./admin/ads.api"
|
||||
)
|
||||
|
||||
|
||||
@ -19,3 +19,4 @@ import (
|
||||
"./app/document.api"
|
||||
"./app/subscribe.api"
|
||||
)
|
||||
|
||||
|
||||
@ -12,3 +12,4 @@ import (
|
||||
"./common.api"
|
||||
"./auth/auth.api"
|
||||
)
|
||||
|
||||
|
||||
@ -7,6 +7,7 @@ info(
|
||||
email: "tension@ppanel.com"
|
||||
version: "0.0.1"
|
||||
)
|
||||
|
||||
import (
|
||||
"./public/user.api"
|
||||
"./public/subscribe.api"
|
||||
@ -17,3 +18,4 @@ import (
|
||||
"./public/document.api"
|
||||
"./public/portal.api"
|
||||
)
|
||||
|
||||
|
||||
@ -253,6 +253,10 @@ type (
|
||||
CongestionController string `json:"congestion_controller"`
|
||||
SecurityConfig SecurityConfig `json:"security_config"`
|
||||
}
|
||||
AnyTLS {
|
||||
Port int `json:"port" validate:"required"`
|
||||
SecurityConfig SecurityConfig `json:"security_config"`
|
||||
}
|
||||
SecurityConfig {
|
||||
SNI string `json:"sni"`
|
||||
AllowInsecure *bool `json:"allow_insecure"`
|
||||
@ -711,12 +715,10 @@ type (
|
||||
Telephone string `json:"telephone"`
|
||||
Address string `json:"address"`
|
||||
}
|
||||
|
||||
QueryUserAffiliateCountResponse {
|
||||
Registers int64 `json:"registers"`
|
||||
TotalCommission int64 `json:"total_commission"`
|
||||
}
|
||||
|
||||
AppUserSubcbribe {
|
||||
Id int64 `json:"id"`
|
||||
Name string `json:"name"`
|
||||
@ -728,7 +730,6 @@ type (
|
||||
ExpireTime string `json:"expire_time"`
|
||||
List []AppUserSubscbribeNode `json:"list"`
|
||||
}
|
||||
|
||||
AppUserSubscbribeNode {
|
||||
Id int64 `json:"id"`
|
||||
Name string `json:"name"`
|
||||
@ -751,3 +752,4 @@ type (
|
||||
Download int64 `json:"download"`
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user