Conversations
A conversation layer sits on top of the inbox and outbound tables so a support agent — human or AI — can triage threads instead of individual messages.Threading
Inbound mail is threaded by RFC headers (Message-ID, In-Reply-To, References) first,
falling back to subject plus participants within CONVERSATION_MATCH_WINDOW_DAYS (default 30)
when headers are missing.
Triage state
Each conversation carries:
A new inbound message to a
closed or snoozed conversation reopens it to open.
Received attachment bytes are retained up to ATTACHMENT_MAX_BYTES (default 10 MB) and are
individually fetchable. Message subject and body are indexed in FTS5 for full-text search.
REST API
List filters include conversation age and unanswered state.
MCP tools
A
triage_inbox prompt is also served — see MCP server.
Mailboxes
Register addresses on a managed domain, e.g.support@emails.stateset.com. Incoming IMAP mail
whose To: or Cc: matches a registered address is routed to that mailbox
(inbox.mailbox_id).
When MAIL_DOMAIN is set, the send endpoint requires the from address on that domain to
be a registered mailbox.
Managed-domain onboarding is driven by these settings:
Webhooks
Conversation activity is carried on the standard webhook stream.inbox.received events
include the conversation, mailbox, domain, and tenant, plus attachment metadata; bounce events
carry the recipient. Subscriptions can be scoped to a tenant.
See Configuration for subscription management.