Power BI PowerShell Cmdlets
-
Power BI PowerShell Cmdlets
Posted by DSC Communities on May 21, 2019 at 7:20 pm-
Ben Oastler
MemberMay 21, 2019 at 7:20 PM
Hi everyone,Can you assign Premium Capacity to a Workspace using PowerShell?
Can you create App Workspaces using PowerShell?
Can you assign a PowerBI Pro licence via PowerShell?
Can you check if a user has a PowerBI Pro licence with PowerShell?
Can you check to see if a Workspace has premium Capacity with PowerShell?thanks
Ben——————————
Ben Oastler
Practise Director – North America
Bizdata
+1 (917) 724 1666
ben.oastler@bizdata.com.au
—————————— -
Tuhin Tapadar
MemberMay 22, 2019 at 3:38 AM
Hi Ben,Although, I am not a champion on PowerShell on Power BI but these two websites definitely help you with your queries.Ā Ā
Working with PowerShell in Power BI | Microsoft Power BI Blog | Microsoft Power BI
Microsoft remove preview Working with PowerShell in Power BI | Microsoft Power BI Blog | Microsoft Power BI If you are following the Power BI blog on a regular basis, you probably have noticed the Power BI APIs and cmdlets announcement for administrators, which introduced a set of APIs and cmdlets to work… View this on Microsoft > https://powerbi.microsoft.com/en-us/blog/working-with-powershell-in-power-bi/Ā
https://insightsquest.com/2018/12/24/power-bi-workspace-scripts/Ā
Regards,
——————————
Tuhin Tapadar
Data Analyst
Dublin
894164048
——————————
——————————————- -
Lutz Bendlin
MemberMay 22, 2019 at 7:20 AM
Full reference is here
https://docs.microsoft.com/en-us/powershell/power-bi/overview?view=powerbi-ps——————————
Lutz
——————————
——————————————- -
Mike Anderson
MemberMay 22, 2019 at 9:20 AM
In short, I believe the answers are as follows:Can you assign Premium Capacity to a Workspace using PowerShell?
Yes, I believe this can be done based on the API –Ā https://docs.microsoft.com/en-us/rest/api/power-bi/capacities/groups_assigntocapacityCan you create App Workspaces using PowerShell?
No, I see no REST API that can do this, only retrieve existing apps – Apps (Power BI Power BI REST APIs)Can you assign a PowerBI Pro licence via PowerShell?
Yes, this should be possible but you’d have to call into Office 365 API’s I’m assuming, something like this?Ā Ā Using Power BI Audit Log and PowerShell to assign Power BI Pro licenses | Microsoft Power BI Blog | Microsoft Power BICan you check if a user has a PowerBI Pro licence with PowerShell?
I believe the above might be able to accomplish this.Can you check to see if a Workspace has premium Capacity with PowerShell?
Yes, I believe based on this API –Ā Groups – Get Groups (Power BI Power BI REST APIs)
Ā
You could then use the PowerShell CMDLETS the previous users mentioned to call the Power BI REST API’s with the Invoke-PowerBIRestMethod –Ā Invoke-PowerBIRestMethod (MicrosoftPowerBIMgmt.Profile).It may be the PS CMDLETS can do this, at quick glance I didn’t see the option for capacity assignment but might have missed it.
——————————
Cheers,
Mike Anderson——————————
——————————————- -
Ben Oastler
MemberMay 22, 2019 at 4:16 PM
Thanks Mike, that’s perfect!——————————
Ben Oastler
Practise Director – North America
Bizdata
eastwood
+1 (917) 724 1666
ben.oastler@bizdata.com.au
——————————
——————————————-
DSC Communities replied 6 years, 3 months ago 1 Member · 0 Replies -
-
0 Replies
Sorry, there were no replies found.
The discussion ‘Power BI PowerShell Cmdlets’ is closed to new replies.