Documentation
¶
Overview ¶
Package commworker implements the communication gateway worker (provider webhooks → instance notifications).
Index ¶
Constants ¶
View Source
const (
QueueMessageKindInbound = "comm.inbound"
)
QueueMessageKind* constants define comm-worker SQS message kinds.
View Source
const ServiceName = "comm-worker"
ServiceName is the canonical service identifier for the comm worker.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type InboundAttachment ¶
type InboundNotification ¶
type InboundNotification struct {
Type string `json:"type"`
Channel string `json:"channel"` // email|sms|voice
From InboundParty `json:"from"`
To *InboundParty `json:"to,omitempty"` // required for routing; schema allows omitting
Subject string `json:"subject,omitempty"`
Body string `json:"body"`
BodyMimeType string `json:"bodyMimeType,omitempty"`
ReceivedAt string `json:"receivedAt"`
MessageID string `json:"messageId"`
InReplyTo *string `json:"inReplyTo,omitempty"`
Attachments []InboundAttachment `json:"attachments,omitempty"`
}
InboundNotification matches the communication:inbound notification payload contract.
func (*InboundNotification) Validate ¶
func (n *InboundNotification) Validate() error
type InboundParty ¶
type InboundParty struct {
Address string `json:"address,omitempty"`
Number string `json:"number,omitempty"`
SoulAgentID *string `json:"soulAgentId,omitempty"`
DisplayName string `json:"displayName,omitempty"`
}
func (*InboundParty) Validate ¶
func (p *InboundParty) Validate() error
type QueueMessage ¶
type QueueMessage struct {
Kind string `json:"kind"`
Provider string `json:"provider,omitempty"` // migadu|telnyx|test
Notification InboundNotification `json:"notification"`
}
QueueMessage is the SQS payload processed by comm-worker.
func (*QueueMessage) Validate ¶
func (m *QueueMessage) Validate() error
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server processes inbound communication events from provider webhooks and delivers them to lesser instances.
Click to show internal directories.
Click to hide internal directories.