Hi,
I woudl like to setup a flow that will send me a push notification when I receive a specific email. I want to use the contents of the email to compose the message for the push notification.
Some details about the email:
What I have do so far:
Email after conversion
Alert Customer Company Name Title Some very important Alert Severity Informational Category UnwantedSoftware Detection Time The date and Time Some Portal Portal Link Generic HTML Link This message from Microsoft is an important part of a program, service, or product that you or your company purchased or participates in. Microsoft respects your privacy. Please read ourPrivacy Statement Generic HTML Link Microsoft Corporation One Microsoft Way Redmond, WA 98052 USA Generic HTML Link
I want to take "Severity", "Informational", "Category", and "UnwantedSoftware" and format it like this:
Severity: Informational Category: UnwantedSoftware
The "Information" and "UnwantedSoftware" part may not always read that way, it could change based on what triggers the email.
Any ideas on how I might do that?
Solved! Go to Solution.
Hi @th_son,
You could add a Compose under the "Html to text" action, and then choose the "the plain text content" dynamic content of the "Html to text" action in the Compose input field,
And then refer to screenshot below to create the flow:
The expression in Informational action the as below:
last(split(first(split(outputs('Compose'),'Category')),'Severity'))
The expression in UnwantedSoftware action the as below:
last(split(first(split(outputs('Compose'),'Detection Time')),'Category'))
The expression in the Compose 4 action the as below:
concat('Severity:',outputs('Informational'),'Category:',outputs('UnwantedSoftware'))
The flow would run successfully as below:
Best regards,
Alice
Hi @th_son,
You could add a Compose under the "Html to text" action, and then choose the "the plain text content" dynamic content of the "Html to text" action in the Compose input field,
And then refer to screenshot below to create the flow:
The expression in Informational action the as below:
last(split(first(split(outputs('Compose'),'Category')),'Severity'))
The expression in UnwantedSoftware action the as below:
last(split(first(split(outputs('Compose'),'Detection Time')),'Category'))
The expression in the Compose 4 action the as below:
concat('Severity:',outputs('Informational'),'Category:',outputs('UnwantedSoftware'))
The flow would run successfully as below:
Best regards,
Alice
Hi Alice,
So I tested this out and it works great. Thank you so much for taking the time to respond.
I am just curious though, how does it actually work?
I am especially confused by the following:
last(split(first(split(outputs('Compose'),'Category')),'Severity'))
I was trying to follow it to understand how it is actually accomplishing its task, but I haven't had any luck.
That may be a loaded question so I don't blame you if you don't respond.
On a side note, when the push notification comes in I get the test all on one line? Is it possible to separate "Severity" and "Category" onto their own lines?
Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.
Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!
User | Count |
---|---|
45 | |
42 | |
37 | |
36 | |
23 |
User | Count |
---|---|
42 | |
39 | |
30 | |
28 | |
28 |