Versions in this module Expand all Collapse all v0 v0.0.6 Oct 3, 2023 Changes in this version + func PrintRequestHeaders(req *http.Request) + type Authenticator interface + Authenticate func(c *Client) error + type BasicAuthConfig struct + Password string + Username string + func (b BasicAuthConfig) Authenticate(c *Client) error + type Client struct + ExtraHeader map[string]string + HttpClient *http.Client + HttpRetryTimeout time.Duration + func NewClient(cfg Config) (*Client, error) + func (c *Client) DoRawRequest(api string, params *url.Values) (string, error) + func (c *Client) DoRequest(method, api string, reqbody interface{}, params *url.Values, out interface{}) error + func (c *Client) DoRequestDebug(method, api string, reqbody interface{}, params *url.Values, out interface{}) error + type Config struct + AuthMethod Authenticator + ExtraHeader map[string]string + HTTPClient *http.Client + HttpRetryTimeout time.Duration + RefreshBuffer time.Duration + URL string + type Error interface + Body func() string + Error func() string + StatusCode func() int + URI func() string + type OAuthConfig struct + ClientID string + ClientSecret string + func (o OAuthConfig) Authenticate(c *Client) error + type StatusCodeCategory int + const ClassicAPI + const ClientError + const JamfProAPI + const ServerError + const Success + const Unknown