GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - leo0o/simpleoauth: Golang实现几大主流平台的oauth2.0认证(目前仅支持QQ,微信,微博)

BranchesTags
Open more actions menu

Latest commit

 

History

10 Commits
10 Commits

Folders and files

NameName
Last commit message
Last commit date
example
example
 
 
vendor/httplib
vendor/httplib
 
 
README.md
README.md
 
 
config.go
config.go
 
 
oauth.go
oauth.go
 
 
oauth_qq.go
oauth_qq.go
 
 
oauth_test.go
oauth_test.go
 
 
oauth_wechat.go
oauth_wechat.go
 
 
oauth_weibo.go
oauth_weibo.go
 
 

Repository files navigation

simpleoauth

Golang实现几大主流平台的oauth2.0认证(目前仅支持QQ,微信,微博)

使用方法: 在config.go中配置好相关信息后

package main

 import (
 	"fmt"
 	"simpleoauth"
 )

 func main() {
 	m, _ := simpleoauth.NewManager("qq")
 	result := m.Authorize("此处填入认证通过后,第三方平台跳转带回来的CODE")
 	fmt.Println(result)
 }

返回结果为:

type AuthorizeResult struct{
    Result bool                         //认证成功或失败
    Userinfo map[string]interface{}     //返回用户信息等基本资料
}

About

Golang实现几大主流平台的oauth2.0认证(目前仅支持QQ,微信,微博)

Topics

gogolangoauth2qqwechat

Resources

Readme
Activity

Stars

32 stars

Watchers

1 watching

Forks

4 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.