Power BI REST API: How to get authentication token with PowerShell Cmdlets

You may also like...

2 Responses

  1. Beau Raines says:

    Thanks for this information. Your post seems to be the only place on the internet, MS docs included where this can be found.

    I noted that if you change


    Login-PowerBI -Credential $credential

    to


    Login-PowerBI

    It will trigger the device login method where you have to enter a code online. While interactive, it does work with MFA.

    • Alex says:

      Yes, the change you mention might trigger the manual login (could be MFA), but that won’t work for fully automated scripts. If it matches your needs, thats great 🙂
      Cheers! ☺️

Leave a Reply