package
0.0.0-20250104135103-08bbe5a41a8a
Repository: https://github.com/otuff/go-startkode.git
Documentation: pkg.go.dev

# Functions

CreateTodo godoc @Summary Create a new todo @Description Create a new todo entry in the database @Tags todos @Accept application/json @Produce application/json @Param todo body generated.CreateTodoParams true "Todo object" @Success 201 {object} generated.CreateTodoParams @Failure 400 {string} string "Bad request" @Failure 500 {string} string "Internal server error" @Router /api/todo [post].
DeleteTodo godoc @Summary Delete todo @Description Delete a todo based on the id from the database @Tags todos @Produce application/json @Param id path string true "Todo ID" @Success 200 {object} generated.Todo @Failure 400 {string} string "Bad request" @Failure 404 {string} string "Not found" @Router /api/todo/{id} [delete].
GetAllTodos godoc @Summary Get all todos @Description Fetches a list of all todos from the database @Tags todos @Produce application/json @Success 200 {array} generated.Todo @Router /api/todos [get].
GetTodo godoc @Summary Get todo @Description Fetches a todo based on the id from the database @Tags todos @Produce application/json @Param id path string true "Todo ID" @Success 200 {object} generated.Todo @Router /api/todo/{id} [get].