Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateAuthHandler ¶
type CreateAuthHandler struct {
// contains filtered or unexported fields
}
func NewCreateAuthHandler ¶
func NewCreateAuthHandler(creator appauth.Creator) *CreateAuthHandler
func (*CreateAuthHandler) Handle ¶
func (h *CreateAuthHandler) Handle(c *fiber.Ctx) error
Handle godoc @Summary Create an auth @Description Creates a new auth in a gateway. @Tags auths @Accept json @Produce json @Security BearerAuth @Param gateway_id path string true "Gateway id" format(uuid) @Param body body request.CreateAuthRequest true "Auth to create" @Success 201 {object} response.AuthResponse @Failure 400 {object} helpers.ErrorBody @Failure 401 {object} helpers.ErrorBody @Failure 404 {object} helpers.ErrorBody @Failure 409 {object} helpers.ErrorBody @Router /v1/gateways/{gateway_id}/auths [post]
type DeleteAuthHandler ¶
type DeleteAuthHandler struct {
// contains filtered or unexported fields
}
func NewDeleteAuthHandler ¶
func NewDeleteAuthHandler(deleter appauth.Deleter) *DeleteAuthHandler
func (*DeleteAuthHandler) Handle ¶
func (h *DeleteAuthHandler) Handle(c *fiber.Ctx) error
Handle godoc @Summary Delete an auth @Description Deletes an auth from a gateway. @Tags auths @Produce json @Security BearerAuth @Param gateway_id path string true "Gateway id" format(uuid) @Param id path string true "Auth id" format(uuid) @Success 204 "No Content" @Failure 400 {object} helpers.ErrorBody @Failure 401 {object} helpers.ErrorBody @Failure 404 {object} helpers.ErrorBody @Failure 409 {object} helpers.ErrorBody @Router /v1/gateways/{gateway_id}/auths/{id} [delete]
type GetAuthHandler ¶
type GetAuthHandler struct {
// contains filtered or unexported fields
}
func NewGetAuthHandler ¶
func NewGetAuthHandler(finder appauth.Finder) *GetAuthHandler
func (*GetAuthHandler) Handle ¶
func (h *GetAuthHandler) Handle(c *fiber.Ctx) error
Handle godoc @Summary Get an auth @Description Returns a single auth by id. @Tags auths @Produce json @Security BearerAuth @Param gateway_id path string true "Gateway id" format(uuid) @Param id path string true "Auth id" format(uuid) @Success 200 {object} response.AuthResponse @Failure 400 {object} helpers.ErrorBody @Failure 401 {object} helpers.ErrorBody @Failure 404 {object} helpers.ErrorBody @Router /v1/gateways/{gateway_id}/auths/{id} [get]
type ListAuthHandler ¶
type ListAuthHandler struct {
// contains filtered or unexported fields
}
func NewListAuthHandler ¶
func NewListAuthHandler(finder appauth.Finder) *ListAuthHandler
func (*ListAuthHandler) Handle ¶
func (h *ListAuthHandler) Handle(c *fiber.Ctx) error
Handle godoc @Summary List auths @Description Returns a paginated list of auths in a gateway. @Tags auths @Produce json @Security BearerAuth @Param gateway_id path string true "Gateway id" format(uuid) @Param name query string false "Filter by name (substring match)" @Param page query int false "Page number (1-based)" @Param size query int false "Page size" @Success 200 {object} response.ListAuthResponse @Failure 400 {object} helpers.ErrorBody @Failure 401 {object} helpers.ErrorBody @Router /v1/gateways/{gateway_id}/auths [get]
type UpdateAuthHandler ¶
type UpdateAuthHandler struct {
// contains filtered or unexported fields
}
func NewUpdateAuthHandler ¶
func NewUpdateAuthHandler(updater appauth.Updater) *UpdateAuthHandler
func (*UpdateAuthHandler) Handle ¶
func (h *UpdateAuthHandler) Handle(c *fiber.Ctx) error
Handle godoc @Summary Update an auth @Description Updates an existing auth. @Tags auths @Accept json @Produce json @Security BearerAuth @Param gateway_id path string true "Gateway id" format(uuid) @Param id path string true "Auth id" format(uuid) @Param body body request.UpdateAuthRequest true "Auth fields to update" @Success 200 {object} response.AuthResponse @Failure 400 {object} helpers.ErrorBody @Failure 401 {object} helpers.ErrorBody @Failure 404 {object} helpers.ErrorBody @Failure 409 {object} helpers.ErrorBody @Router /v1/gateways/{gateway_id}/auths/{id} [put]