Skip to content

lastbackend/vendors

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vendors for Go

Installation

go get github.com/lastbackend/vendors

Usage

import "github.com/lastbackend/vendors"

Get client for github

var client = vendors.GetGitHub(clientID, clientSecretID, redirectURI)

Get token using auth code

token, err := client.GetToken(code)
if err != nil {
    return err
}

Get user information use token

user, err := client.GetUser(token)
if err != nil {
    return err
}