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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Getting data via REST API using Bearer as Authentication token

Hi I have my rest api which works fine in Postman with GET method and have authorization token as Bearer token and Accept Key as JSON. I would like to know how can I pull the data in Power Bi, Can anyone provide me the syntax or steps where and how can I pull the data in Power Bi, I searched in community but I dont get one with Bearer token.

Thanks in advance.

3 REPLIES 3
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @Anonymous ,

If I understand your scenario correctly that you want to pull data via Rest API with GET Method and have authorization token as Bearer token.

If so, you could refer to the similar threads and blogs below firstly. 

https://community.powerbi.com/t5/Desktop/How-to-authenticate-Web-data-source-REST-API-with-AAD-token...

https://community.powerbi.com/t5/Desktop/Power-BI-Query-to-Generate-Bearer-Token-for-an-OData-API/td...

https://community.powerbi.com/t5/Power-Query/Pull-data-from-a-REST-API-Authentication/td-p/246006

If you still need help, feel free to ask.

Best Regards,

Cherry

 

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Hi @v-piga-msft , 

Thanks for the response. I managed to figure out, the authorization token , we need to just add the text of Authorization type. 

So it works now if I pass the Authorization header as Bearer Token--xxx-xxx-id. 

The above api give me the overall result, however I am still stuck when I try to append my filter value of start and end date in my api as ../.../api/v1/data?startdate= 01-01-2012&enddate=02-02-2017. This runs fine in Postman but in Power Bi i get error as 400 Bad request. Any other way to handle the filters and is there any way to pass the date dynamically??

 

Thanks again.

 

Ankku

 

hi @Anonymous can you advise how did you work on Authorization bearer?

 

I'm having the same problem.image1.JPG

Authentication error.

 

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.