osc

package
v0.0.0-...-115e584 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2021 License: Apache-2.0, GPL-3.0, GPL-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AuthCodeURL

func AuthCodeURL(params map[string]string) string

Types

type UserInfo

type UserInfo struct {
	Id       int64  `json:"id"`
	Email    string `json:"email"`
	Name     string `json:"name"`
	Gender   string `json:"gender"`
	Avatar   string `json:"avatar"`
	Location string `json:"location"`
	Url      string `json:"url"`
}

func GetUserInfo

func GetUserInfo(accessToken string) (*UserInfo, error)

GetUserInfo 根据accessToken获取用户信息

func GetUserInfoByCode

func GetUserInfoByCode(code, state string) (*UserInfo, error)

GetUserInfoByCode 根据code获取用户信息 流程为先使用code换取accessToken,然后根据accessToken获取用户信息

Jump to

Keyboard shortcuts

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