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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
amsrivas
Helper IV
Helper IV

Power BI calls REST API.

Hi Folks!!

 

Will it be possible to call Power BI Rest API from either from Power BI Desktop or Power BI Services.

 

I.e.can we call below REST API from Power BI Desktop or Power BI Services.

 

Command : 

$url="https://api.powerbi.com/v1.0/myorg/groups"

Invoke-PowerBIRestMethod -Url $url -Method Get

 

Thanks

Amit Srivastava

 

 

Thanks

Amit Srivastava

7 REPLIES 7
v-yingjl
Community Support
Community Support

Hi @amsrivas ,

You can use Web connector to connect to Rest API in power bi desktop.

web.png

 

Here is the a viedo and a document that introduce it in details:

  1. Power BI Tutorial: Power BI REST API no-code options. Import Rest API into Power BI 
  2. Display a time series using the Metrics API 

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-yingjl 

I want to call below REST API from PowerShell

 

$url="https://api.powerbi.com/v1.0/myorg/groups"

Invoke-PowerBIRestMethod -Url $url -Method Get

 

When I putting https://api.powerbi.com/v1.0/myorg/groups on Web Connector, it sat "Access prohibited" but wondering as i can excute this command from PowerShell and able to fetch data.

 

Could you please suggest why i am getting access related issue while connecting from PowerBI.

 

Thanks

Amit

Hi @amsrivas ,

Based on my test, this api will return the specific power bi account workspace information as json format in Powershell if you have connecting to your power bi account by "Connect-PowerBIServiceAccount"

p1.png

We can run this Powershell script to export it as a .csv file:

p2.png

It will create a .csv file at your specified path which includes the above information:

re1.png

 

If you cannot use "Connect-PowerBIServiceAccount" command in powershell, run Powershell as administrator and run this command: "Install-Module -Name MicrosoftPowerBIMgmt"

 

After getting the .csv file, we can connect it in power bi desktop and power bi service to transform data as your needed.

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-yingjl ,

Can understand, this can be achieved via steps you have mentioned however issue in this process is i am not able to automatized the process.

 

I can say, it can automatised via TASK SCHEDULAR or AZURE FUNCTION, but unfortunately, i dont have priviledge to use either of the option.

 

Is there any other way to automatised this process.

 

Thanks

Amit 

Hi @amsrivas ,

As far as I know, if you dont have priviledge to use TASK SCHEDULAR or AZURE FUNCTION, PowerShell is a better way to achieve this while it could not be automatically.

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

Hi @amitchandak 

 

We do not have priviledge to use AZURE as we do not have Azure account/subscription with us.

 

Is there any other way via which we can achieve the requirement without having need of Azure.

 

Please suggest!!

 

Thanks

Amit

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

Top Solution Authors