Documentation ¶
Overview ¶
Package auth provides configuration fields and implementations of HTTP request authentication strategies.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BasicAuthConfig ¶
type BasicAuthConfig struct { Enabled bool `json:"enabled" yaml:"enabled"` Username string `json:"username" yaml:"username"` Password string `json:"password" yaml:"password"` }
BasicAuthConfig contains fields for setting basic authentication in HTTP requests.
func NewBasicAuthConfig ¶
func NewBasicAuthConfig() BasicAuthConfig
NewBasicAuthConfig returns a default configuration for basic authentication in HTTP client requests.
type Config ¶
type Config struct { OAuth OAuthConfig `json:"oauth" yaml:"oauth"` BasicAuth BasicAuthConfig `json:"basic_auth" yaml:"basic_auth"` }
Config contains configuration params for various HTTP auth strategies.
type OAuthConfig ¶
type OAuthConfig struct { Enabled bool `json:"enabled" yaml:"enabled"` ConsumerKey string `json:"consumer_key" yaml:"consumer_key"` ConsumerSecret string `json:"consumer_secret" yaml:"consumer_secret"` AccessToken string `json:"access_token" yaml:"access_token"` AccessTokenSecret string `json:"access_token_secret" yaml:"access_token_secret"` RequestURL string `json:"request_url" yaml:"request_url"` }
OAuthConfig holds the configuration parameters for an OAuth exchange.
func NewOAuthConfig ¶
func NewOAuthConfig() OAuthConfig
NewOAuthConfig returns a new OAuthConfig with default values.
Click to show internal directories.
Click to hide internal directories.