api

package
v0.0.0-...-598afe9 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2019 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package api provides all useful API for frontend. A frontend should call required API through HTTP requests.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ActivateUser

func ActivateUser(c *gin.Context)

func BanUser

func BanUser(c *gin.Context)

func GetProfile

func GetProfile(c *gin.Context)

func LoginByJWT

func LoginByJWT(c *gin.Context)

Login by email address or cellphone number.

func LoginBySession

func LoginBySession()

func LogoutByJWT

func LogoutByJWT(c *gin.Context)

func LogoutBySession

func LogoutBySession()

func RefreshToken

func RefreshToken(c *gin.Context)

func Register

func Register(c *gin.Context)

func RestrictUser

func RestrictUser(c *gin.Context)

func UpdateProfile

func UpdateProfile(c *gin.Context)

func UploadAvatar

func UploadAvatar(c *gin.Context)

Types

type Response

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

Jump to

Keyboard shortcuts

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