Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ValidateCredentials ¶
ValidateCredentials attempts a token refresh to verify credentials are valid.
Types ¶
type Authenticator ¶
Authenticator handles OAuth2 token management.
type OAuthAuthenticator ¶
type OAuthAuthenticator struct {
// contains filtered or unexported fields
}
OAuthAuthenticator refreshes access tokens using OAuth2 credentials.
func NewOAuthAuthenticator ¶
func NewOAuthAuthenticator(clientID, clientSecret, refreshToken string) *OAuthAuthenticator
NewOAuthAuthenticator creates an authenticator from client credentials and a refresh token.
func (*OAuthAuthenticator) AccessToken ¶
func (a *OAuthAuthenticator) AccessToken(ctx context.Context) (string, error)
AccessToken returns a valid access token, refreshing if necessary.
Click to show internal directories.
Click to hide internal directories.