Hi,
I am a relative beginner to power automate and I am facing some hurdles with my flow.
So, want to parse through this particular nested json snippet in my Compose field (no sensitive information), and
[
{
"project": "project1",
"BusinessOwner":
{
"Email": ["abc@gmail.com"]
},
"TeamMember":
{
"Email": ["def@gmail.com"]
}
},
{
"project": "project2",
"BusinessOwner":
{
"Email": ["efg@gmail.com"]
},
"TeamMember":
{
"Email":
["ghi@gmail.com",
"ijk@gmail.com"]
}
}
]
Basically, this is my current idea of how the flow will go -
I want to parse through the "BusinessOwner" and "TeamMember" fields, then take in the variable length array, and use these email addresses in the Send an Email action to send emails based on "project" value. I also need to have attachment in the mail which is stored in a SharePoint List and I want to map it to "project" value dynamically. "BusinessOwner" email addresses go in the "To" section of the mail and "TeamMember" email addresses go in the "CC" section of the mail. Both "Email" fields in "BusinessOwner" and "TeamMember" entries are of variable length.
The SharePoint List has only one column "project" and the values are:
project1
project2
and both "project" values have a single distinct attachment each.
Based on the "project" value the email recipients and attachment from the SharePoint List is to be added.
Could someone please help me out? I have tried multiple attempts to achieve this, but to no avail.
If any further information is required, then please let me know!
Thanks!