question

JarrodCallander-5337 avatar image
1 Vote"
JarrodCallander-5337 asked JarrodCallander-5337 commented

Pull emails from attachments LogicApp

Hi all,

Within LogicApp I am wanting to pull emails that are attached to emails however these attachments don't show (see raw output below). How can I pull .msg files?

{
"headers": {
"Pragma": "no-cache",
"Transfer-Encoding": "chunked",
"Retry-After": "3600",
"Vary": "Accept-Encoding",
"x-ms-request-id": "xxxxxx",
"Strict-Transport-Security": "max-age=31536000; includeSubDomains",
"X-Content-Type-Options": "nosniff",
"X-Frame-Options": "DENY",
"Cache-Control": "no-store, no-cache",
"Location": "xxxxxx",
"Set-Cookie": "xxxxxxt",
"Timing-Allow-Origin": "*",
"x-ms-apihub-cached-response": "true",
"Date": "Fri, 26 Mar 2021 00:51:29 GMT",
"Content-Type": "application/json; charset=utf-8",
"Expires": "-1",
"Content-Length": "1623"
},
"body": {
"id": "xxxxxx",
"hasAttachments": true,
"internetMessageId": "xxxxxx",
"subject": "xxxxxx",
"bodyPreview": "Txxxxxx",
"importance": "normal",
"conversationId": "xxxxxx",
"isRead": false,
"isHtml": false,
"body": "xxxxxx",
"from": "xxxxxx",
"toRecipients": "xxxxxx",
"ccRecipients": null,
"bccRecipients": null,
"replyTo": null,
"attachments": []
}
}

azure-logic-appsmicrosoft-sentinel
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

PramodValavala-MSFT avatar image
1 Vote"
PramodValavala-MSFT answered JarrodCallander-5337 commented

@JarrodCallander-5337 For Office 365 Outlook Connector, there is an Include Attachments option that needs to be set to fetch attachments along with the message.

There is a limitation for Email Messages and Calendar Items documented and requires the following workaround (as-is from the docs for reference)

· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Include attachments was selected. It worked with txt files but not .msg files.

0 Votes 0 ·

Looks like there is a limitation that you may be running into. I've updated my answer with more details.

0 Votes 0 ·

Hi the Get attachments is fine and works but I cant do anything with the attachment. For instance, I want a LogicApp that:

Email comes in > Get Attachment (using HTTP with Azure AD) > Compose an email (using HTTP with Azure AD) > Add Attachment (using HTTP with Azure AD) > Send mail (using HTTP with Azure AD).

I get all the way to the point of Add Attachment and cannot add the attachment using the information I obtained from the Get Attachment. I need to maintain the internet headers of the email attachment so I cant just get the body and create a new one, it has to be the original email. The Add Attahcment documentation describes adding item attachments using creating a new event but not adding an existing email.


0 Votes 0 ·