models

package
v0.3.10 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrEnvironmentNotFound = errors.New("environment id not found")
View Source
var Version = "1.0.0"

Version will be changed automatically on build

Functions

This section is empty.

Types

type CampaignActivation

type CampaignActivation struct {
	EnvID           string `json:"cid"`
	VisitorID       string `json:"vid"`
	CustomerID      string `json:"cuid"`
	CampaignID      string `json:"caid"`
	VariationID     string `json:"vaid"`
	Timestamp       int64
	PersistActivate bool
	QA              bool  `json:"qa"`
	QueueTime       int64 `json:"qt"`
}

CampaignActivation represents a single campaign activation

func (*CampaignActivation) ComputeQueueTime

func (c *CampaignActivation) ComputeQueueTime()

func (*CampaignActivation) ToMap

func (c *CampaignActivation) ToMap() map[string]interface{}

type CorsOptions

type CorsOptions struct {
	Enabled        bool
	AllowedOrigins string
	AllowedHeaders string
}

type Environment

type Environment struct {
	Common          *common.Environment
	HasIntegrations bool
}

type MappableHit

type MappableHit interface {
	ToMap() map[string]interface{}
	ComputeQueueTime()
}

type VisitorContext

type VisitorContext struct {
	EnvID      string                 `json:"cid"`
	VisitorID  string                 `json:"vid"`
	CustomerID string                 `json:"cuid"`
	Context    map[string]interface{} `json:"s"`
	Partner    string                 `json:"pa,omitempty"`
	Timestamp  int64
	QueueTime  int64 `json:"qt"`
}

func (*VisitorContext) ComputeQueueTime

func (c *VisitorContext) ComputeQueueTime()

func (*VisitorContext) ToMap

func (c *VisitorContext) ToMap() map[string]interface{}

Jump to

Keyboard shortcuts

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