Make HTTP request from Flow in Power Automate

One of the most common asks I’ve come across lately is people asking whether or not, we can make external HTTP requests using Flow in Power Automate. Well, yes! Let’s quickly take a look at how you can do that.

Scenario

To keep the example really simple, I have an API that I can use to call to get weather information. (By the way, you’ll find MSN Weather connector in Power Automate too)
So, the API I’m using to test the call is OpenWeatherMap. Their API is really easy to understand for this example.

Note: You can create your account here and you’ll get an API key which you can use.

  1. Now, Let’s say I have the API key and I’m ready to consume their API.
    You can have your Flow start any which way you want, I’m just running it on schedule –
    Select HTTP in the search and select the HTTP trigger
    selectAction
  2. Now, I can fill in the data required to make the HTTP call. In my example, the API is expecting Query String, so I’m passing the values in Queries as needed. It could be different in your case.
    I’m select GET method since we are trying to retrieve data by calling the API
    getSelected

    And then go on to write the rest of the request.
    sampleRequest
    Let’s say, if you’re required to pass headers to a POST request with Body, you can do that as well.

  3. And I’m capturing the response in a variable in Flow to further use it. I’ve chosen to store it in an Object type of variable.
    captureResponseEasy!

Making HTTP Request

Now, let’s test it. I made a sample request and I’ve received the response as below –
I’ll open my response part –
openResponse

Check this, in case you want to also secure the data your receive – Secure Input/Output in Power Automate Run History

And I’ve received the data successfully! Hope this gets you started in making HTTP calls.

12 thoughts on “Make HTTP request from Flow in Power Automate

      • yes I understand but just want to know how did you get this, means is this app registered in azure.

        Like

      • Ok My system’s api is not exposed publicly and they use Oauth authentication so I am not getting how authentication will work, is this something they will provide details or I need to do it.

        Also Can i post request also from Flow to that system based upon my trigger in Dynamics 365

        Like

      • There are various ways you can implement authentication. Most common being the APIKey provided by the one who hosted the app. Which you can store somewhere and pass it in params which appears like I did. I’ll try to write an example soon on that some time soon.

        And Yes, you can use POST verb to do so.

        Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.