Microsoft 365 Get

Microsoft 365 Get

Certified

Get Outlook email message

Retrieves one email by message ID with optional attachments. Requires Microsoft Graph permission Mail.Read (application).

yaml
type: io.kestra.plugin.microsoft365.outlook.Get

Get a specific email message

yaml
id: get_outlook_message
namespace: company.team

tasks:
  - id: get_message
    type: io.kestra.plugin.microsoft365.outlook.Get
    tenantId: "{{ secret('AZURE_TENANT_ID') }}"
    clientId: "{{ secret('AZURE_CLIENT_ID') }}"
    clientSecret: "{{ secret('AZURE_CLIENT_SECRET') }}"
    userPrincipalName: "user@example.com"
    messageId: "AAMkAGVmMDEzMTM4LTZmYWUtNDdkNC1hMDZiLTU1OGY5OTZhYmY4OABGAAAAAAAiQ8W967B7TKBjgx9rVEURBwAiIsqMbYjsT5e"

Get message from specific user mailbox

yaml
id: get_user_message
namespace: company.team

tasks:
  - id: get_message
    type: io.kestra.plugin.microsoft365.outlook.Get
    tenantId: "{{ secret('AZURE_TENANT_ID') }}"
    clientId: "{{ secret('AZURE_CLIENT_ID') }}"
    clientSecret: "{{ secret('AZURE_CLIENT_SECRET') }}"
    userPrincipalName: "user@example.com"
    userEmail: "specific.user@example.com"
    messageId: "{{ vars.messageId }}"
    includeAttachments: true
Properties

Azure client ID

Application (client) ID of the Graph app registration

Azure client secret

Client secret for the app registration; required for client-credentials flow

Message ID

Graph message ID to retrieve

Azure tenant ID

Entra tenant (directory) ID used for Graph auth

Assets this task consumes as inputs or produces as outputs, for lineage tracking and the asset graph (Enterprise Edition). A flow declaring this property on a task is rejected in the open-source edition.

Definitions
assetFailureBehaviorstring
Possible Values
IGNOREFAILWARN

Asset failure behavior

Behavior applied to the task state when a declared asset fails to render, emit, or be persisted (e.g. a lock conflict): FAIL escalates it to FAILED, WARN (default) warns it if it would otherwise succeed, IGNORE leaves the state untouched.

enableAutobooleanstring

Whether to auto-register assets referenced dynamically at runtime that are not statically declared in inputs or outputs.

inputsarray

The assets consumed as inputs.

id*string
Min length1
typestring
outputs

The assets produced as outputs.

id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*string
Min length1

Custom asset type

descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
Defaultfalse

Include attachments

If true, returns attachment metadata; content is not downloaded here

Defaulthttps://graph.microsoft.com/.default

Scopes

Space-separated Graph scopes; default uses .default application permissions

User email

Mailbox to read; defaults to app mailbox when omitted

User principal name

Mailbox UPN/email to act on; defaults to app context when omitted

Message

Full message detail including recipients and attachments

Definitions
attachmentsarray
contentTypestring
idstring
namestring
sizeinteger
uristring
bccRecipientsarray
SubTypestring
bodyContentstring
bodyPreviewstring
bodyTypestring
ccRecipientsarray
SubTypestring
conversationIdstring
conversationIndexstring
fromMailstring
hasAttachmentsboolean
idstring
importancestring
internetMessageIdstring
isReadboolean
receivedDateTimestring
Formatdate-time
senderMailstring
sentDateTimestring
Formatdate-time
subjectstring
toRecipientsarray
SubTypestring