Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Parameter ¶
type Parameter interface {
// contains filtered or unexported methods
}
Parameter is the interface for service parameters.
func WithCACert ¶
WithCACert sets the certificate authority certificate for HTTPS requests.
func WithClientCert ¶
WithClientCert sets the client certificate for HTTPS requests.
func WithClientKey ¶
WithClientKey sets the client Key for HTTPS requests.
func WithLogLevel ¶
WithLogLevel sets the log level for the module.
type Service ¶
type Service struct{}
Service returns the values from an HTTP connection. This service handles URLs with the scheme "http" and "https". It returns the file at the URL as the value. For example a URL "http://www.example.com/secret.txt" will return the contents of the file "secret.txt" on the server "www.example.com" Additional information, such as certificates, can be passed as context values. The available values are: - CACert a certificate authority certificate, as a byte slice - ClientCert a client certificate, as a byte slice - ClientKey a client key, as a byte slice - HTTPMethod the HTTP method, as a string (e.g. http.MethodPost) - MIMEType the MIME type for request and response, as a string (e.g. application/json) - Body the request body, as a byte slice