cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Drew1
Level: Powered On

body() action Options

Hi,

 

Is there a link to a list of actions that can be used within body()? I see body('Get_record') and I think I saw body('Get_item') and want to see if there are more. I looked trough the Workflow Definitions but did not see any list of actions. 

2 ACCEPTED SOLUTIONS

Accepted Solutions
Super User
Super User

Re: body() action Options

Hi @Drew1

So, if you take the following example.Capture-213.png

"Get Offfice 365 Messages" is an action. I named it that way, so If I want to access the body of that action i use:

body('Get_Office_365_Messages')

If you had any action, let's say it was a "send email" and youy named it "F00". to get the body of that action you would call:

body('f00')

Does that make sense now?


Please mark with thumbs up if you found this information helpful!
If this addresses your issue, please mark your post as Solved.


Did I answer your question? Mark my post as a solution!

Proud to be a Flownaut!


View solution in original post

ADMCharles
Level: Powered On

Re: body() action Options

@AlanPs1

Yes. Obviously that's only way to do this when there is no provided way to view runtime and environment variables, why do you have to create a step that you hope picks up the previous? There's loads of times when a step should have a previous step's property and name but I have to guess through the mess of incorrect intellisense with no feedback unless I re-run the whole flow.

 

**EDIT**

 

I'll eat my hat, they've just released exactly what I've been banging my head over!

https://flow.microsoft.com/en-us/blog/build-more-powerful-conditions-in-flows-and-more/

 

Take a look at the 'Peek Code' functionality. Allows copying and pasting for use in Dynamic Expressions! Along with the new conditional stuff it's taken a big jump forward in building complex flows.

View solution in original post

6 REPLIES 6
Community Support Team
Community Support Team

Re: body() action Options

Hi @Drew1,

 

The body() function is used to return an action's body output at runtime. In other words, if the output of any action of any connector within Microsoft Flow contains the Body dynamic content, you could use the following formula to return this action's body output:

body('<actionName>')

I have made a test on my side and the screenshot as below:6.JPG

If you add a action within your flow (I assume that you add a "List files in folder" action) and the output of the action contains Body dynamic content as above, you could get the action's body output with following expression formula:

body('List_files_in_folder')

 

More details about body() function, please check the following article:

body() function

 

More details about available connectors in Microsoft Flow, please check the following article:

Available connectors in Microsoft Flow

 

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Drew1
Level: Powered On

Re: body() action Options

@v-xida-msft

Thanks Kris! What I am looking for is a list of the '<actionName>' or a way to discover them within Flow. I have looked at the links you provided in the past and I was not able to locate a list of them, perhaps I am missing where they are located.

ADMCharles
Level: Powered On

Re: body() action Options

This is unbelievably frustrating. How are we supposed to magically know the internal action names? Why mask everything? I can see the bloody 'List Item Column' in Dynamic Data but you won't let me peek at what that is under the hood? How are we supposed to model anything remotely complex?

Super User
Super User

Re: body() action Options

Hi @Drew1

So, if you take the following example.Capture-213.png

"Get Offfice 365 Messages" is an action. I named it that way, so If I want to access the body of that action i use:

body('Get_Office_365_Messages')

If you had any action, let's say it was a "send email" and youy named it "F00". to get the body of that action you would call:

body('f00')

Does that make sense now?


Please mark with thumbs up if you found this information helpful!
If this addresses your issue, please mark your post as Solved.


Did I answer your question? Mark my post as a solution!

Proud to be a Flownaut!


View solution in original post

Super User
Super User

Re: body() action Options

@ADMCharles

I would advise looking at existing templates and see the naming conventions they use and how they access values from previous actions.

The documention linked in this thread also has all the information that is needed to get you going. Just persevere, read on and keep looking at the pre made templates. You'll soon get an idea of how best to implement what you are looking for.


Did I answer your question? Mark my post as a solution!

Proud to be a Flownaut!


ADMCharles
Level: Powered On

Re: body() action Options

@AlanPs1

Yes. Obviously that's only way to do this when there is no provided way to view runtime and environment variables, why do you have to create a step that you hope picks up the previous? There's loads of times when a step should have a previous step's property and name but I have to guess through the mess of incorrect intellisense with no feedback unless I re-run the whole flow.

 

**EDIT**

 

I'll eat my hat, they've just released exactly what I've been banging my head over!

https://flow.microsoft.com/en-us/blog/build-more-powerful-conditions-in-flows-and-more/

 

Take a look at the 'Peek Code' functionality. Allows copying and pasting for use in Dynamic Expressions! Along with the new conditional stuff it's taken a big jump forward in building complex flows.

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 422 members 6,017 guests
Please welcome our newest community members: