cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
New Member

Devscope PowerBIPS Modules

Hi,

 

I am using the Devscope PowerBIPS Modules to send data directly to a PowerBI dataset from a PowerShell script.

 

I am having a problem with authentication. When first run, the acquisition of an authentication token requires you click accept to allow the Devscope app permission to access the dataset. Provided the PowerShell window isn't closed, you can acquire a new token without issue.

 

However, if the PowerShell window is closed, you have to authorise the app again which can only be done GUI driven which makes it useless for automated scripting.

 

I have read that this is to do with the user account used to authenticate to PowerBI.The Devscope modules can work with a custom Azure App and in this case, you can create a user in Azure AD with the necessary permission.

 

I am using it with regular Office 365 and so there is no access to Azure AD apart from signing into the Portal and assigning PowerBI licenses. This has been done.

 

Has anyone been able to successfully use the Get-PBIAuthToken cmdlet specifying both username and password parameters without the need to first run Get-PBIAuthToken and use the GUI to enter credentials and click Accept to authorise the app?

 

The DevScope module is very powerful by allowing you to push data directly into PowerBI but is not usedul if you have to manually authorise each PowerShell session first.

1 ACCEPTED SOLUTION
New Member

Managed to figure this out.

 

You need to have your Office 365 Directory linked to Azure AD. When this is done, you can use the Client ID from the Native Client App along with a username and password for a user in your Office 365 tenancy that is licensed for PowerBI.

 

I am now able to fully automate uploading data to PowerBI as acquiring the authentication token no longer requires initial manual authorisation.

 

Reference article for Azure App configuration is here: https://msdn.microsoft.com/en-us/library/dn877542.aspx

 

I didn't realise but one of my colleagues had already exposed the 365 directory to Azure AD. Don't know how it was done though!

View solution in original post

3 REPLIES 3
New Member

Managed to figure this out.

 

You need to have your Office 365 Directory linked to Azure AD. When this is done, you can use the Client ID from the Native Client App along with a username and password for a user in your Office 365 tenancy that is licensed for PowerBI.

 

I am now able to fully automate uploading data to PowerBI as acquiring the authentication token no longer requires initial manual authorisation.

 

Reference article for Azure App configuration is here: https://msdn.microsoft.com/en-us/library/dn877542.aspx

 

I didn't realise but one of my colleagues had already exposed the 365 directory to Azure AD. Don't know how it was done though!

View solution in original post

That link is dead. And it tells us to move on to another link that is dead. And then  recommends a bunch  of other top-level links.

Anyone know where we should look these days?

That link is dead. And it tells us to move on to another link that is dead. And then  recommends a bunch  of other top-level links.

Anyone know where we should look these days?

Helpful resources

Announcements
secondImage

Congratulations!

We are excited to announce the Power BI Super Users!

Wave Release 2

Check out the updates in Power BI.

Overview of Power BI 2020 release wave 2!

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

secondImage

The largest Power BI virtual conference

100+ sessions, 100+ speakers, Product managers, MVPs, and experts. All about Power BI. Attend online or watch the recordings.

Top Solution Authors