cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
New Member

Connect to custom secured WebAPI in Azure without custom connector

Dear All,

Can someone help and tell me if its possible to call custom secured WebAPI in Azure from MS Flow without creating custom connector ??? I tried to "reproduce" the steps which SharePoint Framework does under the hood when it calls my WebAPI from normal SharePoint page (and it works there) but I'm unable to do the same from my Flow.

Below you can find two screenshots - basically I'm trying to get a bearer token from microsoftonline.com and pass it to my WebAPI. I tried a couple of tips and tricks but it still throws "Unauthenticated" errors.

 

flow1.pngflow3.png

3 REPLIES 3
Community Support
Community Support

Hi @ecmteler,

 

About Web API, you can have a reference about this document:

flow/web-api

And you can also refer to this article that refreshes the access token:

#refreshing-the-access-tokens

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Hi @v-litu-msft ,

Thank you for your message, however thats not what I'm trying to do - I dont want to call MS FLow WebAPI but my own custom WebAPI hosted in Azure. Its using JWTBearer authentication.

Hi @ecmteler 

 

Since you are getting unauthorized access, this means the token creating request is not working properly. Based on my experience with Azure protected API, I would recommend you to create a custom connector and make a call through it, this works perfectly fine if the application registrations are done properly. For more details, you can refer: https://docs.microsoft.com/en-us/connectors/custom-connectors/create-web-api-connector

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Users online (7,124)