Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I'm dispaying a PowerBI dashboard using the powerbi javascript minified file.
I've registered and configured the app as it should be with correct API Permissions.
Using the following to connect and get auth token:
$getTokenParameters = array (
"requestMethod" => "POST",
"requestURL" => "https://login.microsoftonline.com/" . $tenantID . "/oauth2/token",
"postOptions" => array (
"username" => "email",
"password" => "pw",
"grant_type" => "password",
"client_id" => "XYZ123", // Azure Application_ID
"client_secret" => "XYZ", // Azure Application secret
"resource" => "https://analysis.windows.net/powerbi/api",
"scope" => "openid"
)
);
I should note this HAS worked previously, but now getting a blank screen.
Console log tells me:
<strong>Uncaught Error: No access token was found for element. You must specify an access token directly on the element using attribute 'powerbi-access-token' or specify a global token at: powerbi.accessToken.</strong>
getAccessToken https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
populateConfig https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
t https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
e https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
createEmbedComponent https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
embedNew https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
embedInternal https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
embed https://rawgit.com/Microsoft/PowerBI-JavaScript/master/dist/powerbi.min.js:5
I've even tried adding a "premium per user" license to the profile in question making the connection.
At a loss here. Have search high and low for "No access token was found for element. You must specify an access token directly on the element using attribute 'powerbi-access-token' or specify a global token at: powerbi.accessToken" but no luck so far.
Can anyone assist, please?
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 1 | |
| 1 | |
| 1 |
| User | Count |
|---|---|
| 11 | |
| 7 | |
| 4 | |
| 3 | |
| 3 |