api

package
v0.0.0-...-cf2fa2e Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2024 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StatusOk                  = fiber.StatusOK
	StatusRangeNotSatisfiable = fiber.StatusRequestedRangeNotSatisfiable
	StatusPartialContent      = fiber.StatusPartialContent
	StatusBadRequest          = fiber.StatusBadRequest
	StatusNotFound            = fiber.StatusNotFound
	StatusForbidden           = fiber.StatusForbidden
	StatusUnauthorized        = fiber.StatusUnauthorized
	StatusCreated             = fiber.StatusCreated
)
View Source
const (
	ErrBadRequest          = "bad request body"
	ErrUnauthorized        = "authorization failed"
	ErrBadUsernamePassword = "invalid username or password"
)

Variables

This section is empty.

Functions

func AuthConfigHandler

func AuthConfigHandler() fiber.Handler

func AuthHandler

func AuthHandler() fiber.Handler

func CheckTokenHandler

func CheckTokenHandler() fiber.Handler

func CreateDirHandler

func CreateDirHandler() fiber.Handler

func CreateFileHandler

func CreateFileHandler(driver *ddrv.Driver) fiber.Handler

func DelDirHandler

func DelDirHandler() fiber.Handler

func DelFileHandler

func DelFileHandler() fiber.Handler

func DownloadFileHandler

func DownloadFileHandler(driver *ddrv.Driver) fiber.Handler

func GetDirHandler

func GetDirHandler() fiber.Handler

func GetFileHandler

func GetFileHandler() fiber.Handler

func Load

func Load(app *fiber.App, driver *ddrv.Driver)

func LoginHandler

func LoginHandler() fiber.Handler

func UpdateDirHandler

func UpdateDirHandler() fiber.Handler

func UpdateFileHandler

func UpdateFileHandler() fiber.Handler

Types

type Directory

type Directory struct {
	*dp.File
	Files []*dp.File `json:"files"`
}

type Response

type Response struct {
	Message string      `json:"message"`
	Data    interface{} `json:"data,omitempty"`
}

type User

type User struct {
	Username string `json:"username"`
	Password string `json:"password"`
}

Jump to

Keyboard shortcuts

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