options

package
v0.15.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 29, 2024 License: Apache-2.0 Imports: 10 Imported by: 1

Documentation

Overview

Package options is a library of common remote.Options that are useful for modifying the behavior of a remote.Transaction.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Authorization

func Authorization(auth string) remote.Option

Authorization is remote.Option that adds a HTTP "Authorization" header to every request.

func BasicAuth

func BasicAuth(username, password string) remote.Option

BasicAuth is a remote.Option that sets the value of a HTTP header for basic Authentication

func Debug

func Debug() remote.Option

Debug is a remote.Option that adds debugging output to every request.

func Opaque

func Opaque(opaqueValue string) remote.Option

Opaque is a remote.Option that modifies the raw URL string before it is sent to the server. This can be useful when the server requires odd characters in the URL string to NOT be urlencoded. (e.g. Such as the REST API for LinkedIn)

Additional documentation can be found at http://golang.org/pkg/net/url/#URL

func TestServer

func TestServer(hostname string, filesystem fs.FS) remote.Option

TestServer is a remote.Option that mocks requests for a specific hostname.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL