Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
xboneu
New Member

Can't get the auth token in c#

Hi,

I have a web app which retrieves my powerbi reports.  For the last few months, I haven't played with it but it used to work fine. Now, when I run the code (C#; VisualStudio) the GetAuthCode function always retuns a False value. All the credential values are the same as before, as it is the code.

 

As far as I know, nothing has changed. I have read something about migrating from ADAL authentication to MSAL, but I'm not sure if this has anything to do with it.

 

Can someone please give me some idea? I don't know what else to try.

Thanks.

Xavier

 

 

1 REPLY 1
Anonymous
Not applicable

Hi @xboneu ,

 

Did you get any error from you code?

I think you may download the offical developer sample , have a test by these codes and compare them with yours.

For reference: 

PowerBI-Developer-Samples

Here is a blog with similar requirements like yours, I hope it could help you.

 

Best Regards,
Rico Zhou

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.