Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterHandler ¶
func RegisterHandler(db *sql.DB) http.HandlerFunc
@Summary Register a new user @Description Register a new user @Tags users @Accept json @Produce json @Param user body models.RegisterRequest true "User" @Success 200 {object} string @Failure 409 {object} string @Failure 500 {object} string @Router /register [post]
func VaultHandler ¶
func VaultHandler(db *sql.DB) http.HandlerFunc
@Summary Upload a vault @Description Upload a vault @Tags vault @Accept multipart/form-data @Produce json @Param username path string true "Username" @Param file formData file true "File to upload" @Success 200 {object} string @Failure 400 {object} string "Unable to parse form or file too big" @Failure 401 {object} string "Unauthorized" @Failure 409 {object} string @Failure 500 {object} string @Router /vault/{username} [post]
Types ¶
This section is empty.