Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - General Discussion
Answered

Getting no pbi entity found error in rest api call

(0) ShareShare
ReportReport
Posted on by 9

I have created a flow to get the bearer token and using that to get the list of users with their roles in the workspace.

 

Using the below via get method in the http call

 

https://api.powerbi.com/v1.0/myorg/groups/{workspaceId}/users

 

I have validated the workspace ID and that is correct not sure why am getting the error as no pbi entity found. 

  • Sabarikarthy Profile Picture
    9 on at
    Re: Getting no pbi entity found error in rest api call

    Thanks for your time and this fixed my issue and now I tried with getgroupasadmin and it worked and hence now I do not need to add the service principal to the individual workspace.

     

    Thanks again and I have marked this as a solution.

  • Verified answer
    v-yueyun-msft Profile Picture
    on at
    Re: Getting no pbi entity found error in rest api call

    Hi , @Sabarikarthy 

    Thanks for your quick response and sorry for my delay response!

    I test it in my side , I can reproduce your problem on my side:

    vyueyunmsft_0-1698895904518.png

    The reason for this error is because of the permission of the token you generated, and I guess you are using the Service Principal to obtain the token. You need to add this application to your workspace as a viewer or other role.

    vyueyunmsft_1-1698896022919.png

     

    And then you can get the return successfully in this https request.

    And this is my api to generate the Token by Service principal:

    vyueyunmsft_2-1698896124418.png

    Url:     https://login.microsoftonline.com/{tenantID}/oauth2/v2.0/token

    scope:https://analysis.windows.net/powerbi/api/.default
    client_id: {Your client_id}
    client_secret: {Your client_secret
    }
    grant_type:client_credentials

     

    And this is the get the workspace users https request:

    vyueyunmsft_3-1698896238804.png

     

     

    Best Regards,

    Yueyun Zhang



  • Sabarikarthy Profile Picture
    9 on at
    Re: Getting no pbi entity found error in rest api call

    Thanks for your response.

     

    When I test by clicking on try it option as you suggested, am getting the desired result but when I try it out in the power automate am getting no pbi entity found.

     

    Mentioned permissions were already added to the api permission sections.

     

     

  • Verified answer
    v-yueyun-msft Profile Picture
    on at
    Re: Getting no pbi entity found error in rest api call

    Hi , @Sabarikarthy 

    According to your description, you are call the Power BI Rest API in Power Automate but you get the error as no pbi entity found.

    First , we need to check if you can run successfully in the official document "Try it ":
    Groups - Get Group Users - REST API (Power BI Power BI REST APIs) | Microsoft Learn

    vyueyunmsft_0-1698828897096.png

     

    If this fails, you need to check if you have the corresponding permissions, or if you have obtained the correct workspaceid. The Workspace ID is here in he url:(If you're still reporting an error here, you may need to contact the appropriate Power BI technical support)

    vyueyunmsft_1-1698829142116.png

     

    If you succeed here, but Power Automate still fails, you need to check that your token is getting it correctly.

    Test method: Use the Postman tool to test your Power BI Rest API and use the token you generated to test whether the API can be successfully called.

    And also you need to check if your token has the Workspace.Read.All or Workspace.ReadWrite.All permission.

     

    And i test it in my side , i works good like this:

    vyueyunmsft_2-1698829377310.png

     

     

    If your call to the Power BI Rest API in Postman also fails, then you may want to consult the relevant Power BI technical support to check if your token permissions are insufficient.

     

    Best Regards,

    Yueyun Zhang

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Automate - General Discussion

#1
rpersad Profile Picture

rpersad 16

#2
David_MA Profile Picture

David_MA 10 Super User 2025 Season 1

#3
Michael E. Gernaey Profile Picture

Michael E. Gernaey 8 Super User 2025 Season 1

Overall leaderboard