account

package
v0.0.0-...-a8c3d02 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotFound = &jonson.Error{Code: 10000, Message: "Account not found"}
View Source
var TypePrivate = reflect.TypeOf((**Private)(nil)).Elem()

provider.authorization.go:6 -- Private -- struct

View Source
var TypePublic = reflect.TypeOf((**Public)(nil)).Elem()

provider.authorization.go:14 -- Public -- struct

Functions

This section is empty.

Types

type Account

type Account struct{}

func NewAccount

func NewAccount() *Account

func (*Account) GetProfileV1

func (a *Account) GetProfileV1(ctx *jonson.Context, caller *Public, _ jonson.HttpPost, params *GetProfileV1Params) (*GetProfileV1Result, error)

func (*Account) MeV1

func (a *Account) MeV1(ctx *jonson.Context, caller *Private, _ jonson.HttpGet) (*MeV1Result, error)

func (*Account) ProcessV1

func (a *Account) ProcessV1(ctx *jonson.Context, caller *Public, _ jonson.HttpGet) error

type AuthenticationProvider

type AuthenticationProvider struct {
}

func NewAuthenticationProvider

func NewAuthenticationProvider() *AuthenticationProvider

func (*AuthenticationProvider) NewPrivate

func (p *AuthenticationProvider) NewPrivate(ctx *jonson.Context) *Private

func (*AuthenticationProvider) NewPublic

func (p *AuthenticationProvider) NewPublic(ctx *jonson.Context) *Public

type GetProfileV1Params

type GetProfileV1Params struct {
	jonson.Params
	Uuid string `json:"uuid"`
}

func (*GetProfileV1Params) JonsonValidate

func (g *GetProfileV1Params) JonsonValidate(v *jonson.Validator)

type GetProfileV1Result

type GetProfileV1Result struct {
	Name string `json:"name"`
}

func GetProfileV1

func GetProfileV1(ctx *jonson.Context, p *GetProfileV1Params) (*GetProfileV1Result, error)

account.go:42 -- GetProfileV1

type MeV1Result

type MeV1Result struct {
	Uuid string `json:"uuid"`
	Name string `json:"name"`
}

func MeV1

func MeV1(ctx *jonson.Context) (*MeV1Result, error)

account.go:20 -- MeV1

type Private

type Private struct {
}

@generate

func RequirePrivate

func RequirePrivate(ctx *jonson.Context) *Private

func (*Private) AccountUuid

func (p *Private) AccountUuid() string

type Public

type Public struct {
}

@generate

func RequirePublic

func RequirePublic(ctx *jonson.Context) *Public

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳