Showing results for 
Search instead for 
Did you mean: 
Frequent Visitor

How to connect custom API using OAuth2 in Microsoft Power Automate?

I am a new member of the platform, so help would mean a lot to me. I'm trying to get a bearer token in Power Automate flow using Oauth 2.0. Since I use a custom connector it is not clear to me what should I specify under the URI field? I have attached screenshots (only the data from the second screenshots I use in Postman, and everything works normally). Thank you.







Community Support
Community Support

Hi @petarPan ,


URI is used to enter your API.



Best Regards,
If my post helps, then please consider Accept it as the solution to help others. Thanks.


Hi Wearsky. I don't know how to get the URI, for custom connectors. What should I do?

I have Access Token Url`http://localhost:60001/identity/connect/token` as URL. when I try this, I get the error that URI is invalid. 
Super User
Super User

Not very familiar with OAuth and the like - but your URL is for localhost (your PC) and Flow is running in the cloud, so will not be able to connect to that address.

If you have a custom connector you should be able to add it to your connections and then select that connection in Power Automate and pass in parameters directly rather than having to use HTTP action (a customer connector provides a more user-friendly interface to what you would otherwise use the HTTP action for).

Thank you for response. I will try it. 

Helpful resources

Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (4,347)