403 error thrown by power bi report server when trying to get list of data sets

+1 vote
Oct 29, 2018 in Power BI by saranya
• 130 points
5,026 views
Hey @saranya, what exactly did the error log say?

i am sending a GET request to:

https://api.powerbi.com/v1.0/myorg/datasets
with headers:
Content-Type: application/json
authorization : Bearerxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Response headers:
server:Microsoft-HTTPAPI/2.0
strict-transport-security:max-age=31536000; includeSubDomains
x-frame-options:denyx-content-type-options:nosniff
requestid:174e9027-8d2f-4f98-8085-d2f9f75087a5date:Mon, 29 Oct 2018 07:21:31 GMT
Request headers:
content-type:application/json

Why am i not able to access datasets ? am i missing any settings?

Hey @saranya, Try removing the header and footer, sometimes these interfere with column space and create confusion. A lot of people have this same error due to lot of different reasons. Its basically a data integration error.

i am sending request through RESTAPI, url would be: 

https://api.powerbi.com/v1.0/myorg/datasets
headers: 
Authorization Bearer xxxxxxxxxxxxxxxx
content-type:application/json
accept: application/json

still i am getting 403 error. Are there any settings to be changed in power bi report server?

Hi @saranya, I've found this helpful. Even i've had a similar problem, I had followed the guidelines from this and applied it accordingly for my case. Hope it helps. 

2 answers to this question.

+1 vote
Hey @saranya, Try removing the header and footer, sometimes these interfere with column space and create confusion. A lot of people have this same error due to lot of different reasons. Its basically a data integration error.
answered Oct 29, 2018 by Kalgi
• 52,350 points

do you mean remove (content-type:application/json) how can i pass access token?

You can do something like this:

1.  Call login API to get the access token.

2.  Use access token call other operation api.

Example:

    WebResponse = Web.Contents(WebServiceURI,
        [Content = Text.ToBinary(WebServiceContent),
         Headers = [Authorization="Bearer " & AccessToken,
                    #"Content-Type"="application/json",
                    Accept="application/json"],
         Timeout = WebTimeout])

In addition, API can allow "username", "password", "token" as the parameters

0 votes
403 is usually server rejection
That is it acknowledges the request but doesn't process.
The problem seems to be that you don't have permission to the database you're trying to access
The problem could be in 2 places, first is while the data was brought on the power bi cloud or if this is an azure correction used then you just do not have the privileges.
answered Oct 31, 2018 by Maverick
• 10,840 points

I have granted permissions for the application i have registered

Related Questions In Power BI

0 votes
1 answer

Why do I get a "Cannot resolve ambiguity" error when trying to join multiple tables with bi-directional filters?

The “Cannot resolve ambiguity” message in Power ...READ MORE

answered Nov 6 in Power BI by pooja
• 4,690 points
36 views
0 votes
1 answer

Error:connecting to Azure SSAS server in Power-BI through Import mode

If I understand correctly, you're connecting to ...READ MORE

answered Nov 9, 2018 in Power BI by Upasana
• 8,620 points
2,663 views
0 votes
2 answers

Can I get rid of the grey border on the report visuals with power bi embedded?

It's just a simple css code to ...READ MORE

answered Apr 19, 2020 in Power BI by Prateek Mehta
5,436 views
0 votes
1 answer

By default, which level of filter behaves as same as a slicer in a report in Power BI desktop?

Hey, There are several types of filters in ...READ MORE

answered Jan 31, 2020 in Power BI by Rakesh
5,950 views
0 votes
1 answer

How to create a new dashboard by pinning visualizations from a report in Power BI?

Hey, I can show some steps wise steps ...READ MORE

answered Feb 6, 2020 in Power BI by Gitika
• 65,770 points
1,069 views
0 votes
1 answer

How to create a new slicer to filter data by district manager in Power BI?

Follow the steps Open power bi  desktop nd ...READ MORE

answered Oct 10, 2023 in Power BI by Monika kale
952 views
0 votes
1 answer

Error Error on Data load when open report in server "An error has occurred"

The problem you can solve by edit this ...READ MORE

answered Nov 16, 2020 in Power BI by Gitika
• 65,770 points
1,545 views
0 votes
1 answer

How to connect webpage data by using Power BI Desktop?

Web connections are only established using basic ...READ MORE

answered Nov 18, 2020 in Power BI by Gitika
• 65,770 points
992 views
+2 votes
2 answers

Power BI service throwing 403 error when using token to embed Power BI report

To add to @Kalgi's answer, Also make ...READ MORE

answered Oct 3, 2018 in Power BI by Nilesh
• 7,060 points
6,165 views
0 votes
3 answers

How do I get token using javascript API while trying to embed graphs using Power BI

Use ADAL.js that will give you an ...READ MORE

answered Jun 22, 2019 in Power BI by anonymous
4,562 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP