auth

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 14, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"

Variables

This section is empty.

Functions

This section is empty.

Types

type ADCProvider

type ADCProvider struct {
	// contains filtered or unexported fields
}

ADCProvider uses Google Application Default Credentials.

func NewADCProvider

func NewADCProvider(ctx context.Context) (*ADCProvider, error)

func NewTokenSourceProvider

func NewTokenSourceProvider(source oauth2.TokenSource) *ADCProvider

func (*ADCProvider) Token

func (p *ADCProvider) Token(ctx context.Context) (string, error)

type TokenProvider

type TokenProvider interface {
	Token(ctx context.Context) (string, error)
}

func NewProvider added in v0.2.0

func NewProvider(ctx context.Context, cfg config.AuthConfig) (TokenProvider, error)

NewProvider creates a TokenProvider based on the auth configuration.

Jump to

Keyboard shortcuts

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