oauth

package
v0.0.0-...-e7846b9 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2019 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Auth

type Auth struct {
	// contains filtered or unexported fields
}

Auth is the provider

func New

func New(appid string, appsecret string) *Auth

New 构造 OAuth 方法

func (*Auth) GetAccessToken

func (a *Auth) GetAccessToken(code string)

GetAccessToken 根据授权获取到的code,换取access token和openid

func (*Auth) GetAuthorizeURL

func (a *Auth) GetAuthorizeURL(redirect string, state string, scope string) string

GetAuthorizeURL 获取授权页面的URL地址

Jump to

Keyboard shortcuts

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