handlers

package
v0.0.0-...-eb26ef5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 3, 2024 License: MIT Imports: 15 Imported by: 0

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.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL