package
0.0.0-20241201171602-12f376fda57a
Repository: https://github.com/iabdulzahid/golang_task_manager.git
Documentation: pkg.go.dev

# Functions

CreateTask godoc @Summary Create a new task @Description Create a new task with title, description, priority, and due date @Tags tasks @Accept json @Produce json @Param task body models.Task true "Task data" @Success 201 {object} models.SuccessMessage "Task Created Successfully" @Failure 400 {object} models.ErrorResponse @Failure 500 {object} models.ErrorResponse @Router /tasks [post].
DeleteTask godoc @Summary Delete a task @Description Delete a task by its ID @Tags tasks @Param id path string true "Task ID" @Success 200 {object} models.SuccessMessage @Failure 404 {object} models.ErrorResponse @Failure 500 {object} models.ErrorResponse @Router /tasks/{id} [delete].
GetAllTasks godoc @Summary Get all tasks @Description Get a list of all tasks in the system @Tags tasks @Produce json @Success 200 {array} models.Task @Failure 500 {object} models.ErrorResponse @Router /tasks [get].
GetTaskByID godoc @Summary Get task by ID @Description Get task details by task ID @Tags tasks @Produce json @Param id path string true "Task ID" @Success 200 {object} models.Task @Failure 404 {object} models.ErrorResponse @Failure 500 {object} models.ErrorResponse @Router /tasks/{id} [get].
SendErrorResponse sends an error response with a custom key and error message.
UpdateTask godoc @Summary Update an existing task @Description Update task details by task ID @Tags tasks @Accept json @Produce json @Param id path string true "Task ID" @Param task body models.Task true "Task data" @Success 200 {object} models.Task @Failure 400 {object} models.ErrorResponse @Failure 404 {object} models.ErrorResponse @Failure 500 {object} models.ErrorResponse @Router /tasks/{id} [put].