Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { // HCPConfig contains values that allow to interact with HCP APIs. config.HCPConfig // HostPath is the host name of the HCP API, without a scheme prefix. // // Deprecated: HCPConfig should be used instead HostPath string `json:"host_path"` // AuthURL is the URL of the authentication provider, inclusive of the 'https' scheme prefix. // // Deprecated: HCPConfig should be used instead AuthURL string `json:"auth_url"` // ClientID is the client ID of a Service Principal Key. // // Deprecated: HCPConfig should be used instead ClientID string `json:"client_id"` // ClientSecret is the client secret of a Service Principal Key, only provided on creation. // // Deprecated: HCPConfig should be used instead ClientSecret string `json:"client_secret"` // SourceChannel denotes the client (channel) that originiated the request. // This is synonymous to a user-agent. SourceChannel string `json:"source_channel"` // Client allows passing a custom http.Client to be used instead of the // cleanhttp default one for both Auth and API requests. This should be used only for testing // in testing to provide the httptest.Server's custom client that will trust // its TLS cert. // // Deprecated: HCPConfig should be used instead Client *http.Client }
Config contains the client's configuration options
func (*Config) Canonicalize ¶
Canonicalize populates default values for config fields that are otherwise unset.
type MiddlewareOption ¶ added in v0.30.0
MiddlewareOption is a function that modifies an HTTP request.
Click to show internal directories.
Click to hide internal directories.