analytics

package
v1.37.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 19, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Analytics

type Analytics struct {
	Integrations []Integration `json:"integrations,omitempty"`
}

func (Analytics) SnippetJSON

func (a Analytics) SnippetJSON() []byte

Only JSON encode enabled integrations

func (Analytics) UpdateShownDisabledStatus

func (a Analytics) UpdateShownDisabledStatus() Analytics

func (Analytics) UpdateStoredDisabledStatus

func (a Analytics) UpdateStoredDisabledStatus() Analytics

type Custom

type Custom struct {
	Code string `json:"code,omitempty"`
}

Integration specific properties

type FacebookConversions

type FacebookConversions struct {
	Value    string `json:"value,omitempty"`
	Currency string `json:"currency,omitempty"`
}

type FacebookPixel

type FacebookPixel struct {
	Values Values `json:"values,omitempty"`
}

type GoogleAdWords

type GoogleAdWords struct {
}

type GoogleAnalytics

type GoogleAnalytics struct {
}

type Heap

type Heap struct {
}

type Integration

type Integration struct {
	Name      string `json:"-"`
	Disabled  bool   `json:"-"`
	Disabled_ *bool  `json:"disabled,omitempty" datastore:"-"`

	// Common to all integrations
	Type          string `json:"type"`
	Event         string `json:"event,omitempty"`
	Id            string `json:"id,omitempty"`
	IntegrationId string `json:"-"`

	// Sampling percentage
	Sampling float64 `json:"sampling,omitempty"`

	// Available integrations
	Custom
	FacebookConversions
	FacebookPixel
	GoogleAdWords
	GoogleAnalytics
}

type Sentry

type Sentry struct {
}

type Value

type Value struct {
	Percent float64        `json:"percent,omitempty"`
	Value   currency.Cents `json:"value,omitempty"`
}

Override value for a given event

type Values

type Values struct {
	Currency         currency.Type `json:"currency,omitempty"`
	ViewedProduct    Value         `json:"viewedProduct,omitempty"`
	AddedProduct     Value         `json:"addedProduct,omitempty"`
	InitiateCheckout Value         `json:"initiateCheckout,omitempty"`
	AddPaymentInfo   Value         `json:"addPaymentInfo,omitempty"`
}

Event specific value overrides

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL