Documentation ¶
Index ¶
- Variables
- func CheckResponse(r *http.Response) error
- type Account
- type Accounts
- type ApprovalState
- type Client
- func (c Client) AccessToken() string
- func (c Client) BaseURL() url.URL
- func (c Client) Charset() string
- func (c Client) ClientSecret() string
- func (c Client) Debug() bool
- func (c *Client) Do(req *http.Request, responseBody interface{}) (*http.Response, error)
- func (c *Client) GetEndpointURL(path string, pathParams PathParams) url.URL
- func (c Client) MediaType() string
- func (c *Client) NewGetAccountsRequest() GetAccountsRequest
- func (c *Client) NewGetCompanySettingsRequest() GetCompanySettingsRequest
- func (c *Client) NewGetCustomerRequest() GetCustomerRequest
- func (c *Client) NewGetCustomersRequest() GetCustomersRequest
- func (c *Client) NewGetInvoicesRequest() GetInvoicesRequest
- func (c *Client) NewGetPredefinedVoucherSeriesRequest() GetPredefinedVoucherSeriesRequest
- func (c *Client) NewGetVouchersRequest() GetVouchersRequest
- func (c *Client) NewPostCustomerRequest() PostCustomerRequest
- func (c *Client) NewPostInvoiceRequest() PostInvoiceRequest
- func (c *Client) NewPostVoucherRequest() PostVoucherRequest
- func (c *Client) NewRequest(ctx context.Context, method string, URL url.URL, body interface{}) (*http.Request, error)
- func (c *Client) RegisterRequestTimestamp(t time.Time)
- func (c *Client) SetAccessToken(accessToken string)
- func (c *Client) SetBaseURL(baseURL url.URL)
- func (c *Client) SetCharset(charset string)
- func (c *Client) SetClientSecret(clientSecret string)
- func (c *Client) SetDebug(debug bool)
- func (c *Client) SetDisallowUnknownFields(disallowUnknownFields bool)
- func (c *Client) SetHTTPClient(client *http.Client)
- func (c *Client) SetMediaType(mediaType string)
- func (c *Client) SetUserAgent(userAgent string)
- func (c *Client) SleepUntilRequestRate()
- func (c *Client) Unmarshal(r io.Reader, vv ...interface{}) error
- func (c Client) UserAgent() string
- type CompanySettings
- type Customer
- type CustomerType
- type Customers
- type Date
- type DateTime
- type DefaultDeliveryTypes
- type DefaultTemplates
- type DeliveryType
- type EDIInformation
- type EDIStatus
- type EmailInformation
- type ErrorInformation
- type ErrorResponse
- type GetAccountsPathParams
- type GetAccountsQueryParams
- type GetAccountsRequest
- func (r *GetAccountsRequest) Do() (GetAccountsResponseBody, error)
- func (r *GetAccountsRequest) Method() string
- func (r GetAccountsRequest) NewGetAccountsPathParams() *GetAccountsPathParams
- func (r GetAccountsRequest) NewGetAccountsQueryParams() *GetAccountsQueryParams
- func (r GetAccountsRequest) NewGetAccountsRequestBody() GetAccountsRequestBody
- func (r *GetAccountsRequest) NewResponseBody() *GetAccountsResponseBody
- func (r *GetAccountsRequest) PathParams() *GetAccountsPathParams
- func (r *GetAccountsRequest) QueryParams() *GetAccountsQueryParams
- func (r *GetAccountsRequest) RequestBody() *GetAccountsRequestBody
- func (r *GetAccountsRequest) SetMethod(method string)
- func (r *GetAccountsRequest) SetRequestBody(body GetAccountsRequestBody)
- func (r *GetAccountsRequest) URL() url.URL
- type GetAccountsRequestBody
- type GetAccountsResponseBody
- type GetCompanySettingsPathParams
- type GetCompanySettingsQueryParams
- type GetCompanySettingsRequest
- func (r *GetCompanySettingsRequest) Do() (GetCompanySettingsResponseBody, error)
- func (r *GetCompanySettingsRequest) Method() string
- func (r GetCompanySettingsRequest) NewGetCompanySettingsPathParams() *GetCompanySettingsPathParams
- func (r GetCompanySettingsRequest) NewGetCompanySettingsQueryParams() *GetCompanySettingsQueryParams
- func (r GetCompanySettingsRequest) NewGetCompanySettingsRequestBody() GetCompanySettingsRequestBody
- func (r *GetCompanySettingsRequest) NewResponseBody() *GetCompanySettingsResponseBody
- func (r *GetCompanySettingsRequest) PathParams() *GetCompanySettingsPathParams
- func (r *GetCompanySettingsRequest) QueryParams() *GetCompanySettingsQueryParams
- func (r *GetCompanySettingsRequest) RequestBody() *GetCompanySettingsRequestBody
- func (r *GetCompanySettingsRequest) SetMethod(method string)
- func (r *GetCompanySettingsRequest) SetRequestBody(body GetCompanySettingsRequestBody)
- func (r *GetCompanySettingsRequest) URL() url.URL
- type GetCompanySettingsRequestBody
- type GetCompanySettingsResponseBody
- type GetCustomerPathParams
- type GetCustomerQueryParams
- type GetCustomerRequest
- func (r *GetCustomerRequest) Do() (GetCustomerResponseBody, error)
- func (r *GetCustomerRequest) Method() string
- func (r GetCustomerRequest) NewGetCustomerPathParams() *GetCustomerPathParams
- func (r GetCustomerRequest) NewGetCustomerQueryParams() *GetCustomerQueryParams
- func (r GetCustomerRequest) NewGetCustomerRequestBody() GetCustomerRequestBody
- func (r *GetCustomerRequest) NewResponseBody() *GetCustomerResponseBody
- func (r *GetCustomerRequest) PathParams() *GetCustomerPathParams
- func (r *GetCustomerRequest) QueryParams() *GetCustomerQueryParams
- func (r *GetCustomerRequest) RequestBody() *GetCustomerRequestBody
- func (r *GetCustomerRequest) SetMethod(method string)
- func (r *GetCustomerRequest) SetRequestBody(body GetCustomerRequestBody)
- func (r *GetCustomerRequest) URL() url.URL
- type GetCustomerRequestBody
- type GetCustomerResponseBody
- type GetCustomersPathParams
- type GetCustomersQueryParams
- type GetCustomersRequest
- func (r *GetCustomersRequest) Do() (GetCustomersResponseBody, error)
- func (r *GetCustomersRequest) Method() string
- func (r GetCustomersRequest) NewGetCustomersPathParams() *GetCustomersPathParams
- func (r GetCustomersRequest) NewGetCustomersQueryParams() *GetCustomersQueryParams
- func (r GetCustomersRequest) NewGetCustomersRequestBody() GetCustomersRequestBody
- func (r *GetCustomersRequest) NewResponseBody() *GetCustomersResponseBody
- func (r *GetCustomersRequest) PathParams() *GetCustomersPathParams
- func (r *GetCustomersRequest) QueryParams() *GetCustomersQueryParams
- func (r *GetCustomersRequest) RequestBody() *GetCustomersRequestBody
- func (r *GetCustomersRequest) SetMethod(method string)
- func (r *GetCustomersRequest) SetRequestBody(body GetCustomersRequestBody)
- func (r *GetCustomersRequest) URL() url.URL
- type GetCustomersRequestBody
- type GetCustomersResponseBody
- type GetInvoicesPathParams
- type GetInvoicesQueryParams
- type GetInvoicesRequest
- func (r *GetInvoicesRequest) Do() (GetInvoicesResponseBody, error)
- func (r *GetInvoicesRequest) Method() string
- func (r GetInvoicesRequest) NewGetInvoicesPathParams() *GetInvoicesPathParams
- func (r GetInvoicesRequest) NewGetInvoicesQueryParams() *GetInvoicesQueryParams
- func (r GetInvoicesRequest) NewGetInvoicesRequestBody() GetInvoicesRequestBody
- func (r *GetInvoicesRequest) NewResponseBody() *GetInvoicesResponseBody
- func (r *GetInvoicesRequest) PathParams() *GetInvoicesPathParams
- func (r *GetInvoicesRequest) QueryParams() *GetInvoicesQueryParams
- func (r *GetInvoicesRequest) RequestBody() *GetInvoicesRequestBody
- func (r *GetInvoicesRequest) SetMethod(method string)
- func (r *GetInvoicesRequest) SetRequestBody(body GetInvoicesRequestBody)
- func (r *GetInvoicesRequest) URL() url.URL
- type GetInvoicesRequestBody
- type GetInvoicesResponseBody
- type GetPredefinedVoucherSeriesPathParams
- type GetPredefinedVoucherSeriesQueryParams
- type GetPredefinedVoucherSeriesRequest
- func (r *GetPredefinedVoucherSeriesRequest) Do() (GetPredefinedVoucherSeriesResponseBody, error)
- func (r *GetPredefinedVoucherSeriesRequest) Method() string
- func (r GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesPathParams() *GetPredefinedVoucherSeriesPathParams
- func (r GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesQueryParams() *GetPredefinedVoucherSeriesQueryParams
- func (r GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesRequestBody() GetPredefinedVoucherSeriesRequestBody
- func (r *GetPredefinedVoucherSeriesRequest) NewResponseBody() *GetPredefinedVoucherSeriesResponseBody
- func (r *GetPredefinedVoucherSeriesRequest) PathParams() *GetPredefinedVoucherSeriesPathParams
- func (r *GetPredefinedVoucherSeriesRequest) QueryParams() *GetPredefinedVoucherSeriesQueryParams
- func (r *GetPredefinedVoucherSeriesRequest) RequestBody() *GetPredefinedVoucherSeriesRequestBody
- func (r *GetPredefinedVoucherSeriesRequest) SetMethod(method string)
- func (r *GetPredefinedVoucherSeriesRequest) SetRequestBody(body GetPredefinedVoucherSeriesRequestBody)
- func (r *GetPredefinedVoucherSeriesRequest) URL() url.URL
- type GetPredefinedVoucherSeriesRequestBody
- type GetPredefinedVoucherSeriesResponseBody
- type GetVouchersPathParams
- type GetVouchersQueryParams
- type GetVouchersRequest
- func (r *GetVouchersRequest) Do() (GetVouchersResponseBody, error)
- func (r *GetVouchersRequest) Method() string
- func (r GetVouchersRequest) NewGetVouchersPathParams() *GetVouchersPathParams
- func (r GetVouchersRequest) NewGetVouchersQueryParams() *GetVouchersQueryParams
- func (r GetVouchersRequest) NewGetVouchersRequestBody() GetVouchersRequestBody
- func (r *GetVouchersRequest) NewResponseBody() *GetVouchersResponseBody
- func (r *GetVouchersRequest) PathParams() *GetVouchersPathParams
- func (r *GetVouchersRequest) QueryParams() *GetVouchersQueryParams
- func (r *GetVouchersRequest) RequestBody() *GetVouchersRequestBody
- func (r *GetVouchersRequest) SetMethod(method string)
- func (r *GetVouchersRequest) SetRequestBody(body GetVouchersRequestBody)
- func (r *GetVouchersRequest) URL() url.URL
- type GetVouchersRequestBody
- type GetVouchersResponseBody
- type Invoice
- type InvoiceRow
- type InvoiceRows
- type InvoiceType
- type Invoices
- type Label
- type Labels
- type MetaInformation
- type Number
- type Oauth2Config
- type PathParams
- type PaymentWay
- type PostCustomerPathParams
- type PostCustomerQueryParams
- type PostCustomerRequest
- func (r *PostCustomerRequest) Do() (PostCustomerResponseBody, error)
- func (r *PostCustomerRequest) Method() string
- func (r PostCustomerRequest) NewPostCustomerPathParams() *PostCustomerPathParams
- func (r PostCustomerRequest) NewPostCustomerQueryParams() *PostCustomerQueryParams
- func (r PostCustomerRequest) NewPostCustomerRequestBody() PostCustomerRequestBody
- func (r *PostCustomerRequest) NewResponseBody() *PostCustomerResponseBody
- func (r *PostCustomerRequest) PathParams() *PostCustomerPathParams
- func (r *PostCustomerRequest) QueryParams() *PostCustomerQueryParams
- func (r *PostCustomerRequest) RequestBody() *PostCustomerRequestBody
- func (r *PostCustomerRequest) SetMethod(method string)
- func (r *PostCustomerRequest) SetRequestBody(body PostCustomerRequestBody)
- func (r *PostCustomerRequest) URL() url.URL
- type PostCustomerRequestBody
- type PostCustomerResponseBody
- type PostInvoicePathParams
- type PostInvoiceQueryParams
- type PostInvoiceRequest
- func (r *PostInvoiceRequest) Do() (PostInvoiceResponseBody, error)
- func (r *PostInvoiceRequest) Method() string
- func (r PostInvoiceRequest) NewPostInvoicePathParams() *PostInvoicePathParams
- func (r PostInvoiceRequest) NewPostInvoiceQueryParams() *PostInvoiceQueryParams
- func (r PostInvoiceRequest) NewPostInvoiceRequestBody() PostInvoiceRequestBody
- func (r *PostInvoiceRequest) NewResponseBody() *PostInvoiceResponseBody
- func (r *PostInvoiceRequest) PathParams() *PostInvoicePathParams
- func (r *PostInvoiceRequest) QueryParams() *PostInvoiceQueryParams
- func (r *PostInvoiceRequest) RequestBody() *PostInvoiceRequestBody
- func (r *PostInvoiceRequest) SetMethod(method string)
- func (r *PostInvoiceRequest) SetRequestBody(body PostInvoiceRequestBody)
- func (r *PostInvoiceRequest) URL() url.URL
- type PostInvoiceRequestBody
- type PostInvoiceResponseBody
- type PostVoucherPathParams
- type PostVoucherQueryParams
- type PostVoucherRequest
- func (r *PostVoucherRequest) Do() (PostVoucherResponseBody, error)
- func (r *PostVoucherRequest) Method() string
- func (r PostVoucherRequest) NewPostVoucherPathParams() *PostVoucherPathParams
- func (r PostVoucherRequest) NewPostVoucherQueryParams() *PostVoucherQueryParams
- func (r PostVoucherRequest) NewPostVoucherRequestBody() PostVoucherRequestBody
- func (r *PostVoucherRequest) NewResponseBody() *PostVoucherResponseBody
- func (r *PostVoucherRequest) PathParams() *PostVoucherPathParams
- func (r *PostVoucherRequest) QueryParams() *PostVoucherQueryParams
- func (r *PostVoucherRequest) RequestBody() *PostVoucherRequestBody
- func (r *PostVoucherRequest) SetMethod(method string)
- func (r *PostVoucherRequest) SetRequestBody(body PostVoucherRequestBody)
- func (r *PostVoucherRequest) URL() url.URL
- type PostVoucherRequestBody
- type PostVoucherResponseBody
- type RequestCompletionCallback
- type VATType
- type Voucher
- type VoucherRow
- type VoucherRows
- type Vouchers
Constants ¶
This section is empty.
Variables ¶
var (
BaseURL = url.URL{
Scheme: "https",
Host: "api.fortnox.se",
Path: "/3",
}
)
Functions ¶
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 Account ¶
type Account struct { URL utils.URL `json:"@url"` // Direct url to the record. Active bool `json:"active"` BalanceBroughtForward float64 `json:"BalanceBroughtForward"` CostCenter string `json:"CostCenter"` CostCentersettings string `json:"CostCentersettings"` Description string `json:"Description"` Number int `json:"Number"` Project string `json:"Project"` ProjectSettings string `json:"ProjectSettings"` SRU int `json:"SRU"` Year int `json:"Year"` VATCode string `json:"VATCode"` }
type ApprovalState ¶
type ApprovalState int
var ( ApprovalStateNotForApproval ApprovalState = 0 ApprovalStateNotReadForApproval ApprovalState = 1 ApprovalStateNotApproved ApprovalState = 2 ApprovalStateApproved ApprovalState = 3 )
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client manages communication with Exact Globe Client
func (Client) AccessToken ¶
func (Client) ClientSecret ¶
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(path string, pathParams PathParams) url.URL
func (*Client) NewGetAccountsRequest ¶
func (c *Client) NewGetAccountsRequest() GetAccountsRequest
func (*Client) NewGetCompanySettingsRequest ¶
func (c *Client) NewGetCompanySettingsRequest() GetCompanySettingsRequest
func (*Client) NewGetCustomerRequest ¶
func (c *Client) NewGetCustomerRequest() GetCustomerRequest
func (*Client) NewGetCustomersRequest ¶
func (c *Client) NewGetCustomersRequest() GetCustomersRequest
func (*Client) NewGetInvoicesRequest ¶
func (c *Client) NewGetInvoicesRequest() GetInvoicesRequest
func (*Client) NewGetPredefinedVoucherSeriesRequest ¶
func (c *Client) NewGetPredefinedVoucherSeriesRequest() GetPredefinedVoucherSeriesRequest
func (*Client) NewGetVouchersRequest ¶
func (c *Client) NewGetVouchersRequest() GetVouchersRequest
func (*Client) NewPostCustomerRequest ¶
func (c *Client) NewPostCustomerRequest() PostCustomerRequest
func (*Client) NewPostInvoiceRequest ¶
func (c *Client) NewPostInvoiceRequest() PostInvoiceRequest
func (*Client) NewPostVoucherRequest ¶
func (c *Client) NewPostVoucherRequest() PostVoucherRequest
func (*Client) NewRequest ¶
func (*Client) RegisterRequestTimestamp ¶
func (*Client) SetAccessToken ¶
func (*Client) SetBaseURL ¶
func (*Client) SetCharset ¶
func (*Client) SetClientSecret ¶
func (*Client) SetDisallowUnknownFields ¶
func (*Client) SetHTTPClient ¶
func (*Client) SetMediaType ¶
func (*Client) SetUserAgent ¶
func (*Client) SleepUntilRequestRate ¶
func (c *Client) SleepUntilRequestRate()
type CompanySettings ¶
type CompanySettings struct { Address string `json:"Address"` BG string `json:"BG"` BIC string `json:"BIC"` BranchCode string `json:"BranchCode"` City string `json:"City"` ContactFirstName string `json:"ContactFirstName"` ContactLastName string `json:"ContactLastName"` Country string `json:"Country"` CountryCode string `json:"CountryCode"` DatabaseNumber int `json:"DatabaseNumber"` Domicile string `json:"Domicile"` Email string `json:"Email"` Fax string `json:"Fax"` IBAN string `json:"IBAN"` Name string `json:"Name"` OrganizationNumber string `json:"OrganizationNumber"` PG string `json:"PG"` Phone1 string `json:"Phone1"` Phone2 string `json:"Phone2"` TaxEnabled bool `json:"TaxEnabled"` VATNumber string `json:"VATNumber"` VisitAddress string `json:"VisitAddress"` VisitCity string `json:"VisitCity"` VisitCountry string `json:"VisitCountry"` VisitCountryCode string `json:"VisitCountryCode"` VisitName string `json:"VisitName"` VisitZipCode string `json:"VisitZipCode"` WWW string `json:"WWW"` ZipCode string `json:"ZipCode"` }
type Customer ¶
type Customer struct { URL utils.URL `json:"@url,omitempty"` // Direct URL to the record. Active bool `json:"Active"` // If the customer is active or not Address1 string `json:"Address1"` // Address 1 of the customer. Address2 string `json:"Address2"` // Address 2 of the customer. City string `json:"City"` // City of the customer. Country string `json:"Country,omitempty"` // Country name for the customer. Comments string `json:"Comments"` // Comments of the customer. Currency string `json:"Currency"` // Code of the currency for the customer. This will be used as the predefined currency for documents for the customer. The code must be of an existing currency. CostCenter string `json:"CostCenter"` // Code of the cost center for the customer. The code must be of a an existing currency. CountryCode string `json:"CountryCode"` // Code of the country for the customer. The code must be of an existing country according to ISO 3166-1 Alpha-2. CustomerNumber string `json:"CustomerNumber"` // Customer number of the customer. If no customer number is provided, the next number in the series will be used. Only alpha numeric characters, with the addition of – + / and _, are allowed. DefaultDeliveryTypes DefaultDeliveryTypes `json:"DefaultDeliveryTypes"` // The properties for this object is listed in the table for “Default Delivery Types”. DefaultTemplates DefaultTemplates `json:"DefaultTemplates"` // The properties for this object is listed in the table for “Default Templates”. DeliveryAddress1 string `json:"DeliveryAddress1"` // Delivery address 1 for the customer. DeliveryAddress2 string `json:"DeliveryAddress2"` // Delivery address 2 for the customer. DeliveryCity string `json:"DeliveryCity"` // Delivery city for the customer. DeliveryCountry string `json:"DeliveryCountry,omitempty"` // Delivery country for the customer. DeliveryCountryCode string `json:"DeliveryCountryCode"` // Code of the delivery country for the customer. The code must be of an existing country according to ISO 3166-1 Alpha-2. DeliveryFax string `json:"DeliveryFax"` // Delivery fax number of the customer. DeliveryName string `json:"DeliveryName"` // Delivery name for the customer. DeliveryPhone1 string `json:"DeliveryPhone1"` // Delivery phone number 1 for the customer. DeliveryPhone2 string `json:"DeliveryPhone2"` // Delivery phone number 2 for the customer. DeliveryZipCode string `json:"DeliveryZipCode"` // Delivery zip code for the customer. Email string `json:"Email"` // Email address for the customer. This must be a valid email address. EmailInvoice string `json:"EmailInvoice"` // Specific email address used for invoices sent to the customer. This must be a valid email address. EmailInvoiceBCC string `json:"EmailInvoiceBCC"` // Specific blind carbon copy email address used for invoices sent to the customer. This must be a valid email address. EmailInvoiceCC string `json:"EmailInvoiceCC"` // Specific carbon copy email address used for invoices sent to the customer. This must be a valid email address. EmailOffer string `json:"EmailOffer"` // Specific email address used for offers sent to the customer. This must be a valid email address. EmailOfferBCC string `json:"EmailOfferBCC"` // Specific blind carbon copy email address used for offers sent to the customer. This must be a valid email address. EmailOfferCC string `json:"EmailOfferCC"` // Specific carbon copy email address used for offers sent to the customer. This must be a valid email address. EmailOrder string `json:"EmailOrder"` // Specific email address used for orders sent to the customer. This must be a valid email address. EmailOrderBCC string `json:"EmailOrderBCC"` // Specific blind carbon copy email address used for orders sent to the customer. This must be a valid email address. EmailOrderCC string `json:"EmailOrderCC"` // Specific carbon copy email address used for orders sent to the customer. This must be a valid email address. ExternalReference string `json:"ExternalReference"` Fax string `json:"Fax"` // Fax number for the customer. GLN string `json:"GLN"` // Global Location Number of the customer GLNDelivery string `json:"GLNDelivery"` // Global Location Delivery Number InvoiceAdministrationFee string `json:"InvoiceAdministrationFee"` // Predefined invoice administration fee for the customer. InvoiceDiscount float64 `json:"InvoiceDiscount"` // Predefined invoice discount for the customer. InvoiceFreight string `json:"InvoiceFreight"` // Predefined invoice freight fee for the customer. InvoiceRemark string `json:"InvoiceRemark"` // Predefined invoice remark for the customer. Name string `json:"Name"` // Name of the customer. OrganisationNumber string `json:"OrganisationNumber"` // Organisation number of the customer. It needs to be a valid organisation numer. OurReference string `json:"OurReference"` // Our reference of the customer. Phone string `json:"Phone,omitempty"` // Phone number of the customer. Phone1 string `json:"Phone1"` // Phone number 1 of the customer. Phone2 string `json:"Phone2"` // Phone number 2 of the customer. PriceList string `json:"PriceList"` // Code of the price list for the customer. The code must be of a an existing price list. Project string `json:"Project"` // Number of the project for the customer. The number must be of a an existing project. SalesAccount string `json:"SalesAccount"` // Predefined sales account of the customer. ShowPriceVATIncluded bool `json:"ShowPriceVATIncluded"` // If prices should be displayed with VAT included. TermsOfDelivery string `json:"TermsOfDelivery"` // Code of the terms of delivery for the customer. The code must be of a an existing terms of delivery. TermsOfPayment string `json:"TermsOfPayment"` // Code of the terms of payment for the customer. The code must be of a an existing terms of payment. Type CustomerType `json:"Type"` // Type of the customer. Can be PRIVATE or COMPANY. VATNumber string `json:"VATNumber"` // VAT number for the customer. VATType VATType `json:"VATType"` // VAT type of the customer. Can be SEVAT SEREVERSEDVAT EUREVERSEDVAT EUVAT or EXPORT. VisitingAddress string `json:"VisitingAddress"` // Visiting address of the customer. VisitingCity string `json:"VisitingCity"` // Visiting city of the customer. VisitingCountry string `json:"VisitingCountry,omitempty"` // Visiting country of the customer. VisitingCountryCode string `json:"VisitingCountryCode"` // Code of the visiting country for the customer. The code must be of an existing country according to ISO 3166-1 Alpha-2. VisitingZipCode string `json:"VisitingZipCode"` // Visiting zip code of the customer. WWW string `json:"WWW"` // Website of the customer. WayOfDelivery string `json:"WayOfDelivery"` // Code of the way of delivery for the customer. The code must be of a an existing way of delivery. YourReference string `json:"YourReference"` // Your reference of the customer. ZipCode string `json:"ZipCode"` // Zip code of the customers. }
type CustomerType ¶
type CustomerType string
var ( CustomerTypePrivate CustomerType = "PRIVATE" CustomerTypeCompany CustomerType = "COMPANY" )
type DefaultDeliveryTypes ¶
type DefaultDeliveryTypes struct { Invoice DeliveryType Order DeliveryType Offer DeliveryType }
type DefaultTemplates ¶
type DeliveryType ¶
type DeliveryType string
var ( DeliveryTypePrint DeliveryType = "PRINT" DeliveryTypeEmail DeliveryType = "EMAIL" DeliveryTypePrintService DeliveryType = "PRINTSERVICE" )
type EDIInformation ¶
type EDIInformation struct { EDIGlobalLocationNumber string `json:"EDIGlobalLocationNumber"` // Invoice address GLN for EDI EDIGlobalLocationNumberDelivery string `json:"EDIGlobalLocationNumberDelivery"` // Delivery address GLN for EDI EDIInvoiceExtra1 string `json:"EDIInvoiceExtra1"` // Extra EDI Information EDIInvoiceExtra2 string `json:"EDIInvoiceExtra2"` // Extra EDI Information EDIOurElectronicReference string `json:"EDIOurElectronicReference"` // Our electronic reference for EDI EDIYourElectronicReference string `json:"EDIYourElectronicReference"` // Your electronic reference for EDI EDIStatus EDIStatus `json:"EDIStatus,omitempty"` // Status of the send process of the invoice. Can have the following codes: }
type EDIStatus ¶
type EDIStatus string
var ( EDIStatusSentToCrediflow EDIStatus = "1" EDIStatusCheckedByCrediflow EDIStatus = "2" EDIStatusDeliveredElectronically EDIStatus = "3" EDIStatusDeliveredToPrintingService EDIStatus = "4" EDIStatusDeliveredToPostenByPrintCompany EDIStatus = "5" EDIStatusDeclinedByCrediflow EDIStatus = "6" EDIStatusDeclinedByReceiver EDIStatus = "7" )
type EmailInformation ¶
type EmailInformation struct { EmailAddressFrom string `json:"EmailAddressFrom"` // Reply to adress. Must be a valid e-mail address EmailAddressTo string `json:"EmailAddressTo"` // Customer e-mail address. Must be a valid e-mail address. EmailAddressCC string `json:"EmailAddressCC"` // Customer e-mail address – Copy. Must be a valid e-mail address. EmailAddressBCC string `json:"EmailAddressBCC"` // Customer e-mail address – Blind carbon copy. Must be a valid e-mail address. EmailSubject string `json:"EmailSubject"` // Subject of the e-mail // The variable {no} = document number. The variable {name} = customer name EmailBody string `json:"EmailBody"` // Body of the e-mail. }
type ErrorInformation ¶
type ErrorInformation struct { Err int `json:"error"` Message string `json:"message"` Code int `json:"code"` }
func (ErrorInformation) Error ¶
func (e ErrorInformation) Error() string
type ErrorResponse ¶
type ErrorResponse struct { // HTTP response that caused this error Response *http.Response `json:"-"` ErrorInformation error `json:"ErrorInformation"` }
func (ErrorResponse) Error ¶
func (r ErrorResponse) Error() string
type GetAccountsPathParams ¶
type GetAccountsPathParams struct { }
func (*GetAccountsPathParams) Params ¶
func (p *GetAccountsPathParams) Params() map[string]string
type GetAccountsQueryParams ¶
type GetAccountsQueryParams struct { }
func (GetAccountsQueryParams) ToURLValues ¶
func (p GetAccountsQueryParams) ToURLValues() (url.Values, error)
type GetAccountsRequest ¶
type GetAccountsRequest struct {
// contains filtered or unexported fields
}
func (*GetAccountsRequest) Do ¶
func (r *GetAccountsRequest) Do() (GetAccountsResponseBody, error)
func (*GetAccountsRequest) Method ¶
func (r *GetAccountsRequest) Method() string
func (GetAccountsRequest) NewGetAccountsPathParams ¶
func (r GetAccountsRequest) NewGetAccountsPathParams() *GetAccountsPathParams
func (GetAccountsRequest) NewGetAccountsQueryParams ¶
func (r GetAccountsRequest) NewGetAccountsQueryParams() *GetAccountsQueryParams
func (GetAccountsRequest) NewGetAccountsRequestBody ¶
func (r GetAccountsRequest) NewGetAccountsRequestBody() GetAccountsRequestBody
func (*GetAccountsRequest) NewResponseBody ¶
func (r *GetAccountsRequest) NewResponseBody() *GetAccountsResponseBody
func (*GetAccountsRequest) PathParams ¶
func (r *GetAccountsRequest) PathParams() *GetAccountsPathParams
func (*GetAccountsRequest) QueryParams ¶
func (r *GetAccountsRequest) QueryParams() *GetAccountsQueryParams
func (*GetAccountsRequest) RequestBody ¶
func (r *GetAccountsRequest) RequestBody() *GetAccountsRequestBody
func (*GetAccountsRequest) SetMethod ¶
func (r *GetAccountsRequest) SetMethod(method string)
func (*GetAccountsRequest) SetRequestBody ¶
func (r *GetAccountsRequest) SetRequestBody(body GetAccountsRequestBody)
func (*GetAccountsRequest) URL ¶
func (r *GetAccountsRequest) URL() url.URL
type GetAccountsRequestBody ¶
type GetAccountsRequestBody struct{}
type GetAccountsResponseBody ¶
type GetAccountsResponseBody struct { MetaInformation `json:"MetaInformation"` Accounts Accounts }
type GetCompanySettingsPathParams ¶
type GetCompanySettingsPathParams struct { }
func (*GetCompanySettingsPathParams) Params ¶
func (p *GetCompanySettingsPathParams) Params() map[string]string
type GetCompanySettingsQueryParams ¶
type GetCompanySettingsQueryParams struct { }
func (GetCompanySettingsQueryParams) ToURLValues ¶
func (p GetCompanySettingsQueryParams) ToURLValues() (url.Values, error)
type GetCompanySettingsRequest ¶
type GetCompanySettingsRequest struct {
// contains filtered or unexported fields
}
func (*GetCompanySettingsRequest) Do ¶
func (r *GetCompanySettingsRequest) Do() (GetCompanySettingsResponseBody, error)
func (*GetCompanySettingsRequest) Method ¶
func (r *GetCompanySettingsRequest) Method() string
func (GetCompanySettingsRequest) NewGetCompanySettingsPathParams ¶
func (r GetCompanySettingsRequest) NewGetCompanySettingsPathParams() *GetCompanySettingsPathParams
func (GetCompanySettingsRequest) NewGetCompanySettingsQueryParams ¶
func (r GetCompanySettingsRequest) NewGetCompanySettingsQueryParams() *GetCompanySettingsQueryParams
func (GetCompanySettingsRequest) NewGetCompanySettingsRequestBody ¶
func (r GetCompanySettingsRequest) NewGetCompanySettingsRequestBody() GetCompanySettingsRequestBody
func (*GetCompanySettingsRequest) NewResponseBody ¶
func (r *GetCompanySettingsRequest) NewResponseBody() *GetCompanySettingsResponseBody
func (*GetCompanySettingsRequest) PathParams ¶
func (r *GetCompanySettingsRequest) PathParams() *GetCompanySettingsPathParams
func (*GetCompanySettingsRequest) QueryParams ¶
func (r *GetCompanySettingsRequest) QueryParams() *GetCompanySettingsQueryParams
func (*GetCompanySettingsRequest) RequestBody ¶
func (r *GetCompanySettingsRequest) RequestBody() *GetCompanySettingsRequestBody
func (*GetCompanySettingsRequest) SetMethod ¶
func (r *GetCompanySettingsRequest) SetMethod(method string)
func (*GetCompanySettingsRequest) SetRequestBody ¶
func (r *GetCompanySettingsRequest) SetRequestBody(body GetCompanySettingsRequestBody)
func (*GetCompanySettingsRequest) URL ¶
func (r *GetCompanySettingsRequest) URL() url.URL
type GetCompanySettingsRequestBody ¶
type GetCompanySettingsRequestBody struct{}
type GetCompanySettingsResponseBody ¶
type GetCompanySettingsResponseBody struct {
CompanySettings CompanySettings
}
type GetCustomerPathParams ¶
type GetCustomerPathParams struct {
CustomerNumber string
}
func (*GetCustomerPathParams) Params ¶
func (p *GetCustomerPathParams) Params() map[string]string
type GetCustomerQueryParams ¶
type GetCustomerQueryParams struct{}
func (GetCustomerQueryParams) ToURLValues ¶
func (p GetCustomerQueryParams) ToURLValues() (url.Values, error)
type GetCustomerRequest ¶
type GetCustomerRequest struct {
// contains filtered or unexported fields
}
func (*GetCustomerRequest) Do ¶
func (r *GetCustomerRequest) Do() (GetCustomerResponseBody, error)
func (*GetCustomerRequest) Method ¶
func (r *GetCustomerRequest) Method() string
func (GetCustomerRequest) NewGetCustomerPathParams ¶
func (r GetCustomerRequest) NewGetCustomerPathParams() *GetCustomerPathParams
func (GetCustomerRequest) NewGetCustomerQueryParams ¶
func (r GetCustomerRequest) NewGetCustomerQueryParams() *GetCustomerQueryParams
func (GetCustomerRequest) NewGetCustomerRequestBody ¶
func (r GetCustomerRequest) NewGetCustomerRequestBody() GetCustomerRequestBody
func (*GetCustomerRequest) NewResponseBody ¶
func (r *GetCustomerRequest) NewResponseBody() *GetCustomerResponseBody
func (*GetCustomerRequest) PathParams ¶
func (r *GetCustomerRequest) PathParams() *GetCustomerPathParams
func (*GetCustomerRequest) QueryParams ¶
func (r *GetCustomerRequest) QueryParams() *GetCustomerQueryParams
func (*GetCustomerRequest) RequestBody ¶
func (r *GetCustomerRequest) RequestBody() *GetCustomerRequestBody
func (*GetCustomerRequest) SetMethod ¶
func (r *GetCustomerRequest) SetMethod(method string)
func (*GetCustomerRequest) SetRequestBody ¶
func (r *GetCustomerRequest) SetRequestBody(body GetCustomerRequestBody)
func (*GetCustomerRequest) URL ¶
func (r *GetCustomerRequest) URL() url.URL
type GetCustomerRequestBody ¶
type GetCustomerRequestBody struct{}
type GetCustomerResponseBody ¶
type GetCustomerResponseBody struct { MetaInformation `json:"MetaInformation"` Customer Customer }
type GetCustomersPathParams ¶
type GetCustomersPathParams struct { }
func (*GetCustomersPathParams) Params ¶
func (p *GetCustomersPathParams) Params() map[string]string
type GetCustomersQueryParams ¶
type GetCustomersQueryParams struct { CustomerNumber string `schema:"customernumber"` Name string `schema:"name"` Email string `schema:"email"` }
func (GetCustomersQueryParams) ToURLValues ¶
func (p GetCustomersQueryParams) ToURLValues() (url.Values, error)
type GetCustomersRequest ¶
type GetCustomersRequest struct {
// contains filtered or unexported fields
}
func (*GetCustomersRequest) Do ¶
func (r *GetCustomersRequest) Do() (GetCustomersResponseBody, error)
func (*GetCustomersRequest) Method ¶
func (r *GetCustomersRequest) Method() string
func (GetCustomersRequest) NewGetCustomersPathParams ¶
func (r GetCustomersRequest) NewGetCustomersPathParams() *GetCustomersPathParams
func (GetCustomersRequest) NewGetCustomersQueryParams ¶
func (r GetCustomersRequest) NewGetCustomersQueryParams() *GetCustomersQueryParams
func (GetCustomersRequest) NewGetCustomersRequestBody ¶
func (r GetCustomersRequest) NewGetCustomersRequestBody() GetCustomersRequestBody
func (*GetCustomersRequest) NewResponseBody ¶
func (r *GetCustomersRequest) NewResponseBody() *GetCustomersResponseBody
func (*GetCustomersRequest) PathParams ¶
func (r *GetCustomersRequest) PathParams() *GetCustomersPathParams
func (*GetCustomersRequest) QueryParams ¶
func (r *GetCustomersRequest) QueryParams() *GetCustomersQueryParams
func (*GetCustomersRequest) RequestBody ¶
func (r *GetCustomersRequest) RequestBody() *GetCustomersRequestBody
func (*GetCustomersRequest) SetMethod ¶
func (r *GetCustomersRequest) SetMethod(method string)
func (*GetCustomersRequest) SetRequestBody ¶
func (r *GetCustomersRequest) SetRequestBody(body GetCustomersRequestBody)
func (*GetCustomersRequest) URL ¶
func (r *GetCustomersRequest) URL() url.URL
type GetCustomersRequestBody ¶
type GetCustomersRequestBody struct{}
type GetCustomersResponseBody ¶
type GetCustomersResponseBody struct { MetaInformation `json:"MetaInformation"` Customers Customers }
type GetInvoicesPathParams ¶
type GetInvoicesPathParams struct { }
func (*GetInvoicesPathParams) Params ¶
func (p *GetInvoicesPathParams) Params() map[string]string
type GetInvoicesQueryParams ¶
type GetInvoicesQueryParams struct { FromDate Date `schema:"fromdate"` ToDate Date `schema:"todate"` }
func (GetInvoicesQueryParams) ToURLValues ¶
func (p GetInvoicesQueryParams) ToURLValues() (url.Values, error)
type GetInvoicesRequest ¶
type GetInvoicesRequest struct {
// contains filtered or unexported fields
}
func (*GetInvoicesRequest) Do ¶
func (r *GetInvoicesRequest) Do() (GetInvoicesResponseBody, error)
func (*GetInvoicesRequest) Method ¶
func (r *GetInvoicesRequest) Method() string
func (GetInvoicesRequest) NewGetInvoicesPathParams ¶
func (r GetInvoicesRequest) NewGetInvoicesPathParams() *GetInvoicesPathParams
func (GetInvoicesRequest) NewGetInvoicesQueryParams ¶
func (r GetInvoicesRequest) NewGetInvoicesQueryParams() *GetInvoicesQueryParams
func (GetInvoicesRequest) NewGetInvoicesRequestBody ¶
func (r GetInvoicesRequest) NewGetInvoicesRequestBody() GetInvoicesRequestBody
func (*GetInvoicesRequest) NewResponseBody ¶
func (r *GetInvoicesRequest) NewResponseBody() *GetInvoicesResponseBody
func (*GetInvoicesRequest) PathParams ¶
func (r *GetInvoicesRequest) PathParams() *GetInvoicesPathParams
func (*GetInvoicesRequest) QueryParams ¶
func (r *GetInvoicesRequest) QueryParams() *GetInvoicesQueryParams
func (*GetInvoicesRequest) RequestBody ¶
func (r *GetInvoicesRequest) RequestBody() *GetInvoicesRequestBody
func (*GetInvoicesRequest) SetMethod ¶
func (r *GetInvoicesRequest) SetMethod(method string)
func (*GetInvoicesRequest) SetRequestBody ¶
func (r *GetInvoicesRequest) SetRequestBody(body GetInvoicesRequestBody)
func (*GetInvoicesRequest) URL ¶
func (r *GetInvoicesRequest) URL() url.URL
type GetInvoicesRequestBody ¶
type GetInvoicesRequestBody struct{}
type GetInvoicesResponseBody ¶
type GetInvoicesResponseBody struct { MetaInformation `json:"MetaInformation"` Invoices Invoices }
type GetPredefinedVoucherSeriesPathParams ¶
type GetPredefinedVoucherSeriesPathParams struct { }
func (*GetPredefinedVoucherSeriesPathParams) Params ¶
func (p *GetPredefinedVoucherSeriesPathParams) Params() map[string]string
type GetPredefinedVoucherSeriesQueryParams ¶
type GetPredefinedVoucherSeriesQueryParams struct { }
func (GetPredefinedVoucherSeriesQueryParams) ToURLValues ¶
func (p GetPredefinedVoucherSeriesQueryParams) ToURLValues() (url.Values, error)
type GetPredefinedVoucherSeriesRequest ¶
type GetPredefinedVoucherSeriesRequest struct {
// contains filtered or unexported fields
}
func (*GetPredefinedVoucherSeriesRequest) Do ¶
func (r *GetPredefinedVoucherSeriesRequest) Do() (GetPredefinedVoucherSeriesResponseBody, error)
func (*GetPredefinedVoucherSeriesRequest) Method ¶
func (r *GetPredefinedVoucherSeriesRequest) Method() string
func (GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesPathParams ¶
func (r GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesPathParams() *GetPredefinedVoucherSeriesPathParams
func (GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesQueryParams ¶
func (r GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesQueryParams() *GetPredefinedVoucherSeriesQueryParams
func (GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesRequestBody ¶
func (r GetPredefinedVoucherSeriesRequest) NewGetPredefinedVoucherSeriesRequestBody() GetPredefinedVoucherSeriesRequestBody
func (*GetPredefinedVoucherSeriesRequest) NewResponseBody ¶
func (r *GetPredefinedVoucherSeriesRequest) NewResponseBody() *GetPredefinedVoucherSeriesResponseBody
func (*GetPredefinedVoucherSeriesRequest) PathParams ¶
func (r *GetPredefinedVoucherSeriesRequest) PathParams() *GetPredefinedVoucherSeriesPathParams
func (*GetPredefinedVoucherSeriesRequest) QueryParams ¶
func (r *GetPredefinedVoucherSeriesRequest) QueryParams() *GetPredefinedVoucherSeriesQueryParams
func (*GetPredefinedVoucherSeriesRequest) RequestBody ¶
func (r *GetPredefinedVoucherSeriesRequest) RequestBody() *GetPredefinedVoucherSeriesRequestBody
func (*GetPredefinedVoucherSeriesRequest) SetMethod ¶
func (r *GetPredefinedVoucherSeriesRequest) SetMethod(method string)
func (*GetPredefinedVoucherSeriesRequest) SetRequestBody ¶
func (r *GetPredefinedVoucherSeriesRequest) SetRequestBody(body GetPredefinedVoucherSeriesRequestBody)
func (*GetPredefinedVoucherSeriesRequest) URL ¶
func (r *GetPredefinedVoucherSeriesRequest) URL() url.URL
type GetPredefinedVoucherSeriesRequestBody ¶
type GetPredefinedVoucherSeriesRequestBody struct{}
type GetPredefinedVoucherSeriesResponseBody ¶
type GetPredefinedVoucherSeriesResponseBody struct { MetaInformation `json:"MetaInformation"` PreDefinedVoucherSeriesCollection []struct { URL string `json:"@url"` Name string `json:"Name"` VoucherSeries string `json:"VoucherSeries"` } `json:"PreDefinedVoucherSeriesCollection"` }
type GetVouchersPathParams ¶
type GetVouchersPathParams struct { }
func (*GetVouchersPathParams) Params ¶
func (p *GetVouchersPathParams) Params() map[string]string
type GetVouchersQueryParams ¶
type GetVouchersQueryParams struct { }
func (GetVouchersQueryParams) ToURLValues ¶
func (p GetVouchersQueryParams) ToURLValues() (url.Values, error)
type GetVouchersRequest ¶
type GetVouchersRequest struct {
// contains filtered or unexported fields
}
func (*GetVouchersRequest) Do ¶
func (r *GetVouchersRequest) Do() (GetVouchersResponseBody, error)
func (*GetVouchersRequest) Method ¶
func (r *GetVouchersRequest) Method() string
func (GetVouchersRequest) NewGetVouchersPathParams ¶
func (r GetVouchersRequest) NewGetVouchersPathParams() *GetVouchersPathParams
func (GetVouchersRequest) NewGetVouchersQueryParams ¶
func (r GetVouchersRequest) NewGetVouchersQueryParams() *GetVouchersQueryParams
func (GetVouchersRequest) NewGetVouchersRequestBody ¶
func (r GetVouchersRequest) NewGetVouchersRequestBody() GetVouchersRequestBody
func (*GetVouchersRequest) NewResponseBody ¶
func (r *GetVouchersRequest) NewResponseBody() *GetVouchersResponseBody
func (*GetVouchersRequest) PathParams ¶
func (r *GetVouchersRequest) PathParams() *GetVouchersPathParams
func (*GetVouchersRequest) QueryParams ¶
func (r *GetVouchersRequest) QueryParams() *GetVouchersQueryParams
func (*GetVouchersRequest) RequestBody ¶
func (r *GetVouchersRequest) RequestBody() *GetVouchersRequestBody
func (*GetVouchersRequest) SetMethod ¶
func (r *GetVouchersRequest) SetMethod(method string)
func (*GetVouchersRequest) SetRequestBody ¶
func (r *GetVouchersRequest) SetRequestBody(body GetVouchersRequestBody)
func (*GetVouchersRequest) URL ¶
func (r *GetVouchersRequest) URL() url.URL
type GetVouchersRequestBody ¶
type GetVouchersRequestBody struct{}
type GetVouchersResponseBody ¶
type GetVouchersResponseBody struct { MetaInformation `json:"MetaInformation"` Vouchers Vouchers }
type Invoice ¶
type Invoice struct { URL utils.URL `json:"@url,omitempty"` // Direct url to the record. UrlTaxReductionList string `json:"@UrlTaxReductionList,omitempty"` // Direct url to the tax reduction for the invoice. This is visible even if no tax reduction exists. AccountingMethod string `json:"AccountingMethod"` // Accounting Method. Can be ACCRUAL orCASH AdministrationFee float64 `json:"AdministrationFee"` // The invoice administration fee. AdministrationFeeVAT float64 `json:"AdministrationFeeVAT,omitempty"` // VAT of the invoice administration fee. Address1 string `json:"Address1"` // Invoice address 1. Address2 string `json:"Address2"` // Invoice address 2. Balance float64 `json:"Balance,omitempty"` // Balance of the invoice. BasisTaxReduction float64 `json:"BasisTaxReduction,omitempty"` // Basis of tax reduction. Booked null.Bool `json:"Booked"` // If the invoice is bookkept. This value can be changed by using the action “bookkeep”. Cancelled null.Bool `json:"Cancelled,omitempty"` // If the invoice is cancelled. This value can be changed by using the action “cancel”. Credit string `json:"Credit,omitempty"` // If the invoice is a credit invoice. CreditInvoiceReference string `json:"CreditInvoiceReference,omitempty"` // Reference to the credit invoice, if one exits. The reference must be a document number for an existing credit invoice. City string `json:"City,omitempty"` // City for the invoice address. Comments string `json:"Comments"` // Comments of the invoice ContractReference string `json:"ContractReference,omitempty"` // Reference to the contract, if one exists. ContributionPercent float64 `json:"ContributionPercent,omitempty"` // Invoice contribution in percent. ContributionValue float64 `json:"ContributionValue,omitempty"` // Invoice contribution in amount. Country string `json:"Country"` // Country for the invoice address. Must be a name of an existing country. CostCenter string `json:"CostCenter,omitempty"` // Code of the cost center. The code must be of an existing cost center. Currency string `json:"Currency"` // Code of the currency. The code must be of an existing currency. CurrencyRate Number `json:"CurrencyRate"` // Currency rate used for the invoice. CurrencyUnit float64 `json:"CurrencyUnit"` // Currency unit used for the invoice. CustomerName string `json:"CustomerName"` // Name of the customer. CustomerNumber string `json:"CustomerNumber"` // Customer number of the customer. The customer number must be of an existing customer. DeliveryAddress1 string `json:"DeliveryAddress1"` // Invoice delivery address 1. DeliveryAddress2 string `json:"DeliveryAddress2"` // Invoice delivery address 2. DeliveryCity string `json:"DeliveryCity"` // City for the invoice delivery address. DeliveryCountry string `json:"DeliveryCountry"` // Country for the invoice delivery address. Must be a name of an existing country. DeliveryDate Date `json:"DeliveryDate"` // Date of delivery. Must be a valid date according to our date format. DeliveryName string `json:"DeliveryName"` // Name of the recipient of the delivery DeliveryZipCode string `json:"DeliveryZipCode"` // ZipCode for the invoice delivery address. DocumentNumber string `json:"DocumentNumber"` // The invoice number. If no document number is provided, the next number in the series will be used. DueDate Date `json:"DueDate"` // Due date of the invoice. Must be a valid date according to our date format. EDIInformation *EDIInformation `json:"EDIInformation,omitempty"` // The properties for this object is listed in the table for “EDI Information”. EmailInformation *EmailInformation `json:"EmailInformation,omitempty"` // The properties for this object is listed in the table for “Email Information”. EUQuarterlyReport bool `json:"EUQuarterlyReport"` // EU Quarterly Report On / Off ExternalInvoiceReference1 string `json:"ExternalInvoiceReference1"` // External invoice reference 1. ExternalInvoiceReference2 string `json:"ExternalInvoiceReference2"` // External invoice reference 1. FinalPayDate Date `json:"FinalPayDate,omitempty"` // The date when the invoice became fully paid. Only available if the invoice is fully paid. Freight float64 `json:"Freight"` // Freight cost of the invoice. FreightVAT float64 `json:"FreightVAT,omitempty"` // VAT of the freight cost. Gross float64 `json:"Gross,omitempty"` // Gross value of the invoice HouseWork null.Bool `json:"HouseWork,omitempty"` // If there is any row of the invoice marked “house work”. InvoiceDate Date `json:"InvoiceDate"` // Invoice date. Must be a valid date according to our date format. InvoicePeriodStart Date `json:"InvoicePeriodStart,omitempty"` // Start date of the invoice period, only applicable for contract invoices. InvoicePeriodEnd Date `json:"InvoicePeriodEnd,omitempty"` // End date of the invoice period, only applicable for contract invoices. InvoiceReference string `json:"InvoiceReference,omitempty"` InvoiceRows InvoiceRows `json:"InvoiceRows"` // The properties for the object in this array is listed in the table “Invoice Rows”. InvoiceType InvoiceType `json:"InvoiceType"` // The type of invoice. Can be INVOICE AGREEMENTINVOICE INTRESTINVOICE SUMMARYINVOICE or CASHINVOICE. Labels Labels `json:"Labels"` // The properties for the object in this array is listed in the table “Labels” Language string `json:"Language"` // Language code. Can be SV or EN. LastRemindDate Date `json:"LastRemindDate,omitempty"` // Date of last reminder. Net float64 `json:"Net,omitempty"` // Net amount NotCompleted bool `json:"NotCompleted"` // If the invoice is set as not completed. NoxFinans null.Bool `json:"NoxFinans,omitempty"` // If the invoice is managed by NoxFinans OCR string `json:"OCR"` // OCR number of the invoice. OfferReference string `json:"OfferReference,omitempty"` // Reference to the offer, if one exists. OrderReference string `json:"OrderReference,omitempty"` // Reference to the order, if one exists. OrganisationNumber string `json:"OrganisationNumber,omitempty"` // Organisation number of the customer for the invoice. OurReference string `json:"OurReference"` // Our reference. PaymentWay PaymentWay `json:"PaymentWay,omitempty"` // CASH, CARD, AG Phone1 string `json:"Phone1"` // Phone number 1 of the customer for the invoice. Phone2 string `json:"Phone2"` // Phone number 2 of the customer for the invoice. PriceList string `json:"PriceList"` // Code of the price list. The code must be of an existing price list. PrintTemplate string `json:"PrintTemplate"` // Print template of the invoice. Must be an existing print template. Project string `json:"Project"` // Code of the project. The code must be of an existing project. WarehouseReady null.Bool `json:"WarehouseReady,omitempty"` OutboundDate Date `json:"OutboundDate"` Remarks string `json:"Remarks"` // Remarks of the invoice. This is the invoice text shown on the invoice. Reminders int `json:"Reminders,omitempty"` // Number of reminders sent to the customer. RoundOff float64 `json:"RoundOff,omitempty"` // Round off amount for the invoice. Sent null.Bool `json:"Sent,omitempty"` // If the document is printed or sent in any way. TaxReduction int `json:"TaxReduction,omitempty"` // The amount of tax reduction. TermsOfDelivery string `json:"TermsOfDelivery"` // Code of the terms of delivery. The code must be of an existing terms of delivery. TermsOfPayment string `json:"TermsOfPayment"` // Code of the terms of payment. The code must be of an existing terms of payment. Total float64 `json:"Total,omitempty"` // The total amount of the invoice. TotalVAT float64 `json:"TotalVAT,omitempty"` // The total VAT amount of the invoice. TotalToPay float64 `json:"TotalToPay,omitempty"` VATIncluded bool `json:"VATIncluded"` // If the price of the invoice is including VAT. VoucherNumber int `json:"VoucherNumber,omitempty"` // Voucher number for the invoice. This is created when the invoice is bookkept. VoucherSeries string `json:"VoucherSeries,omitempty"` // Voucher series for the invoice. This is created when the invoice is bookkept. VoucherYear int `json:"VoucherYear,omitempty"` // Voucher year for the invoice. This is created when the invoice is bookkept. WayOfDelivery string `json:"WayOfDelivery,omitempty"` // Code of the way of delivery. The code must be of an existing way of delivery. YourOrderNumber string `json:"YourOrderNumber"` // Your order number. YourReference string `json:"YourReference"` // Your reference. ZipCode string `json:"ZipCode"` // Zip code of the invoice. }
type InvoiceRow ¶
type InvoiceRow struct { AccountNumber int `json:"AccountNumber"` // Account number. If not provided the predefined account will be used. ArticleNumber string `json:"ArticleNumber"` // Article number. ContributionPercent string `json:"ContributionPercent,omitempty"` // Contribution Percent. ContributionValue string `json:"ContributionValue,omitempty"` // Contribution Value. CostCenter string `json:"CostCenter,omitempty"` // Code of the cost center for the row. The code must be of an existing cost center. DeliveredQuantity string `json:"DeliveredQuantity"` // Delivered quantity. Description string `json:"Description"` // Row description. Discount float64 `json:"Discount"` // Discount amount. // 12 digits (for amount) / 5 digits (for percent) DiscountType string `json:"DiscountType"` // The type of discount used for the row. Can be AMOUNT or PERCENT. HouseWork bool `json:"HouseWork"` // If the row is housework HouseWorkHoursToReport int `json:"HouseWorkHoursToReport"` // Hours to be reported if the quantity of the row should not be used as hours. HouseWorkType string `json:"HouseWorkType"` // The type of house work. Can be // CONSTRUCTIONELECTRICITYGLASSMETALWORK // GROUNDDRAINAGEWORKMASONRY // PAINTINGWALLPAPERINGHVACMAJORAPPLIANCEREPAIR // MOVINGSERVICESITSERVICESCLEANINGTEXTILECLOTHINGSNOWPLOWING // GARDENINGBABYSITTINGOTHERCAREOTHERCOSTS or empty. Price float64 `json:"Price"` // Price per unit PriceExcludingVAT float64 `json:"PriceExcludingVAT,omitempty"` // Price per unit excluding VAT (regardless of value of VATIncluded flag) Project string `json:"Project,omitempty"` // Code of the project for the row. The code must be of an existing project. StockPointCode string `json:"StockPointCode,omitempty"` Total float64 `json:"Total,omitempty"` // Total amount for the row. TotalExcludingVAT float64 `json:"TotalExcludingVAT,omitempty"` // Total amount for the row excluding VAT (regardless of value of VATIncluded flag) Unit string `json:"Unit"` // Code of the unit for the row. The code must be of an existing unit. VAT int `json:"VAT"` // VAT percentage of the row. The percentage needs to be of an existing VAT percentage. }
type InvoiceRows ¶
type InvoiceRows []InvoiceRow
type InvoiceType ¶
type InvoiceType string
var ( InvoiceTypeInvoice InvoiceType = "INVOICE" InvoiceTypeAgreementInvoice InvoiceType = "AGREEMENTINVOICE" InvoiceTypeIntrestInvoice InvoiceType = "INTRESTINVOICE" InvoiceTypeSummaryInvoice InvoiceType = "SUMMARYINVOICE" InvoiceTypeCashInvoice InvoiceType = "CASHINVOICE" )
type MetaInformation ¶
type Oauth2Config ¶
func NewOauth2Config ¶
func NewOauth2Config() *Oauth2Config
type PathParams ¶
type PaymentWay ¶
type PaymentWay string
var ( PaymentWayCash PaymentWay = "CASH" // Payment Way is set to Cash payment PaymentWayCard PaymentWay = "Card" // Payment Way is set to Card. PaymentWayAG PaymentWay = "AG" // Payment Way is set to Direct debit )
type PostCustomerPathParams ¶
type PostCustomerPathParams struct { }
func (*PostCustomerPathParams) Params ¶
func (p *PostCustomerPathParams) Params() map[string]string
type PostCustomerQueryParams ¶
type PostCustomerQueryParams struct { }
func (PostCustomerQueryParams) ToURLValues ¶
func (p PostCustomerQueryParams) ToURLValues() (url.Values, error)
type PostCustomerRequest ¶
type PostCustomerRequest struct {
// contains filtered or unexported fields
}
func (*PostCustomerRequest) Do ¶
func (r *PostCustomerRequest) Do() (PostCustomerResponseBody, error)
func (*PostCustomerRequest) Method ¶
func (r *PostCustomerRequest) Method() string
func (PostCustomerRequest) NewPostCustomerPathParams ¶
func (r PostCustomerRequest) NewPostCustomerPathParams() *PostCustomerPathParams
func (PostCustomerRequest) NewPostCustomerQueryParams ¶
func (r PostCustomerRequest) NewPostCustomerQueryParams() *PostCustomerQueryParams
func (PostCustomerRequest) NewPostCustomerRequestBody ¶
func (r PostCustomerRequest) NewPostCustomerRequestBody() PostCustomerRequestBody
func (*PostCustomerRequest) NewResponseBody ¶
func (r *PostCustomerRequest) NewResponseBody() *PostCustomerResponseBody
func (*PostCustomerRequest) PathParams ¶
func (r *PostCustomerRequest) PathParams() *PostCustomerPathParams
func (*PostCustomerRequest) QueryParams ¶
func (r *PostCustomerRequest) QueryParams() *PostCustomerQueryParams
func (*PostCustomerRequest) RequestBody ¶
func (r *PostCustomerRequest) RequestBody() *PostCustomerRequestBody
func (*PostCustomerRequest) SetMethod ¶
func (r *PostCustomerRequest) SetMethod(method string)
func (*PostCustomerRequest) SetRequestBody ¶
func (r *PostCustomerRequest) SetRequestBody(body PostCustomerRequestBody)
func (*PostCustomerRequest) URL ¶
func (r *PostCustomerRequest) URL() url.URL
type PostCustomerRequestBody ¶
type PostCustomerRequestBody struct {
Customer Customer
}
type PostCustomerResponseBody ¶
type PostCustomerResponseBody struct { MetaInformation `json:"MetaInformation"` Customer Customer }
type PostInvoicePathParams ¶
type PostInvoicePathParams struct { }
func (*PostInvoicePathParams) Params ¶
func (p *PostInvoicePathParams) Params() map[string]string
type PostInvoiceQueryParams ¶
type PostInvoiceQueryParams struct { }
func (PostInvoiceQueryParams) ToURLValues ¶
func (p PostInvoiceQueryParams) ToURLValues() (url.Values, error)
type PostInvoiceRequest ¶
type PostInvoiceRequest struct {
// contains filtered or unexported fields
}
func (*PostInvoiceRequest) Do ¶
func (r *PostInvoiceRequest) Do() (PostInvoiceResponseBody, error)
func (*PostInvoiceRequest) Method ¶
func (r *PostInvoiceRequest) Method() string
func (PostInvoiceRequest) NewPostInvoicePathParams ¶
func (r PostInvoiceRequest) NewPostInvoicePathParams() *PostInvoicePathParams
func (PostInvoiceRequest) NewPostInvoiceQueryParams ¶
func (r PostInvoiceRequest) NewPostInvoiceQueryParams() *PostInvoiceQueryParams
func (PostInvoiceRequest) NewPostInvoiceRequestBody ¶
func (r PostInvoiceRequest) NewPostInvoiceRequestBody() PostInvoiceRequestBody
func (*PostInvoiceRequest) NewResponseBody ¶
func (r *PostInvoiceRequest) NewResponseBody() *PostInvoiceResponseBody
func (*PostInvoiceRequest) PathParams ¶
func (r *PostInvoiceRequest) PathParams() *PostInvoicePathParams
func (*PostInvoiceRequest) QueryParams ¶
func (r *PostInvoiceRequest) QueryParams() *PostInvoiceQueryParams
func (*PostInvoiceRequest) RequestBody ¶
func (r *PostInvoiceRequest) RequestBody() *PostInvoiceRequestBody
func (*PostInvoiceRequest) SetMethod ¶
func (r *PostInvoiceRequest) SetMethod(method string)
func (*PostInvoiceRequest) SetRequestBody ¶
func (r *PostInvoiceRequest) SetRequestBody(body PostInvoiceRequestBody)
func (*PostInvoiceRequest) URL ¶
func (r *PostInvoiceRequest) URL() url.URL
type PostInvoiceRequestBody ¶
type PostInvoiceRequestBody struct {
Invoice Invoice
}
type PostInvoiceResponseBody ¶
type PostInvoiceResponseBody struct { MetaInformation `json:"MetaInformation"` Invoice Invoice }
type PostVoucherPathParams ¶
type PostVoucherPathParams struct { }
func (*PostVoucherPathParams) Params ¶
func (p *PostVoucherPathParams) Params() map[string]string
type PostVoucherQueryParams ¶
type PostVoucherQueryParams struct { }
func (PostVoucherQueryParams) ToURLValues ¶
func (p PostVoucherQueryParams) ToURLValues() (url.Values, error)
type PostVoucherRequest ¶
type PostVoucherRequest struct {
// contains filtered or unexported fields
}
func (*PostVoucherRequest) Do ¶
func (r *PostVoucherRequest) Do() (PostVoucherResponseBody, error)
func (*PostVoucherRequest) Method ¶
func (r *PostVoucherRequest) Method() string
func (PostVoucherRequest) NewPostVoucherPathParams ¶
func (r PostVoucherRequest) NewPostVoucherPathParams() *PostVoucherPathParams
func (PostVoucherRequest) NewPostVoucherQueryParams ¶
func (r PostVoucherRequest) NewPostVoucherQueryParams() *PostVoucherQueryParams
func (PostVoucherRequest) NewPostVoucherRequestBody ¶
func (r PostVoucherRequest) NewPostVoucherRequestBody() PostVoucherRequestBody
func (*PostVoucherRequest) NewResponseBody ¶
func (r *PostVoucherRequest) NewResponseBody() *PostVoucherResponseBody
func (*PostVoucherRequest) PathParams ¶
func (r *PostVoucherRequest) PathParams() *PostVoucherPathParams
func (*PostVoucherRequest) QueryParams ¶
func (r *PostVoucherRequest) QueryParams() *PostVoucherQueryParams
func (*PostVoucherRequest) RequestBody ¶
func (r *PostVoucherRequest) RequestBody() *PostVoucherRequestBody
func (*PostVoucherRequest) SetMethod ¶
func (r *PostVoucherRequest) SetMethod(method string)
func (*PostVoucherRequest) SetRequestBody ¶
func (r *PostVoucherRequest) SetRequestBody(body PostVoucherRequestBody)
func (*PostVoucherRequest) URL ¶
func (r *PostVoucherRequest) URL() url.URL
type PostVoucherRequestBody ¶
type PostVoucherRequestBody struct {
Voucher Voucher
}
type PostVoucherResponseBody ¶
type PostVoucherResponseBody struct { MetaInformation `json:"MetaInformation"` Voucher Voucher }
type RequestCompletionCallback ¶
RequestCompletionCallback defines the type of the request callback function
type VATType ¶
type VATType string
VAT type of the customer. Can be SEVAT SEREVERSEDVAT EUREVERSEDVAT EUVAT or EXPORT.
type Voucher ¶
type Voucher struct { URL string `json:"@url,omitempty"` // Direct URL to the record. Comments string `json:"Comments"` // Comments of the voucher. CostCenter string `json:"CostCenter,omitempty"` // Code of the cost center. The code must be of an existing cost center. Description string `json:"Description"` // Description of the voucher. Project string `json:"Project"` // Code of the project. The code must be of an existing project. ReferenceNumber string `json:"ReferenceNumber,omitempty"` // Reference number, for example an invoice number. ReferenceType string `json:"ReferenceType"` // Reference type. Can be INVOICE SUPPLIERINVOICE INVOICEPAYMENT SUPPLIERPAYMENT MANUAL CASHINVOICE or ACCRUAL TransactionDate Date `json:"TransactionDate"` // Date of the transaction. Must be a valid date according to our date format. VoucherNumber int `json:"VoucherNumber,omitempty"` // Number of the voucher VoucherRows VoucherRows `json:"VoucherRows"` // The properties for the object in this array is listed in the table for “Voucher Rows”. VoucherSeries string `json:"VoucherSeries"` // Code of the voucher series. The code must be of an existing voucher series. Year int `json:"Year,omitempty"` // Id of the year of the voucher. ApprovalState ApprovalState `json:"ApprovalState,omitempty"` // // The approval state f the voucher. }
type VoucherRow ¶
type VoucherRow struct { Account int `json:"Account"` // Account number. The number must be of an existing active account. CostCenter string `json:"CostCenter,omitempty"` // Code of the cost center. The code must be of an existing cost center. Credit float64 `json:"Credit"` // Amount of credit. Description string `json:"Description"` // The description of the account. Debit float64 `json:"Debit"` // Amount of debit. Project string `json:"Project"` // Code of the project. The code must be of an existing project. Removed bool `json:"Removed,omitempty"` // If the row is marked as removed. TransactionInformation string `json:"TransactionInformation"` // Transaction information regarding the row. Quantity int `json:"Quantity,omitempty"` }
type VoucherRows ¶
type VoucherRows []VoucherRow
Source Files ¶
- account.go
- client.go
- customer.go
- date.go
- datetime.go
- get_accounts.go
- get_company_settings.go
- get_customer.go
- get_customers.go
- get_invoices.go
- get_predefined_voucher_series.go
- get_vouchers.go
- invoice.go
- json_types.go
- meta_information.go
- oauth.go
- post_customer.go
- post_invoice.go
- post_voucher.go
- voucher.go