Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello,
I am trying to create a client that will authenticate to PowerBI via JavaScript. I have attempted to use the ADAL JS but none of the examples actually show how to authenticate to a service... They show how to protect your service using ADAL, which I don't want. Or they show how to redirect you to a sign in page, which I don't want.
Any chance anyone has an example that uses JavaScript so I can grab some data and create my own dashboard.
Pretty please 🙂
Thanks!
Do we have any code sample for this?
Did you find a solution to this?
Thanks
Nope, no answer.
I am posted on the MSDN priority forums on how to do OATH2 "service" authentication (which is what I want to do here), using JavaScript and all I kept getting was pointed at the same sample over and over that isn't a client side authorization example (service), it's a SingularJS WebAPI controller method protection example using ADAL
I am sure this is possible... just not something I have pieced together.
Cheers.
Hi there,
Did you get any further with this... Seems we've also hit the same roadblock; trying to do this entirely in javascript. We know that we can host a Web Service somewhere to act as a proxy and get around the cross-domain challenge, but then we're not going to achieve what we set out to do: a pure client-scripted approach that we can embed anywhere.
Would be great if you could provide an update on where you're at with this...
Jason
Sorry I didn't get anywhere on this.
Doesn't seem possible. If it is, it's such a closely regarded secret no one wants to tell.... Stinks, if you want to create cross domain , cross platform non-aspx pages, how in the world are you supposed to do it, if you can't authenticate.
Hi guys.
@CRMPowerBI when you say that you've constantly pointed to the same example, did you mean this one?
Here is my understanding of what adal.js is, and why you have to create a proxy :
- Adal.js is a lib to authenticate users against a directory which is hosted on azure.
- Authentication is the process of ascertaining that somebody really is who he claims to be.
- OAuth2 implicit grant, which is supported by Adal.js is about obtaining a token (to signing in the user), for accessing our own backend API.
But, there might be a solution if you want to choose the client side route, as stated in this stackoverflow thread.
Hope this helps.
Thank you for that pointer.
I will see how to make this productionizable and hopefully that will be possible.
It would be / will be nice when the BI team creates a sample. It will be harder and harder to expect people to "login" each time to select things to show, especially at an integration into other apps.
Cheers and thank you very much
Did you (or anyone else) find how it could be done.
Without this functionality the REST API is useless
Has anyone managed to get a sample for this?
I am struggling to get this in place
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.