auth

package
v0.16.2 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2022 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Login

func Login(s *server.Server) gin.HandlerFunc

func Logout

func Logout(s *server.Server) gin.HandlerFunc

func NewService

func NewService(g *server.RouterGroup)

Types

type LoginReply

type LoginReply struct {
	Success bool   `json:"success"`
	Message string `json:"message"`
}

LoginReply defines the reply from /api/auth/login

type LoginRequest

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

LoginRequest defines the request to /api/auth/login

type LogoutReply

type LogoutReply struct {
	Success bool `json:"success"`
}

LogoutReply defines the reply from /api/auth/logout

Jump to

Keyboard shortcuts

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