auth

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2022 License: MIT Imports: 9 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Grant

type Grant struct {
	ExpiresIn   int    `json:"expires_in"`
	AccessToken string `json:"access_token"`
}

Grant represents the grant response returned by the token endpoint

type TokenSource

type TokenSource interface {
	TokenString() (token string, err error)
}

TokenSource is similar to rsauth TokenSource -- it generates JWT bearer tokens.

func NewOAuthAuthenticator

func NewOAuthAuthenticator(host string, refreshToken string) (TokenSource, error)

NewOAuthAuthenticator returns a authenticator that uses a oauth refresh token to create access tokens. The refresh token can be found in the CM dashboard under Settings > Account Settings > API Credentials.

Jump to

Keyboard shortcuts

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