Mail Item Lifecycle

How Mail Items move throughout the system.

Before a scan

When Stable receives a mail item, these fields have values:

  • imageUrl (top level): Envelope Scan
  • from: the sender, transcribed from the envelope
  • recipients: listed recipients (see Recipients​)
  • clearAt: the storage deadline (see Storage and Shredding)
  • isReturnedToSender
  • the tags and teams on the item, if they have been applied by a routing rule

Event ordering

Event ordering is not guaranteed

Stable does not guarantee the order of events. See Webhooks for guidance.

Events generally occur in this order:

  1. mailItem.created
  2. mailItem.scan.processing
  3. mailItem.scan.completed
  4. mailItem.scan.ocrCompleted
  5. check.created (if checks detected)
  6. mailItem.summary.created

This order is typical and reflects the physical and post-processing steps a mail item undergoes. However, you should be prepared for events that arrive out of order.

Physical actions

A mail item is subject to the following "real world" actions:

Items that are shipped or shredded are considered "terminal" and cannot have further physical actions taken on them. Learn more in Mail Items to see how to check these.

Digital actions

A mail item is subject to the following digital actions:

  • Archive: the item is reversibly marked as archived.
  • Read: the item is reversibly marked as "read." This is currently only possible via the dashboard but may be used to identify items not seen by a user.
  • Assign tags: one or many text tags are applied to an item for organizational purposes.
  • Assign teams: one or many teams are applied to an item for organizational purposes. This affects the mail item's permissions.

Returned mail

isReturnedToSender means that the item looks like your own mail that came back to you. It does not mean that Stable returned the item.



Did this page help you?