handlers

package
v0.0.0-...-06e6d5f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 30, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateDummy

func CreateDummy(ds service.DummyService) fiber.Handler

@Summary Create a new dummy item @Description Create a new dummy item with the provided information @Tags dummy @Accept json @Produce json @Param dummy body request.Dummy true "Dummy information" @Success 201 {object} model.Dummy @Failure 400 {object} response.restResponseError "Invalid request body or validation errors" @Failure 500 {object} response.restResponseError "Internal server error" @Router /dummy [post] @Security OAuth2Password

func GetDummies

func GetDummies(ds service.DummyService) fiber.Handler

@Summary List all dummies @Description Get a list of dummies with pagination @Tags dummy @Accept json @Produce json @Param page query int false "Page number" @Param size query int false "Size per page" @Param sortBy query string false "Sort by field" @Param sortOrder query string false "Sort order (asc or desc)" @Success 200 {object} response.RestResponsePagination[model.Dummy] "Paginated list of dummies" @Failure 400 {object} response.restResponseError "Invalid query parameters" @Failure 500 {object} response.restResponseError "Internal server error" @Router /dummy [get] @Security OAuth2Password

func GetDummyById

func GetDummyById(ds service.DummyService) fiber.Handler

@Summary Find a dummy by ID @Description Get dummy details by ID @Tags dummy @Accept json @Produce json @Param id path int true "Dummy ID" @Success 200 {object} model.Dummy @Failure 400 {object} response.restResponseError "Invalid ID" @Failure 404 {object} response.restResponseError "Internal Error" @Router /dummy/{id} [get] @Security OAuth2Password

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL