web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Exposing Dataverse Web...
Power Apps
Unanswered

Exposing Dataverse Webapi to external applications

(0) ShareShare
ReportReport
Posted on by 49

Hi all,

 

We have got a requirement where a 3rd party applications (most probably a node js application) wants to connect to our dataverse tables (read/write). Is there any way to call the dataverse webapi through this node js/javascript application?

I know about these articles:

1. Connecting Dataverse API through C# application: https://learn.microsoft.com/en-us/power-apps/developer/data-platform/webapi/quick-start-console-app-csharp
2. Connecting through single page application: https://github.com/MicrosoftDocs/powerapps-docs/blob/main/powerapps-docs/developer/data-platform/oauth-cross-origin-resource-sharing-connect-single-page-application.md

 

But in this case, the javascript application is not a single page application. What is the efficient way to expose the dataverse webapi with proper authentication. I already registered an azure app.

 

 

I have the same question (0)
  • Guido Preite Profile Picture
    1,488 Super User 2024 Season 1 on at

    you don't need to expose the Dataverse Web API as they are already public protected by the authentication.

    If you created an azure app registration you probably have a clientid/clientsecret and you can use them to obtain the bearer token.

    With the bearer token you can execute your Web API (they are REST) with postman, nodejs or any other programming language.

    To build the requests you can use my tool Dataverse REST Builder, regarding the bearer token I wrote some insights in this blog post.

     

  • SShivi Profile Picture
    49 on at

    Hi @GuidoPreite ,

    Thank you for providing the inputs. I will definitely check out the rest builder tool. I am facing issue in getting bearer token. The client do not want to have a login popup, but should be able to get the dataverse data from their application. Any code snippets for the authorization part for such scenario in javascript?

  • Guido Preite Profile Picture
    1,488 Super User 2024 Season 1 on at

    as I wrote before if you have clientid/clientsecret you can get the bearer token, in this scenario there isn't a login popup (like the standard oauth flow)

  • Joeri Stroy Profile Picture
    49 on at

    You also need to keep in mind that you cannot retrieve a bearer token in the browser. Client credential flows are blocked from the browser because it would be a security risk when you would perform these actions in clear text. 

     

    You would need to have a backend service to call azure ad and create the token and pass it back to the browser.

     

    Then you can use the token in your request header to the dynamics web api

  • iwaldman Profile Picture
    159 on at

    @SShivi you may want to check out Scott Durow's https://github.com/scottdurow/dataverse-ify

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard