events

package
v1.7.1 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AWS_SESSION *awsSession.Session = nil
View Source
var WAREHOUSE_QUEUE_NAME string = "warehouse-data-transfer"
View Source
var WAREHOUSE_QUEUE_URL *string

Functions

func SendCostEvent

func SendCostEvent(costEvent CostEvent)

func SetAWSCredentials

func SetAWSCredentials(awsAccessKey, awsSecretKey, awsRegion string) error

Types

type CostEvent

type CostEvent struct {
	ServiceType      Service `json:"service"`
	Vendor           Vendor  `json:"vendor"`
	ClientUUID       string  `json:"client_uuid"`
	FlowUUID         string  `json:"flow_uuid"`
	CallUUID         string  `json:"call_uuid"`
	ConversationUUID string  `json:"conversation_uuid"`
	NumHits          int     `json:"num_hits"`
	Cost             int     `json:"cost"`
}

func NewCostEvent

func NewCostEvent(service Service, vendor Vendor, clientUUID string, flowUUID string, callUUID string, conversationUUID string) CostEvent

func NewCostEventWithCost

func NewCostEventWithCost(service Service, vendor Vendor, clientUUID string, flowUUID string, callUUID string, conversationUUID string, cost int) CostEvent

func NewCostEventWithNumHits

func NewCostEventWithNumHits(service Service, vendor Vendor, clientUUID string, flowUUID string, callUUID string, conversationUUID string, numHits int) CostEvent

type Events

type Events string
const (
	WAREHOUSE_COST_TRACKER Events = "WAREHOUSE_COST_TRACKER"
)

type Service

type Service string
const (
	ASR       Service = "ASR"
	TTS       Service = "TTS"
	SLU       Service = "SLU"
	LID       Service = "LID"
	SMS       Service = "SMS"
	TELEPHONY Service = "TELEPHONY"
)

type Vendor

type Vendor string
const (
	NONE            Vendor = "NONE"
	GOOGLE          Vendor = "GOOGLE"
	SKIT            Vendor = "SKIT"
	AZURE           Vendor = "AZURE"
	AMAZON          Vendor = "AMAZON"
	SHORT_UTTERANCE Vendor = "SHORT_UTTERANCE"
	TCN             Vendor = "TCN"
	TWILIO          Vendor = "TWILIO"
	FAST2SMS        Vendor = "FAST2SMS"
	TWO_FA          Vendor = "TWO_FA"
	MY_OPERATOR     Vendor = "MY_OPERATOR"
	MSG91           Vendor = "MSG91"
)

Jump to

Keyboard shortcuts

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