o2cli

package module
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2020 License: Apache-2.0, MIT Imports: 11 Imported by: 1

README

oauth2-auth-cli

Simple library for command line or other desktop apps that need to auth against OAuth2. Returns a *oauth2.Token, but doesn't care to handle refreshes. If you want an authenticated HTTP Client, try https://github.com/nmrshll/oauth2-noserver

Specify an static port with the option.

Thanks

This project borrows heavily from two other projects:

Thank you to both!

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Authorize

func Authorize(conf *oauth2.Config) (*oauth2.Token, error)

Types

type Oauth2CLI

type Oauth2CLI struct {
	Log  *logrus.Logger
	Port uint
	Conf *oauth2.Config
}

func (*Oauth2CLI) Authorize

func (o *Oauth2CLI) Authorize() (*oauth2.Token, error)

Jump to

Keyboard shortcuts

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