shorturl

package
v0.0.0-...-4af809f Latest Latest
Warning

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

Go to latest
Published: May 21, 2023 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	Router *mux.Router
}

func (*App) Initialize

func (app *App) Initialize() error

func (*App) InitializeRouter

func (app *App) InitializeRouter()

func (*App) Run

func (app *App) Run(addr string)

type CreateShortUrlReq

type CreateShortUrlReq struct {
	Url           string `json:"url" validate:"required"`
	ExpireSeconds int64  `json:"expire_seconds" validate:"min=0"`
}

type CreateShortUrlRsp

type CreateShortUrlRsp struct {
	Code     int    `json:"code"`
	Msg      string `json:"msg"`
	ShortUrl string `json:"short_url"`
}

type GetUrlInfoRsp

type GetUrlInfoRsp struct {
	Code int                   `json:"code"`
	Msg  string                `json:"msg"`
	Info *entity.UrlDetailInfo `json:"info"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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