handler

package
v0.0.0-...-1d517b5 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BulkDeleteUrls

func BulkDeleteUrls(c *fiber.Ctx) error

/ Example request: {"urls_ids": ["url_id1", "url_id2"]}

func CreateUrl

func CreateUrl(c *fiber.Ctx) error

/ Example request: {"name": "example", "long": "https://example.com", "alias": "example", "expires_at": "2022-01-01T00:00:00Z"} / Example response: {"status": "success", "message": "Url created", "data": {"ID":1,"CreatedAt":"2021-09-26T14:00:00Z","UpdatedAt":"2021-09-26T14:00:00Z","

func DeleteUrl

func DeleteUrl(c *fiber.Ctx) error

func GetStats

func GetStats(c *fiber.Ctx) error

func GetUrls

func GetUrls(c *fiber.Ctx) error

func Login

func Login(c *fiber.Ctx) error

func RedirectToUrl

func RedirectToUrl(c *fiber.Ctx) error

func Register

func Register(c *fiber.Ctx) error

func UpdateUrl

func UpdateUrl(c *fiber.Ctx) error

/ Example request: {"active": true, "alias": "example", "name": "example", "long": "https://example.com", "expires_at": "2022-01-01T00:00:00Z"}

Types

type UserCredentials

type UserCredentials struct {
	Email    string `json:"email"`
	Password string `json:"password"`
}

Jump to

Keyboard shortcuts

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