Versions in this module Expand all Collapse all v1 v1.38.0 Jun 22, 2026 Changes in this version + var ErrProviderNotSet = errors.New("auth provider not set, please login") + var ErrProviderUnknown = errors.New("auth provider is unknown, please login") + var RadixAPIScopes = []string + type AccessToken struct + ExpiresOn time.Time + Token string + type Auth struct + func New() (*Auth, error) + func (a *Auth) GetAccessToken(ctx context.Context, scopes []string) (AccessToken, error) + func (a *Auth) Login(ctx context.Context, ...) error + func (a *Auth) Logout() error + type AzureClientSecret struct + Authority string + func NewAzureClientSecret(cache cache.Cache, authority string) *AzureClientSecret + func (p *AzureClientSecret) Authenticate(ctx context.Context, azureClientId, azureClientSecret string, scopes []string) (AccessToken, error) + func (p *AzureClientSecret) GetAccessToken(ctx context.Context, scopes []string) (AccessToken, error) + type AzureFederatedCredentials struct + func NewAzureFederatedCredentials(cache cache.Cache) *AzureFederatedCredentials + func (p *AzureFederatedCredentials) Authenticate(ctx context.Context, azureClientId, federatedTokenFile string, scopes []string) (AccessToken, error) + func (p *AzureFederatedCredentials) GetAccessToken(ctx context.Context, scopes []string) (AccessToken, error) + type AzureGithub struct + func NewAzureGithub(cache cache.Cache, authority string) *AzureGithub + func (p *AzureGithub) Authenticate(ctx context.Context, azureClientId string, scopes []string) (AccessToken, error) + func (p *AzureGithub) GetAccessToken(ctx context.Context, scopes []string) (AccessToken, error) + type GetAccessTokener interface + GetAccessToken func(ctx context.Context, scopes []string) (AccessToken, error) + type MsalDeviceCode struct + func NewMsalDeviceCode(cache msalcache.ExportReplace, authority string) *MsalDeviceCode + func (p *MsalDeviceCode) Authenticate(ctx context.Context, scopes []string) (AccessToken, error) + func (p *MsalDeviceCode) GetAccessToken(ctx context.Context, scopes []string) (AccessToken, error) + type MsalInteractive struct + func NewMsalInteractive(cache msalcache.ExportReplace, authority string) *MsalInteractive + func (p *MsalInteractive) Authenticate(ctx context.Context, scopes []string) (AccessToken, error) + func (p *MsalInteractive) GetAccessToken(ctx context.Context, scopes []string) (AccessToken, error) + type MsalTokenCache struct + func NewMsalTokenCache(cache cache.Cache, key string) *MsalTokenCache + func (t *MsalTokenCache) Export(ctx context.Context, cache azurecache.Marshaler, hints azurecache.ExportHints) error + func (t *MsalTokenCache) Replace(ctx context.Context, cache azurecache.Unmarshaler, ...) error + type Provider interface + Login func(ctx context.Context, ...) error + Logout func() error