Skip to content
Art2link ESB v2.02 LTS HomeDocumentationBlogContact
Core concepts/Adapters/O365 Mail adapter
Adapter

O365 Mail adapter

A send-side adapter that dispatches email through Microsoft 365 / Exchange Online. The response is an acknowledgement only — mail has no synchronous payload to return.

ADAPTER · SEND O365 Mail Sends mail via Microsoft 365 / Exchange Online — acknowledgement response only Shipping DIRECTION ↑ Send MODES One-way · Two-way AUTHENTICATION O365 Authentication PORT Send port RESPONSE Ack only

The O365 Mail adapter composes an outbound email from the message it picks up off the bus and dispatches it through Microsoft Graph. The recipient list, subject, body, and any attachments are templated against the message and the Application's variables; the adapter handles the call to Graph and reports success or failure.

The send port carries the email's structure. Every visible field is templatable, so the same port can issue context-specific mail when fed by different upstream flows.

COMPOSE FROM {{Variable.notification_sender}} TO {{xpath(/Notification/Recipient)}}, ops@example.com CC (optional) BCC (optional) SUBJECT Order #{{xpath(/Order/Id)}} confirmed BODY <p>Hello {{xpath(/Order/CustomerName)}},</p> <p>Your order has been confirmed for {{xpath(/Order/Total)}}.</p> CONTENT TYPE: HTML · or PLAIN TEXT ATTACH file({{Variable.invoice_path}}), inline(image/png, {{xpath(/Order/Logo)}})

The Microsoft Graph mail-send call returns success or failure but does not carry a meaningful payload back — once the service has accepted the message, the work is done. In two-way mode the response published to the bus is therefore an empty acknowledgement: the in-flight envelope, no body, with a status code on a promoted property. That is enough to let any downstream port subscribed to the response continue its work.

Bus O365 MAIL SENDER Graph mail.send call MICROSOFT 365 Exchange Online ack · status only · empty body One-way: no publish Two-way: ack message republished Use two-way when a downstream port needs to know the send completed; otherwise leave one-way for less bus traffic.

The O365 Mail adapter pairs with an O365 Authentication. Authentication is OAuth 2.0 client credentials against the customer's Azure AD tenant, with the application granted the Mail.Send (or Mail.Send.Shared) permission on Microsoft Graph. The Authentication object carries the tenant id, application (client) id, and the client secret; the adapter handles token acquisition and refresh transparently.

i
Sending as a specific mailbox (rather than the configured app identity) requires the application to have Mail.Send.Shared and the target mailbox to delegate send access. The From field can then template the sending mailbox.

Placeholder field set — verify against the running product.

From — required; templatable email address. Must be a mailbox the Authentication's app identity is permitted to send as.
To — required; one or more comma-separated addresses. Templatable.
Cc — optional; same shape as To.
Bcc — optional; same shape as To.
Subject — required; templatable string.
Body — required; templatable. May reference variables, message properties, and xPath expressions.
Content Type — required; HTML or Plain text.
Attachments — optional; list of attachment specifications. Each row carries source (file path / inline payload / xPath of base64 content) and metadata (filename, content type, inline cid).
Save to Sent Items — optional toggle; default on. When off, the sent message does not appear in the sender's Sent Items folder.
Importance — optional; Low / Normal / High. Defaults to Normal.
Authentication — required; picker filtered to O365 Authentication objects in the same Application.

That is the O365 Mail adapter

Mail dispatch via Microsoft Graph. Acknowledgement-only response; two-way publishes an empty ack message back to the bus to let downstream work continue. Back to Adapters.