Documentation
¶
Overview ¶
Package httpx is the HTTP plumbing adapters share: base URLs from svc:// addresses, JSON calls with auth.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Default = &http.Client{Timeout: 30 * time.Second}
Functions ¶
This section is empty.
Types ¶
type Endpoint ¶
type Endpoint struct {
Addr string `yaml:"addr"`
User string `yaml:"user"`
Password string `yaml:"password"`
Token string `yaml:"token"`
Headers map[string]string `yaml:"headers"`
}
Endpoint is an HTTP API an adapter talks to, given as a URL or svc://service:port.
func (Endpoint) Base ¶
Base resolves the address through env and returns it with a scheme and without a trailing slash.
Click to show internal directories.
Click to hide internal directories.