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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
jcaffarel
Regular Visitor

REST API accessToken datasetId field

Hi,

 

I'm trying to set up a Power BI dashboard using NodeJS and ejs with the REST API. (https://stackoverflow.com/questions/47194412/node-js-app-integration-with-power-bi-rest-api)

 

I've managed to successfully login from my code and get the access token from 

 
To my understanding, after that, I need to get another access token from 
https://api.powerbi.com/v1.0/myorg/groups/{groupId}/reports/{reportId}, by means of setting an Authorization header like "Authorization" "Bearer {receivedToken}" and sending a GET request to that URL. The issue is that, after that request, I receive a response with fields such as:
 
@odata.context, id, webUrl, etc. but the only "new" field that I receive is a "datasetId". However, I can't seem to find the description of that field, but I assume is the accessToken that needs to be passed in the "config" object to the powerbi.embed(...., config) function. Am I right?
 
The problem is that on the webpage, a message of "This content is not available" is shown, and checking the console errors, I can see a 403 error for the resource: https://wabi-south-east-asia-redirect.analysis.windows.net/metadata/cluster
 
Is there something I'm missing? Any help would be greatly appreciated.
2 REPLIES 2
Anonymous
Not applicable

HI @jcaffarel,

 

It sounds like you are try to use javascript to dev with power bi rest api, I'd like to suggest you post this to power bi developer forum to get further support.

 

Regards,
Xiaoxin Sheng

Thanks @Anonymous

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.