Example Logic App with Azure Function

It’s basic, but I am not that familiar with JSON yet. I saw an example where you use a logic app to retrieve all tweets with anchor #LogicApps. Next you see an Azure function named Returning ComplexResp is called. See the screenprint below:


What we see, is that the Azure function takes input from the Twitter functoid. Json property “text” is set to Tweet text, “by” is set to TweetedBy. Now. To give a better idea. What does the code of ReturningComplexResp look like? Actually it returns in the Body a value for Msg (being a combination of the input parameters TweetedBy and TweetText) and a value FileName.


When we run the Azure function we see we get the following response:


Now, as the last step, we create an API to add a file to the root folder of a DropBox directory. First we create a DropBox API with the Body of the ReturningComplexResp Azure function as both the filename and the content.


Then we switch to code view and see how we can actually set the content to Body.Msg and filename to Body.FileName as returned by the Azure function:


This is the actual JSON I wanted to show. Simple, but powerful. When we switch back to Design View again, we see the File Name and File Content parameters have been changed. This shows that Code View and Designer View are actually aligned. Nice! I’ve had another experience before.