fix: api descript
This commit is contained in:
+7
-4
@@ -2,6 +2,9 @@ syntax = "v1"
|
||||
import "common.api"
|
||||
|
||||
type (
|
||||
PathIDReq {
|
||||
Id int64 `path:"id"`
|
||||
}
|
||||
SearchReq {
|
||||
PageReq
|
||||
Q string `form:"q"`
|
||||
@@ -18,12 +21,13 @@ type (
|
||||
|
||||
FavoriteReq {
|
||||
TargetType string `json:"targetType"` // player, shop
|
||||
TargetId string `json:"targetId"`
|
||||
TargetId int64 `json:"targetId"`
|
||||
}
|
||||
|
||||
FavoriteCheckReq {
|
||||
PathIDReq
|
||||
TargetType string `form:"targetType"`
|
||||
TargetId string `form:"targetId"`
|
||||
TargetId int64 `form:"targetId"`
|
||||
}
|
||||
|
||||
FavoriteCheckResp {
|
||||
@@ -48,7 +52,6 @@ service juwan-api {
|
||||
@server(
|
||||
prefix: api/v1
|
||||
group: favorites
|
||||
jwt: Auth
|
||||
)
|
||||
service juwan-api {
|
||||
@doc "获取收藏列表"
|
||||
@@ -61,7 +64,7 @@ service juwan-api {
|
||||
|
||||
@doc "取消收藏"
|
||||
@handler RemoveFavorite
|
||||
delete /favorites/:id (EmptyResp) returns (EmptyResp)
|
||||
delete /favorites/:id (PathIDReq) returns (EmptyResp)
|
||||
|
||||
@doc "检查收藏状态"
|
||||
@handler CheckFavorite
|
||||
|
||||
Reference in New Issue
Block a user