Documentation ¶
Index ¶
- type Config
- func (c Config) Client() (*http.Client, error)
- func (c *Config) CredsFilePath() (string, error)
- func (c Config) DeleteTempCredsFile() error
- func (c Config) GetOAuthCodeURL() string
- func (c Config) JWTConfig() (conf *jwt.Config, err error)
- func (c Config) NewContext() context.Context
- func (c Config) NewOAuthClient() (*http.Client, error)
- func (c Config) TokenSource(ctx context.Context) (oauth2.TokenSource, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // by parameter Email string PrivateKey string // by file Filename string // by OAuth setting NoOAuthClient bool // for multiple config and avoid to use environment value. OAuthClientID string OAuthClientSecret string OAuthRefreshToken string OAuthRedirectURL string OAuthCode string OAuthTokenFile string OAuthCredsFile string Scopes []string TokenURL string Timeout time.Duration CredsJSONBody string UseTempCredsFile bool UseIAMRole bool NoUseIAMRole bool // for multiple config and avoid to use environment value. // contains filtered or unexported fields }
func (*Config) CredsFilePath ¶ added in v0.5.0
CredsFilePath returns credential file path. if UseTempCredsFile is true, then temporary creds json file will be created.
func (Config) DeleteTempCredsFile ¶ added in v0.5.0
DeleteTempCredsFile deletes temporary creds json file.
func (Config) GetOAuthCodeURL ¶ added in v0.7.0
GetOAuthCodeURL returns URL to get oauth code.
func (Config) NewContext ¶
func (Config) NewOAuthClient ¶ added in v0.7.0
NewOAuthClient creates http.Client from OAuth parameters.
func (Config) TokenSource ¶ added in v0.8.0
Click to show internal directories.
Click to hide internal directories.