credentials

package
v1.0.0-beta.1 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuraCredential

type AuraCredential struct {
	Name         string `json:"name"`
	ClientId     string `json:"client-id"`
	ClientSecret string `json:"client-secret"`
	AccessToken  string `json:"access-token"`
	TokenExpiry  int64  `json:"token-expiry"`
}

func (*AuraCredential) HasValidAccessToken

func (credential *AuraCredential) HasValidAccessToken() bool

type AuraCredentials

type AuraCredentials struct {
	DefaultCredential string            `json:"default-credential"`
	Credentials       []*AuraCredential `json:"credentials"`
	// contains filtered or unexported fields
}

func (*AuraCredentials) Add

func (c *AuraCredentials) Add(name string, clientId string, clientSecret string) error

func (*AuraCredentials) ClearAccessToken

func (c *AuraCredentials) ClearAccessToken(cred *AuraCredential) (*AuraCredential, error)

func (*AuraCredentials) Get

func (c *AuraCredentials) Get(name string) (*AuraCredential, error)

func (*AuraCredentials) GetDefault

func (c *AuraCredentials) GetDefault() (*AuraCredential, error)

func (*AuraCredentials) List

func (c *AuraCredentials) List() []*AuraCredential

func (*AuraCredentials) Print

func (config *AuraCredentials) Print(writer io.Writer) error

func (*AuraCredentials) Remove

func (c *AuraCredentials) Remove(name string) error

func (*AuraCredentials) SetDefault

func (c *AuraCredentials) SetDefault(name string) error

func (*AuraCredentials) UpdateAccessToken

func (c *AuraCredentials) UpdateAccessToken(cred *AuraCredential, accessToken string, expiresInSeconds int64) *AuraCredential

type Credentials

type Credentials struct {
	Aura *AuraCredentials
	// contains filtered or unexported fields
}

func NewCredentials

func NewCredentials(fs afero.Fs, configPrefix string) *Credentials

type CredentialsFile

type CredentialsFile struct {
	Aura *AuraCredentials `json:"aura"`
}

Jump to

Keyboard shortcuts

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