auth

package
v0.23.0 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: MIT Imports: 2 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Credential

type Credential interface {
	Token(ctx context.Context, options ...TokenOption) (Token, error)
}

Credential is the interface that wraps around method Token.

type Token

type Token struct {
	ExpiresOn   time.Time
	AccessToken string
}

Token contains the access token and when it expires.

type TokenOption added in v0.10.0

type TokenOption func(o *TokenOptions)

TokenOption is a function that sets options for a token request.

func WithScope added in v0.10.0

func WithScope(scope string) TokenOption

WithScope sets the scope of the token request.

type TokenOptions added in v0.10.0

type TokenOptions struct {
	Scope string
}

TokenOptions contains options for a token request.

Jump to

Keyboard shortcuts

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