Documentation ¶
Index ¶
- Variables
- func AddQueryParamsToRequest(requestParams interface{}, req *http.Request, skipEmpty bool) error
- func CheckResponse(r *http.Response) error
- type Client
- func (c *Client) BaseURL() url.URL
- func (c *Client) Charset() string
- func (c *Client) Debug() bool
- func (c *Client) DivisionID() int
- func (c *Client) Do(req *http.Request, responseBody interface{}) (*http.Response, error)
- func (c *Client) GetEndpointURL(relative string, pathParams PathParams) url.URL
- func (c *Client) MediaType() string
- func (c *Client) NewMatchSetsDownloadPathParams() *MatchSetsDownloadPathParams
- func (c *Client) NewMatchSetsDownloadQueryParams() *MatchSetsDownloadQueryParams
- func (c *Client) NewMatchSetsDownloadRequest() MatchSetsDownloadRequest
- func (s *Client) NewMatchSetsDownloadRequestBody() MatchSetsDownloadRequestBody
- func (c *Client) NewRequest(ctx context.Context, method string, URL url.URL, body interface{}) (*http.Request, error)
- func (c *Client) SetBaseURL(baseURL url.URL)
- func (c *Client) SetCharset(charset string)
- func (c *Client) SetDebug(debug bool)
- func (c *Client) SetDivisionID(divisionID int)
- func (c *Client) SetHTTPClient(client *http.Client)
- func (c *Client) SetMediaType(mediaType string)
- func (c *Client) SetUserAgent(userAgent string)
- func (c *Client) Unmarshal(r io.Reader, vv ...interface{}) error
- func (c *Client) UserAgent() string
- type DefaultQueryParams
- type ErrorResponse
- type MatchLine
- type MatchLines
- type MatchSet
- type MatchSets
- type MatchSetsDownloadPathParams
- type MatchSetsDownloadQueryParams
- type MatchSetsDownloadRequest
- func (r *MatchSetsDownloadRequest) All() ([]MatchSetsDownloadResponseBody, error)
- func (r *MatchSetsDownloadRequest) Do() (MatchSetsDownloadResponseBody, error)
- func (r *MatchSetsDownloadRequest) Method() string
- func (r *MatchSetsDownloadRequest) NewResponseBody() *MatchSetsDownloadResponseBody
- func (r *MatchSetsDownloadRequest) PathParams() *MatchSetsDownloadPathParams
- func (r *MatchSetsDownloadRequest) QueryParams() *MatchSetsDownloadQueryParams
- func (r *MatchSetsDownloadRequest) RequestBody() *MatchSetsDownloadRequestBody
- func (r *MatchSetsDownloadRequest) SetMethod(method string)
- func (r *MatchSetsDownloadRequest) SetRequestBody(body MatchSetsDownloadRequestBody)
- func (r *MatchSetsDownloadRequest) URL() url.URL
- type MatchSetsDownloadRequestBody
- type MatchSetsDownloadResponseBody
- type Message
- type Messages
- type Oauth2Config
- type PathParams
- type RequestCompletionCallback
- type SchemaMarshaler
- type ToURLValues
- type Topic
- type Topics
Constants ¶
This section is empty.
Variables ¶
var (
DefaultBaseURL = url.URL{
Scheme: "https",
Host: "start.exactonline.nl",
Path: "docs/",
RawQuery: "_Division_={{.divisionID}}",
}
)
Functions ¶
func AddQueryParamsToRequest ¶
func CheckResponse ¶
CheckResponse checks the Client response for errors, and returns them if present. A response is considered an error if it has a status code outside the 200 range. Client error responses are expected to have either no response body, or a json response body that maps to ErrorResponse. Any other response body will be silently ignored.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client manages communication with Exact Globe Client
func (*Client) DivisionID ¶
func (*Client) Do ¶
Do sends an Client request and returns the Client response. The Client response is json decoded and stored in the value pointed to by v, or returned as an error if an Client error has occurred. If v implements the io.Writer interface, the raw response will be written to v, without attempting to decode it.
func (*Client) GetEndpointURL ¶
func (c *Client) GetEndpointURL(relative string, pathParams PathParams) url.URL
func (*Client) NewMatchSetsDownloadPathParams ¶
func (c *Client) NewMatchSetsDownloadPathParams() *MatchSetsDownloadPathParams
func (*Client) NewMatchSetsDownloadQueryParams ¶
func (c *Client) NewMatchSetsDownloadQueryParams() *MatchSetsDownloadQueryParams
func (*Client) NewMatchSetsDownloadRequest ¶
func (c *Client) NewMatchSetsDownloadRequest() MatchSetsDownloadRequest
func (*Client) NewMatchSetsDownloadRequestBody ¶
func (s *Client) NewMatchSetsDownloadRequestBody() MatchSetsDownloadRequestBody
func (*Client) NewRequest ¶
func (*Client) SetBaseURL ¶
func (*Client) SetCharset ¶
func (*Client) SetDivisionID ¶
func (*Client) SetHTTPClient ¶
func (*Client) SetMediaType ¶
func (*Client) SetUserAgent ¶
type DefaultQueryParams ¶
type ErrorResponse ¶
type ErrorResponse struct { // HTTP response that caused this error Response *http.Response `json:"-"` Errors []error }
func (ErrorResponse) Error ¶
func (r ErrorResponse) Error() string
func (*ErrorResponse) UnmarshalJSON ¶
func (r *ErrorResponse) UnmarshalJSON(data []byte) error
type MatchLines ¶
type MatchLines []MatchLine
func (*MatchLines) UnmarshalXML ¶
func (ll *MatchLines) UnmarshalXML(e *xml.Decoder, start xml.StartElement) error
type MatchSet ¶
type MatchSet struct { GLAccountCode string AccountCode string MatchLines MatchLines }
func (*MatchSet) UnmarshalXML ¶
type MatchSetsDownloadPathParams ¶
type MatchSetsDownloadPathParams struct { }
func (*MatchSetsDownloadPathParams) Params ¶
func (p *MatchSetsDownloadPathParams) Params() map[string]string
type MatchSetsDownloadQueryParams ¶
type MatchSetsDownloadQueryParams struct { DefaultQueryParams // Grootboekrekening GLAccount string `schema:"Params_GLAccount,omitempty"` // Relatiecode AccountCode string `schema:"Params_AccountCode,omitempty"` // Data subscription token DownloadID string `schema:"Params_DownloadID,omitempty"` }
func (MatchSetsDownloadQueryParams) ToURLValues ¶
func (p MatchSetsDownloadQueryParams) ToURLValues() (url.Values, error)
type MatchSetsDownloadRequest ¶
type MatchSetsDownloadRequest struct {
// contains filtered or unexported fields
}
func (*MatchSetsDownloadRequest) All ¶
func (r *MatchSetsDownloadRequest) All() ([]MatchSetsDownloadResponseBody, error)
func (*MatchSetsDownloadRequest) Do ¶
func (r *MatchSetsDownloadRequest) Do() (MatchSetsDownloadResponseBody, error)
func (*MatchSetsDownloadRequest) Method ¶
func (r *MatchSetsDownloadRequest) Method() string
func (*MatchSetsDownloadRequest) NewResponseBody ¶
func (r *MatchSetsDownloadRequest) NewResponseBody() *MatchSetsDownloadResponseBody
func (*MatchSetsDownloadRequest) PathParams ¶
func (r *MatchSetsDownloadRequest) PathParams() *MatchSetsDownloadPathParams
func (*MatchSetsDownloadRequest) QueryParams ¶
func (r *MatchSetsDownloadRequest) QueryParams() *MatchSetsDownloadQueryParams
func (*MatchSetsDownloadRequest) RequestBody ¶
func (r *MatchSetsDownloadRequest) RequestBody() *MatchSetsDownloadRequestBody
func (*MatchSetsDownloadRequest) SetMethod ¶
func (r *MatchSetsDownloadRequest) SetMethod(method string)
func (*MatchSetsDownloadRequest) SetRequestBody ¶
func (r *MatchSetsDownloadRequest) SetRequestBody(body MatchSetsDownloadRequestBody)
func (*MatchSetsDownloadRequest) URL ¶
func (r *MatchSetsDownloadRequest) URL() url.URL
type MatchSetsDownloadRequestBody ¶
type MatchSetsDownloadRequestBody struct { }
type Oauth2Config ¶
func NewOauth2Config ¶
func NewOauth2Config() *Oauth2Config
func (*Oauth2Config) SetBaseURL ¶
func (c *Oauth2Config) SetBaseURL(baseURL *url.URL)
type PathParams ¶
type RequestCompletionCallback ¶
RequestCompletionCallback defines the type of the request callback function
type SchemaMarshaler ¶
type SchemaMarshaler interface {
MarshalSchema() string
}