Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Address ¶
type Address struct {
// VersionedStruct
Version int `json:"version"`
ID string `json:"id"`
Customer AddressCustomer `json:"customer"`
// Address info
Type AddressType `json:"type"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
State string `json:"state"`
Street string `json:"street"`
HouseNumber string `json:"houseNumber"`
City string `json:"city"`
Zip string `json:"zip"`
Latitude float64 `json:"latitude"`
Longitude float64 `json:"longitude"`
Phone string `json:"phone"`
AdditionalAddressInfo string `json:"additionalAddressInfo"`
CreatedAt time.Time `json:"createdAt"`
Revision int `json:"revision"` // Each change on the customer increments the revision
}
func NewAddress ¶
type AddressCustomer ¶
type AddressCustomer struct {
CustomerID string `json:"id"`
CustomerType CustomerType `json:"type"`
}
func (*AddressCustomer) Protobuf ¶ added in v1.2.0
func (a *AddressCustomer) Protobuf() *protobuf.Address_Customer
type AddressType ¶
type AddressType string
const ( AddressTypeInvoice AddressType = "INVOICE" AddressTypeDelivery AddressType = "DELIVERY" )
type Customer ¶
type Customer struct {
// VersionedStruct
Version int `json:"version"`
ID string `json:"id"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
Gender string `json:"gender"`
CompanyName *string `json:"companyName"`
Email string `json:"email"`
CustomerType CustomerType `json:"customerType"` // PERSONAL | BUSINESS
Revision int `json:"revision"` // Each change on the customer increments the revision
}
func NewCustomer ¶
func NewCustomer() Customer
type CustomerType ¶
type CustomerType string
const ( CustomerTypePersonal CustomerType = "PERSONAL" CustomerTypeBusiness CustomerType = "BUSINESS" )
type FrontendEvent ¶
type FrontendEvent struct {
// VersionedStruct
Version int `json:"version"`
RequestedURL string `json:"requestedUrl"`
Method string `json:"method"`
CorrelationID string `json:"correlationId"`
IPAddress string `json:"ipAddress"`
RequestDuration int `json:"requestDuration"`
Response FrontendEventResponse `json:"response"`
Headers map[string]string `json:"headers"`
}
func NewFrontendEvent ¶
func NewFrontendEvent() FrontendEvent
type FrontendEventResponse ¶
type Order ¶
type Order struct {
// VersionedStruct
Version int `json:"version"`
ID string `json:"id"`
CreatedAt time.Time `json:"createdAt"`
LastUpdatedAt time.Time `json:"lastUpdatedAt"`
DeliveredAt *time.Time `json:"deliveredAt"`
CompletedAt *time.Time `json:"completedAt"`
Customer Customer `json:"customer"`
OrderValue int `json:"orderValue"`
LineItems []OrderLineItem `json:"lineItems"`
Payment OrderPayment `json:"payment"`
DeliveryAddress Address `json:"deliveryAddress"`
Revision int `json:"revision"`
}
type OrderDeliveryAddress ¶
type OrderDeliveryAddress struct{}
type OrderLineItem ¶
type OrderLineItem struct {
ArticleID string `json:"articleId"`
Name string `json:"name"`
Quantity int `json:"quantity"`
QuantityUnit string `json:"quantityUnit"`
UnitPrice int `json:"unitPrice"`
TotalPrice int `json:"totalPrice"`
}
func (*OrderLineItem) Protobuf ¶ added in v1.2.0
func (o *OrderLineItem) Protobuf() *protobuf.Order_LineItem
type OrderPayment ¶
type OrderPayment struct {
PaymentID string `json:"paymentId"`
Method string `json:"method"` // PAYPAL | CREDIT_CARD | DEBIT | CASH
}
func (*OrderPayment) Protobuf ¶ added in v1.2.0
func (o *OrderPayment) Protobuf() *protobuf.Order_Payment
Click to show internal directories.
Click to hide internal directories.