FromEmail@1
The FromEmail@1 node polls a mailbox over IMAP and triggers the pipeline for new
messages. Use it for any IMAP-capable mailbox (Gmail, self-hosted, Exchange with IMAP
enabled, …). For Microsoft 365 mailboxes via Microsoft Graph — no stored password, an
Azure app registration instead, and folder-as-queue semantics — use
FromMicrosoftGraphEmail@1 instead.
Adapter Prerequisites
- Mesh Adapter
- An
System.Communication/EMailReceiverConfigurationentity (IMAP host / credentials), linked to the pipeline via aSystem.Communication/Usesassociation.
Server Configuration (EMailReceiverConfiguration)
Create the IMAP settings as a System.Communication/EMailReceiverConfiguration entity
and reference it by WellKnownName from the node's serverConfiguration. Store the
password outside of source control.
- rtId: <config-rtId>
ckTypeId: System.Communication/EMailReceiverConfiguration
rtWellKnownName: InvoiceMailbox
attributes:
- id: System.Communication/Host
value: "imap.example.com"
- id: System.Communication/Port
value: 993
- id: System.Communication/Username
value: "accounting@example.com"
- id: System.Communication/Password
value: "<password>"
- id: System.Communication/IsSslEnabled
value: true
- id: System.Communication/Folder # optional, defaults to INBOX
value: "INBOX"
| Attribute | Required | Default | Description |
|---|---|---|---|
Host | yes | — | IMAP server host name. |
Port | yes | — | IMAP port (typically 993 for SSL, 143 for STARTTLS). |
Username | yes | — | Login user. |
Password | yes | — | Login password. |
IsSslEnabled | yes | — | true → implicit SSL on connect (SslOnConnect); false → StartTlsWhenAvailable. |
Folder | no | INBOX | Mailbox folder to poll. |
The serverConfiguration must be linked to the pipeline through a
System.Communication/Uses association — the GlobalConfiguration is built only from
Uses associations, the name alone is not resolved:
# on the Pipeline entity
associations:
- roleId: System.Communication/Uses
targetRtId: <config-rtId>
targetCkTypeId: System.Communication/EMailReceiverConfiguration
Node Configuration
| Field | Required | Default | Description |
|---|---|---|---|
serverConfiguration | yes | — | WellKnownName of the EMailReceiverConfiguration entity. |
pollingIntervalSeconds | no | 60 | Seconds between polling cycles. |
onlyUnread | no | true | Only process unread (unseen) messages. When false, all messages in the folder are searched. |
markAsRead | no | true | Mark a message as read after it has been processed. |
deleteAfterProcessing | no | false | Delete a message after it has been processed. |
senderFilter | no | (none) | Only process messages whose sender address contains this string. |
subjectFilter | no | (none) | Only process messages whose subject contains this string. |
The node de-duplicates within a single adapter run by message UID. To avoid
reprocessing across restarts, keep onlyUnread: true with markAsRead: true, or set
deleteAfterProcessing: true when the mailbox folder is a dedicated work queue.
Output
The node emits an array of messages at $.Emails[], the same unified shape produced by
FromMicrosoftGraphEmail@1 / FromTeamsBot@1
(see Microsoft 365 E-Mail — unified message shape):
$.Emails[0].Subject
$.Emails[0].From — sender (display name + address)
$.Emails[0].FromAddress — sender address only
$.Emails[0].To
$.Emails[0].Date
$.Emails[0].Body — also HtmlBody / TextBody
$.Emails[0].MessageId
$.Emails[0].Attachments[0].FileName
$.Emails[0].Attachments[0].ContentType
$.Emails[0].Attachments[0].Length
$.Emails[0].Attachments[0].Data — base64 file content
Usage Example
Poll an inbox for unread invoice mails and process each attachment:
triggers:
- type: FromEmail@1
serverConfiguration: InvoiceMailbox
pollingIntervalSeconds: 60
onlyUnread: true
markAsRead: true
senderFilter: "@supplier.com"
transformations:
- type: ForEach@1
iterationPath: $.Emails
targetPath: $.emailResults
targetValueKind: Simple
targetValueWriteMode: Overwrite
transformations:
- type: ForEach@1
iterationPath: $.key.Attachments
targetPath: $.attachmentResults
targetValueKind: Simple
targetValueWriteMode: Overwrite
transformations:
- type: If@1
path: $.key.ContentType
operator: Equals
value: "application/pdf"
valueType: String
transformations:
# ... store $.key.Data, run OCR / AI, create entities ...