Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3816c67b95 | ||
|
|
c18376739b | ||
|
|
6d85149be8 | ||
|
|
cf4ad9642d | ||
|
|
e1adf8cf4f |
@@ -39,4 +39,7 @@ type Client struct {
|
||||
type CustomField struct {
|
||||
Name string `json:"name"`
|
||||
Value string `json:"value"`
|
||||
Type string `json:"type,omitempty"`
|
||||
Options []string `json:"options,omitempty"`
|
||||
Required bool `json:"required"`
|
||||
}
|
||||
|
||||
@@ -26,6 +26,13 @@ type Item struct {
|
||||
Shippable bool `json:"shippable,omitempty"`
|
||||
}
|
||||
|
||||
type OrderTax struct {
|
||||
Name string `json:"taxName"`
|
||||
Rate float64 `json:"taxRate"`
|
||||
Amount float64 `json:"amount"`
|
||||
NumberForInvoice string `json:"numberForInvoice"`
|
||||
}
|
||||
|
||||
type Order struct {
|
||||
Token string `json:"token"`
|
||||
Created time.Time `json:"creationDate"`
|
||||
@@ -34,6 +41,7 @@ type Order struct {
|
||||
Subtotal float64 `json:"subtotal,omitempty"`
|
||||
Currency string `json:"currency,omitempty"`
|
||||
Total float64 `json:"grandTotal,omitempty"`
|
||||
TotalTaxable float64 `json:"taxableTotal,omitempty"`
|
||||
Status string `json:"status"`
|
||||
TotalWeight float64 `json:"totalWeight"`
|
||||
ShippingAddress Address `json:"shippingAddress,omitempty"`
|
||||
@@ -54,6 +62,7 @@ type Order struct {
|
||||
ShippingMethod string `json:"shippingMethod,omitempty"`
|
||||
ShippingRateId string `json:"shippingRateUserDefinedId,omitempty"`
|
||||
Items []Item `json:"items"`
|
||||
Taxes []OrderTax `json:"taxes,omitempty"`
|
||||
Metadata any `json:"metadata"`
|
||||
}
|
||||
|
||||
@@ -68,6 +77,8 @@ type OrderUpdate struct {
|
||||
|
||||
type Orders struct {
|
||||
TotalItems int
|
||||
Offest int
|
||||
Limit int
|
||||
Items []Order
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user