Documentation ¶
Index ¶
Constants ¶
View Source
const ( DiscriminatorPattern = "event_type\":\"%s\"" DiscriminatorV1Search = "search" DiscriminatorV1DetailPageView = "detail-page-view" DiscriminatorV1AddToCart = "add-to-cart" DiscriminatorV1PurchaseComplete = "purchase-complete" )
View Source
const ( ConfigFile = "-configFile=examples/configs/events-test-config.json" SampleRate = "-sampleRate=1" )
Variables ¶
This section is empty.
Functions ¶
func BuildV1Discriminator ¶
Types ¶
type AddToCart ¶
type AddToCart struct {
CommonData
}
type CommonData ¶
type CommonData struct { EventType string `json:"event_type"` EventTime string `json:"event_time"` VisitorId string `json:"visitor_id"` SessionId string `json:"session_id"` ProductDetails []ProductDetail `json:"product_details"` }
type DetailPageView ¶
type DetailPageView struct {
CommonData //
}
type ProductDetail ¶
type PurchaseComplete ¶
type PurchaseComplete struct { CommonData PurchaseTransaction struct { Id string `json:"id"` Revenue float32 `json:"revenue"` Tax float32 `json:"tax"` CurrencyCode string `json:"currency_code"` } `json:"purchase_transaction"` }
type Search ¶
type Search struct { CommonData SearchQuery string `json:"search_query"` }
Click to show internal directories.
Click to hide internal directories.