Documentation ¶
Index ¶
- func DecodeAuthenticationStrategyHookFunc() mapstructure.DecodeHookFunc
- type APIKeyStrategy
- type AuthenticationStrategy
- type BasicAuthStrategy
- type ClientCredentialsStrategy
- type Endpoint
- func (e Endpoint) CreateClient(peerName string) *http.Client
- func (e Endpoint) CreateRequest(ctx context.Context, body io.Reader, rndr renderer.Renderer) (*http.Request, error)
- func (e Endpoint) Hash() string
- func (e Endpoint) SendRequest(ctx context.Context, body io.Reader, renderer renderer.Renderer) ([]byte, error)
- func (e Endpoint) Validate() error
- type Retry
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeAuthenticationStrategyHookFunc ¶
func DecodeAuthenticationStrategyHookFunc() mapstructure.DecodeHookFunc
Types ¶
type APIKeyStrategy ¶
type APIKeyStrategy struct { In string `mapstructure:"in"` Name string `mapstructure:"name"` Value string `mapstructure:"value"` }
func (*APIKeyStrategy) Hash ¶
func (c *APIKeyStrategy) Hash() string
type AuthenticationStrategy ¶
type BasicAuthStrategy ¶
type BasicAuthStrategy struct { User string `mapstructure:"user"` Password string `mapstructure:"password"` }
func (*BasicAuthStrategy) Hash ¶
func (c *BasicAuthStrategy) Hash() string
type ClientCredentialsStrategy ¶
type ClientCredentialsStrategy struct { ClientID string `mapstructure:"client_id"` ClientSecret string `mapstructure:"client_secret"` Scopes []string `mapstructure:"scopes"` TokenURL string `mapstructure:"token_url"` }
func (*ClientCredentialsStrategy) Hash ¶
func (c *ClientCredentialsStrategy) Hash() string
type Endpoint ¶
type Endpoint struct { URL string `mapstructure:"url"` Method string `mapstructure:"method"` Retry *Retry `mapstructure:"retry"` AuthStrategy AuthenticationStrategy `mapstructure:"auth"` Headers map[string]string `mapstructure:"headers"` }
func (Endpoint) CreateRequest ¶
func (Endpoint) SendRequest ¶
Click to show internal directories.
Click to hide internal directories.