token

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create

func Create(token *model.Token) error

func DecreaseQuota

func DecreaseQuota(id string, quota int64) error

func DecreaseQuotaDirect

func DecreaseQuotaDirect(id string, quota int64) error

func Delete

func Delete(token *model.Token) error

func DeleteByID

func DeleteByID(tokenId, userId string) error

func GetAll

func GetAll(userId string, start, num int, order string) ([]*model.Token, error)

func GetByID

func GetByID(tokenId string) (*model.Token, error)

func GetByIDs

func GetByIDs(tokenId, userId string) (*model.Token, error)

func GetFirstAvailable

func GetFirstAvailable(userId string) (*model.Token, error)

func IncreaseQuota

func IncreaseQuota(id string, quota int64) error

func IncreaseQuotaDirect

func IncreaseQuotaDirect(id string, quota int64) error
func Search(userId string, keyword string) ([]*model.Token, error)

func SelectUpdate

func SelectUpdate(token *model.Token) error

func Update

func Update(token *model.Token) error

func ValidateUserToken

func ValidateUserToken(key string) (*model.Token, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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