Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
8 months ago
Solved

Power Bi Api issue

Hi Community ,

I am facing some issue in power bi Api, if i am using device login method the data is extracted , but using without it with client secret, client id, tenant id  , i am able to extract workspaces, reports but not 

===== Dataset Data Sources =====
Status: 403
{
  "Message": "API is not accessible for application"
}

 

===== Dataset Refresh History =====
Status: 403
{
  "Message": "API is not accessible for application"
}

 

===== Dataset Refresh Schedule =====
Status: 403
{
  "Message": "API is not accessible for application"
}


 

6 Replies

  • Hi Anonymous, can you explain more about what you are doing and trying to accomplish with API. Are you trying to connect to the API from within Fabric using a notebook or from an Azure resource of from some other application? Share the particular API that you are using. Then we have more information to give you a proper answer to your problem.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Using power bi api i am fetching  workspace, reports , datasources, refresh schedule, refresh history data.

  • Check the requested permissions in your app registration. Sounds like the scope is insufficient.

  • v-hjannapu's avatar
    v-hjannapu
    Community Support

    Hi Anonymous,
    Thank you for posting your query in Microsoft Fabric Community Forum. Also, thanks to nielsvdc  , lbendlin    for those inputs on this thread. 

    This usually happens when using client ID and secret. Workspace and report APIs work, but dataset APIs need some extra permissions. Please check if service principal access is enabled in Power BI Admin Portal and that your app has dataset permissions with admin consent. Also make sure the service principal is added to the workspace and you are calling the group-level dataset APIs.

    After this, the dataset refresh and datasource APIs should work.

    please go through with the below document hope it may resolve your Issue

    Embed Power BI content in an embedded analytics application with service principal and an application secret - Power BI | Microsoft Learn
    Enable service principal authentication for admin APIs - Microsoft Fabric | Microsoft Learn

    Hope the above provided information help you resolve the issue, if you have any further concerns or queries, please feel free to reach out to us.

    Regards,
    community Support Team.

    • v-hjannapu's avatar
      v-hjannapu
      Community Support

      Hi Anonymous,
      I hope the information provided above assists you in resolving the issue. If you have any additional questions or concerns, please do not hesitate to contact us. We are here to support you and will be happy to help with any further assistance you may need.

      Regards,
      Community Support Team.

      • v-hjannapu's avatar
        v-hjannapu
        Community Support

        Hi Anonymous,
        I hope the above details help you fix the issue. If you still have any questions or need more help, feel free to reach out. We are always here to support you.


        Regards,
        Community Support Team.