Documentation
¶
Index ¶
- func CreateList(writer http.ResponseWriter, request *http.Request)
- func DeleteList(writer http.ResponseWriter, request *http.Request)
- func GetHealth(writer http.ResponseWriter, request *http.Request)
- func GetList(writer http.ResponseWriter, request *http.Request)
- func GetLists(writer http.ResponseWriter, request *http.Request)
- func UpdateList(writer http.ResponseWriter, request *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateList ¶
func CreateList(writer http.ResponseWriter, request *http.Request)
CreateList godoc @Summary Creates a list @Description Creates a list @Accept json @Produce json @Param userId path string true "The user id of the user" @Param list body models.List true "The value of the list" @Success 201 {object} models.List "The created list" @Router /user/{userId}/lists [post]
func DeleteList ¶
func DeleteList(writer http.ResponseWriter, request *http.Request)
DeleteList godoc @Summary Deletes a specific list of a user @Description Deletes a specific list of a user @Param userId path string true "The user id of the user" @Param listId path string true "The id of the list to update" @Success 204 "deleted successfully" @Failure 404 "list with the specified id does not exist" @Router /user/{userId}/lists/{listId} [delete]
func GetList ¶
func GetList(writer http.ResponseWriter, request *http.Request)
GetList godoc @Summary Gets a specific list of a user @Description Gets a specific list of a user @Produce json @Param userId path string true "The user id of the user" @Param listId path string true "The id of the list to get" @Success 200 {object} models.List @Failure 404 "list with the specified id does not exist" @Router /user/{userId}/lists/{listId} [get]
func GetLists ¶
func GetLists(writer http.ResponseWriter, request *http.Request)
GetLists godoc @Summary Gets all lists for a user @Description Gets all lists for a user @Produce json @Param userId path string true "The user id of the user" @Success 200 {array} models.List @Failure 404 "The user does not have any lists" @Router /user/{userId}/lists [get]
func UpdateList ¶
func UpdateList(writer http.ResponseWriter, request *http.Request)
UpdateList godoc @Summary Updates a specific list of a user @Description Updates a specific list of a user @Accept json @Param userId path string true "The user id of the user" @Param listId path string true "The id of the list to update" @Param list body models.List true "The new value of the list" @Success 202 "updated successfully" @Failure 404 "list with the specified id does not exist" @Router /user/{userId}/lists/{listId} [put]
Types ¶
This section is empty.