Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var HandlerSet = wire.NewSet(HandlerStruct, ThreatAPIStruct)
View Source
var HandlerStruct = wire.Struct(new(Handler), "*")
View Source
var ThreatAPIStruct = wire.Struct(new(ThreatAPI), "*")
Functions ¶
func OnLimitReached ¶
func OnLimitReached(c *fiber.Ctx) error
Types ¶
type Handler ¶
type Handler struct {
ThreatAPI *ThreatAPI
}
func (*Handler) RegisterAPI ¶
func (h *Handler) RegisterAPI(r *fiber.App)
type ThreatAPI ¶
func (*ThreatAPI) GetThreats ¶
@Tags Threat @Summary 获取所有的威胁IP信息 @Description 获取所有的威胁IP信息, 并分页的形式呈现 @ID get-threats @Accept json @Produce json @Param current query integer false "当前查询页码(默认 1)" @Param page_sizet query integer false "当前查询每页显示条数(默认 10)" @Success 200 {object} schema.ThreatsResponse @Failure 400 {object} schema.ErrorResponse "{code:1002,status_code:401,message:no permission}" @Failure 500 {object} schema.ErrorResponse "{code:1001,status_code:504,message:internal server error}" @Router /api/threats [get]
Click to show internal directories.
Click to hide internal directories.