collections

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2023 License: CC0-1.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cycle

type Cycle struct {
	SubscriptionId string    `bson:"subscription_id"`
	TemplateIds    []string  `bson:"template_ids"`
	StartDate      time.Time `bson:"start_date"`
	EndDate        time.Time `bson:"end_date"`
	SendByDate     time.Time `bson:"send_by_date"`
	Active         bool      `bson:"active"`
	TargetCount    int       `bson:"target_count"`
}

func GetCycle

func GetCycle(id string) (Cycle, error)

GetCycle returns a cycle by id

type Notification

type Notification struct {
	Name          string `bson:"name"`
	Subject       string `bson:"subject"`
	Html          string `bson:"html"`
	TaskName      string `bson:"task_name"`
	Text          string `bson:"text"`
	HasAttachment bool   `bson:"has_attachment"`
}

func GetNotification

func GetNotification(TaskName string) (Notification, error)

GetNotification returns a notification template by task name

type Phish

type Phish struct {
	Name    string `bson:"name"`
	Subject string `bson:"subject"`
	Html    string `bson:"html"`
	Text    string `bson:"text"`
	Retired bool   `bson:"retired"`
}

func GetPhish

func GetPhish(Name string) (Phish, error)

GetPhish returns a phish template by name

type PrimaryContact

type PrimaryContact struct {
	FirstName   string `bson:"first_name"`
	LastName    string `bson:"last_name"`
	Title       string `bson:"title"`
	OfficePhone string `bson:"office_phone"`
	MobilePhone string `bson:"mobile_phone"`
	Email       string `bson:"email"`
	Notes       string `bson:"notes"`
	Active      bool   `bson:"active"`
}

type Subscription

type Subscription struct {
	Name                   string              `bson:"name"`
	CustomerID             string              `bson:"customer_id"`
	SendingProfileID       string              `bson:"sending_profile_id"`
	TargetDomain           string              `bson:"target_domain"`
	Customer               string              `bson:"customer"`
	StartDate              time.Time           `bson:"start_date"`
	PrimaryContact         PrimaryContact      `bson:"primary_contact"`
	AdminEmail             string              `bson:"admin_email"`
	OperatorEmail          string              `bson:"operator_email"`
	Status                 string              `bson:"status"`
	CycleStartDate         string              `bson:"cycle_start_date"`
	TargetEmailList        []TargetEmail       `bson:"target_email_list"`
	TemplatesSelected      []string            `bson:"templates_selected"`
	NextTemplates          []string            `bson:"next_templates"`
	ContinuousSubscription bool                `bson:"continuous_subscription"`
	BufferTimeMinutes      int                 `bson:"buffer_time_minutes"`
	CycleLengthMinutes     int                 `bson:"cycle_length_minutes"`
	CooldownMinutes        int                 `bson:"cooldown_minutes"`
	ReportFrequencyMinutes int                 `bson:"report_frequency_minutes"`
	Tasks                  []SubscriptionTasks `bson:"tasks"`
	Processing             bool                `bson:"processing"`
	Archived               bool                `bson:"archived"`
}

func GetSubscription

func GetSubscription(id string) (Subscription, error)

GetSubscription returns a notification template by task name

type SubscriptionTasks

type SubscriptionTasks struct {
	TaskUUID      string    `bson:"task_uuid"`
	TaskType      string    `bson:"task_type"`
	ScheduledDate time.Time `bson:"scheduled_date"`
	Executed      bool      `bson:"executed"`
	ExecutedDate  time.Time `bson:"executed_date"`
	Error         string    `bson:"error"`
}

type TargetEmail

type TargetEmail struct {
	Email     string `bson:"email"`
	FirstName string `bson:"first_name"`
	LastName  string `bson:"last_name"`
	Position  string `bson:"position"`
}

Jump to

Keyboard shortcuts

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