client

package
v0.4.12 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Organization     string
	APIToken         string
	APIServer        string
	APIPrefix        string
	Debug            bool
	TLSNoVerify      bool
	TimeoutSeconds   int
	RetryCount       int
	RetryWaitSeconds float64
	Headers          []string
}

type Interface

type Interface interface {
	Post(path string, body *jnode.Node, options ...Option) (*jnode.Node, error)
	Patch(path string, body *jnode.Node, options ...Option) (*jnode.Node, error)
	Get(path string, options ...Option) (*jnode.Node, error)
	GetWithParams(path string, params map[string]string, options ...Option) (*jnode.Node, error)
	Delete(path string, options ...Option) (*jnode.Node, error)
	GetClient() *resty.Client
}

func NewClient

func NewClient(config *Config) Interface

type Option

type Option func(*resty.Request)

Jump to

Keyboard shortcuts

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