ums

package
v1.4.2 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// AppID appid
	AppID string

	// AppKey app key
	AppKey string
)

Functions

This section is empty.

Types

type Request

type Request struct {
	AppID      string `json:"appId,omitempty"`      // 是 AppId
	Timestamp  string `json:"timestamp,omitempty"`  // 是 时间戳
	Nonce      string `json:"nonce,omitempty"`      // 是 随机数
	SignMethod string `json:"signMethod,omitempty"` // 是 签名方法
	Signature  string `json:"signature,omitempty"`  // 是 签名
}

Request request

type Response

type Response struct {
	ErrCode     string `json:"errCode,omitempty"`     // 是 错误代码
	ErrInfo     string `json:"errInfo,omitempty"`     // 是 错误说明
	AccessToken string `json:"accessToken,omitempty"` // 是 授权令牌
	ExpiresIn   int    `json:"expiresIn,omitempty"`   // 是 失效时间
}

Response response

type Token

type Token struct{}

Token token

func NewToken

func NewToken() *Token

NewToken new token

func (*Token) Access

func (t *Token) Access() (string, error)

Access access token

func (*Token) Get added in v1.3.7

func (t *Token) Get() (*Response, error)

Jump to

Keyboard shortcuts

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