web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Reading the text/plain...
Power Automate
Unanswered

Reading the text/plain part from a multipart email body

(0) ShareShare
ReportReport
Posted on by

I want to create a flow to pull just the text/plain information from an autogenerated email. The email body is a multi-part MIME message with a Content-Type: text/html part that is prettily formatted for human eyes in an email client, and a text/plain part that is in JSON and much better-suited to reading by a machine, e.g. something like this:

 

Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit

{
  "Id": "18BE1F64-B23F-7532-82B3-6FE2800154D9",
  "user": {
     "firstname": "Fred",

etc

----
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: quoted-printable

<html><head>

etc

 

I understand that I can use the "Html to text" action to convert this html body to text and parse that, but this will be more fragile and complicated - if anything changes in the layout of the email it may break. Reading the JSON in the text/plain section would be much more resilient to new fields being added etc.

 

I cannot manage to get the "When a new email arrives (v3)" to get anything but the html part of the body, though.

Any ideas or suggestions?

 

Thanks!

Categories:
I have the same question (0)
  • VictorIvanidze Profile Picture
    13,073 on at

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard