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.
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.
- 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
- 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
And then go on to write the rest of the request.
Let’s say, if you’re required to pass headers to a POST request with Body, you can do that as well.
- 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.
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 –
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.