Azure-Samples / powerbi-powershell

Samples for calling the Power BI REST API via PowerShell
MIT License
258 stars 191 forks source link

Invoke-RestMethod : The remote server returned an error: (401) Unauthorized. #9

Open engelaux opened 6 years ago

engelaux commented 6 years ago

Hi,

I'm trying to rebind my existing report to another workspace and dataset. I've come with the error below.

Invoke-RestMethod : The remote server returned an error: (401) Unauthorized. At line:100 char:1

droptablestudents commented 6 years ago

Having the same issue, did you find a solution?

engelaux commented 6 years ago

Still encountering the unauthorized error. Does the user needs to be a PowerBI admin?

On Tue, 14 Aug 2018 at 6:20 PM droptablestudents notifications@github.com wrote:

Having the same issue, did you find a solution?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Azure-Samples/powerbi-powershell/issues/9#issuecomment-412825202, or mute the thread https://github.com/notifications/unsubscribe-auth/AUKN7C1MwbtHqYtV55nsZrCBh3nlmFMJks5uQqSBgaJpZM4TQ35L .

rstewart89 commented 6 years ago

Also encountering this issue. I'd imagine it's something to do with the app registration maybe?

sgsshankar commented 5 years ago

The Power BI User should be a Admin to use the API. Also the app registration should have the necessary permissions.