Forum Discussion

adelmonte's avatar
adelmonte
Resolver I
4 years ago
Solved

REST API get dataset data - Datasets - Execute Queries

Hi All,

I need to get data from a dataset online.
How can I use REST API to show data online?

Thanks,

Alex

  • ibarrau's avatar
    ibarrau
    4 years ago

    Well, you can allow Service Principals to use Power Bi Rest API on your PowerBI Admin Portal tenant settings. Then register the app, get the secret, add permissions, add the Service Principal to the workspace. After that you can share a Service Principal to external users. They should be able to use the Rest API and excecute queries

    I hope that helps,

6 Replies

  • Hi. How do you want to connect? I mean, you can open Power Bi Desktop and get data from PowerBi Datasets to build new reports from a current dataset. The admin must have the connection across datasets turned on.

    If you just want to use a language code to get specific thing from a dataset, you can use the rest api. It would be this request:
    https://docs.microsoft.com/en-us/rest/api/power-bi/datasets/execute-queries-in-group

    If you find hard to use the API you can use libraries depending on the language. For example you can import SimplePBI for python or use cmdlets for power bi on PowerShell.

    Be sure to read the Considerations and Limitations on the link above.

    I hope that helps,

    • adelmonte's avatar
      adelmonte
      Resolver I

      Hi ibarrau,
      Thanks for your reply.

      Yes, I would like to use a language code to get specific thing from a dataset.
      Is there any example on how it is done?
      Youtube video or a tutorial online?

      Thanks,

      Alex