The envelope
Every call to your endpoint carries one event, always in the same envelope:
Events go out for changes after the account connected. An endpoint only receives the events in its
trigger_events.
Email events
data is { "email": … }: the full email object.
email.new
data.email is complete, body and attachment list included, so most apps don’t need to call the API again. Attachments themselves are downloaded separately.
Folder events
data is { "folder": … }: the folder object.
email.folder.create
Tracking events
data is { tracking_id, label, message_id, email_id, date, ip, user_agent }, plus url for clicks. See Open and click tracking.
Account events
state is the value you passed in the auth intent (POST /api/v1/auth/intent). Use it to find your user.
account.add
account.status.disconnected
disconnected, ask the user for the new password and reconnect the account.
Imported mail from an initial sync sends no email.new; account.initial_sync.completed tells you when to fetch it:
account.initial_sync.completed
Headers
Your endpoint’s own
headers are sent too.