auth

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2020 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OAuthFlow

type OAuthFlow struct {
	Hostname         string
	ClientID         string
	ClientSecret     string
	Scopes           []string
	OpenInBrowser    func(string, string) error
	WriteSuccessHTML func(io.Writer)
	VerboseStream    io.Writer
	HTTPClient       *http.Client
	TimeNow          func() time.Time
	TimeSleep        func(time.Duration)
}

OAuthFlow represents the setup for authenticating with GitHub

func (*OAuthFlow) ObtainAccessToken

func (oa *OAuthFlow) ObtainAccessToken() (accessToken string, err error)

ObtainAccessToken guides the user through the browser OAuth flow on GitHub and returns the OAuth access token upon completion.

Jump to

Keyboard shortcuts

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