form3

package
v2.8.1 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2021 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReqMimeType = "application/vnd.api+json"
	UserAgent   = "go-form3-client"
)

Variables

View Source
var ErrPEMDecode = errors.New("failed to decode PEM block containing private key")

Functions

func NewMTLSTransport added in v2.8.0

func NewMTLSTransport(opts ...MTLSOption) http.RoundTripper

Types

type ClientDefaults

type ClientDefaults struct {
	OrganisationID *strfmt.UUID
}

func NewClientDefaults

func NewClientDefaults() *ClientDefaults

func (*ClientDefaults) GetBool

func (*ClientDefaults) GetBool(objectName, attributeName string) bool

func (*ClientDefaults) GetBoolPtr

func (*ClientDefaults) GetBoolPtr(objectName, attributeName string) *bool

func (*ClientDefaults) GetFloat64

func (*ClientDefaults) GetFloat64(objectName, attributeName string) float64

func (*ClientDefaults) GetFloat64Ptr

func (*ClientDefaults) GetFloat64Ptr(objectName, attributeName string) *float64

func (*ClientDefaults) GetInt32

func (*ClientDefaults) GetInt32(objectName, attributeName string) int32

func (*ClientDefaults) GetInt64

func (*ClientDefaults) GetInt64(objectName, attributeName string) int64

func (*ClientDefaults) GetInt64Ptr

func (*ClientDefaults) GetInt64Ptr(objectName, attributeName string) *int64

func (*ClientDefaults) GetMapStringInterface added in v2.7.0

func (*ClientDefaults) GetMapStringInterface(objectName, attributeName string) map[string]interface{}

func (*ClientDefaults) GetStrfmtDate

func (*ClientDefaults) GetStrfmtDate(objectName, attributeName string) strfmt.Date

func (*ClientDefaults) GetStrfmtDatePtr

func (*ClientDefaults) GetStrfmtDatePtr(objectName, attributeName string) *strfmt.Date

func (*ClientDefaults) GetStrfmtDateTime

func (*ClientDefaults) GetStrfmtDateTime(objectName, attributeName string) strfmt.DateTime

func (*ClientDefaults) GetStrfmtDateTimePtr

func (*ClientDefaults) GetStrfmtDateTimePtr(objectName, attributeName string) *strfmt.DateTime

func (*ClientDefaults) GetStrfmtURI

func (*ClientDefaults) GetStrfmtURI(objectName, attributeName string) strfmt.URI

func (*ClientDefaults) GetStrfmtURIPtr

func (*ClientDefaults) GetStrfmtURIPtr(objectName, attributeName string) *strfmt.URI

func (*ClientDefaults) GetStrfmtUUID

func (d *ClientDefaults) GetStrfmtUUID(objectName, attributeName string) strfmt.UUID

func (*ClientDefaults) GetStrfmtUUIDPtr

func (d *ClientDefaults) GetStrfmtUUIDPtr(objectName, attributeName string) *strfmt.UUID

func (*ClientDefaults) GetString

func (*ClientDefaults) GetString(objectName, attributeName string) string

func (*ClientDefaults) GetStringArray

func (*ClientDefaults) GetStringArray(objectName, attributeName string) []string

func (*ClientDefaults) GetStringPtr

func (*ClientDefaults) GetStringPtr(objectName, attributeName string) *string

type ErrMissingEnvVariable added in v2.8.0

type ErrMissingEnvVariable struct {
	// contains filtered or unexported fields
}

func (*ErrMissingEnvVariable) Error added in v2.8.0

func (e *ErrMissingEnvVariable) Error() string

type F3

type F3 struct {
	genClient.Form3PublicAPI
	// contains filtered or unexported fields
}

func New

func New(opts ...Option) (*F3, error)

func NewFromEnv

func NewFromEnv() (*F3, error)

type MTLSOption added in v2.8.0

type MTLSOption func(transport *MTLSTransportBuilder)

func WithCertificate added in v2.8.0

func WithCertificate(c tls.Certificate) MTLSOption

func WithIgnoreSkipVerify added in v2.8.0

func WithIgnoreSkipVerify(skip bool) MTLSOption

type MTLSTransportBuilder added in v2.8.0

type MTLSTransportBuilder struct {
	// contains filtered or unexported fields
}

type Option added in v2.8.0

type Option func(*F3)

func WithBaseURL added in v2.8.0

func WithBaseURL(u url.URL) Option

func WithHTTPClient added in v2.8.0

func WithHTTPClient(c *http.Client) Option

func WithOrganisationID added in v2.8.0

func WithOrganisationID(u uuid.UUID) Option

func WithRequestSigningTransport added in v2.8.0

func WithRequestSigningTransport(opts ...RequestSigningOption) Option

func WithTokenTransport added in v2.8.0

func WithTokenTransport(opts ...TokenOption) Option

type RequestSigningOption added in v2.8.0

type RequestSigningOption func(*RequestSigningTransport)

func WithPrivateKey added in v2.8.0

func WithPrivateKey(key *rsa.PrivateKey) RequestSigningOption

func WithPublicKeyID added in v2.8.0

func WithPublicKeyID(keyID uuid.UUID) RequestSigningOption

func WithUnderlyingRequestSigningTransport added in v2.8.0

func WithUnderlyingRequestSigningTransport(tr http.RoundTripper) RequestSigningOption

type RequestSigningTransport added in v2.8.0

type RequestSigningTransport struct {
	// contains filtered or unexported fields
}

func NewRequestSigningTransport added in v2.8.0

func NewRequestSigningTransport(opts ...RequestSigningOption) *RequestSigningTransport

func (*RequestSigningTransport) RoundTrip added in v2.8.0

func (t *RequestSigningTransport) RoundTrip(req *http.Request) (*http.Response, error)

type TokenOption added in v2.8.0

type TokenOption func(*TokenTransport)

func WithClientID deprecated added in v2.8.0

func WithClientID(clientID uuid.UUID) TokenOption

Deprecated: token based authentication is deprecated and will be removed at some point in the future in favour of request signing.

func WithClientSecret deprecated added in v2.8.0

func WithClientSecret(secret string) TokenOption

Deprecated: token based authentication is deprecated and will be removed at some point in the future in favour of request signing.

func WithInitialToken deprecated added in v2.8.0

func WithInitialToken(token string) TokenOption

Deprecated: token based authentication is deprecated and will be removed at some point in the future in favour of request signing.

func WithUnderlyingTokenTransport deprecated added in v2.8.0

func WithUnderlyingTokenTransport(tr http.RoundTripper) TokenOption

Deprecated: token based authentication is deprecated and will be removed at some point in the future in favour of request signing.

type TokenTransport added in v2.8.0

type TokenTransport struct {
	// contains filtered or unexported fields
}

func NewTokenTransport deprecated added in v2.8.0

func NewTokenTransport(opts ...TokenOption) *TokenTransport

Deprecated: token based authentication is deprecated and will be removed at some point in the future in favour of request signing.

func (*TokenTransport) RoundTrip added in v2.8.0

func (t *TokenTransport) RoundTrip(req *http.Request) (*http.Response, error)

Jump to

Keyboard shortcuts

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