feat: added swaggo support

This commit is contained in:
Robin Dittmar
2026-07-28 14:41:49 +02:00
parent cb14374d09
commit 2e1fbc6e68
7 changed files with 80 additions and 6 deletions
+12
View File
@@ -17,6 +17,18 @@ func NewListHandler(listService *domain.ListService) *ListHandler {
return &ListHandler{ListService: listService}
}
// CreateList handles the creation of a list
//
// @Summary Create list route
// @Description Create a list and associate user(s) to it
// @Tags List
// @Accept json
// @Produce json
// @Param payload body request.CreateListPayload true "Create list payload"
// @Success 201 {object} domain.List
// @Error 400 {object} response.ErrorResponse "failed to decode request body"
// @Error 500 {object} response.ErrorResponse "failed to create list"
// @Router /api/v1/list [post]
func (h *ListHandler) CreateList(w http.ResponseWriter, r *http.Request) {
ctx := r.Context()