user_subscribe.api 1.7 KB

syntax = "v1"

info(
    title: "xx实例"
    desc: "xx实例"
    author: "author"
    email: "email"
    version: "v1"
)

@server(
    prefix: user_subscribe/v1
    group: user_subscribe
    jwt: JwtAuth
)
service Core {
    @handler getUserSubscribe
    post /user_subscribe/:id (UserSubscribeGetRequest) returns (UserSubscribeGetResponse)
    @handler saveUserSubscribe
    post /user_subscribe (UserSubscribeSaveRequest) returns (UserSubscribeSaveResponse)
    @handler deleteUserSubscribe
    delete /user_subscribe/:id (UserSubscribeDeleteRequest) returns (UserSubscribeDeleteResponse)
    @handler updateUserSubscribe
    put /user_subscribe/:id (UserSubscribeUpdateRequest) returns (UserSubscribeUpdateResponse)
    @handler searchUserSubscribe
    post /user_subscribe/search (UserSubscribeSearchRequest) returns (UserSubscribeSearchResponse)
}

type (
    UserSubscribeGetRequest {
		Id int64 `path:"id"`
	}
    UserSubscribeGetResponse struct{
		UserSubscribe UserSubscribeItem `json:"user_subscribe"`
    }

	UserSubscribeSaveRequest struct{
		UserSubscribe UserSubscribeItem `json:"user_subscribe"`
    }
    UserSubscribeSaveResponse struct{}

	UserSubscribeDeleteRequest struct{
        Id int64 `path:"id"`
    }
    UserSubscribeDeleteResponse struct{}

	UserSubscribeUpdateRequest struct{
		Id int64 `path:"id"`
        UserSubscribe UserSubscribeItem `json:"user_subscribe"`
    }
    UserSubscribeUpdateResponse struct{}

 	UserSubscribeSearchRequest struct{
         Page int  `json:"page"`
         Size int  `json:"size"`
    }
    UserSubscribeSearchResponse{
        List []UserSubscribeItem  `json:"list"`
        Total int64 `json:"total"`
    }
	UserSubscribeItem struct{
	
	}
)