Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Embedding a PowerBI Report in a Confluence page

Aaron Williams March 27, 2024

Hello, having a tricky problem.

We use a connector for JSM to PowerBI to create a report, and we have the report set up with Embed Capacity and token authentication.

Reviewing PowerBI embed documentation:

There is an option to embed a report where our client can view the report without personally authenticating. We've generated a token and amended the script found here to match our details:

Since the script is JavaScript, I found this Confluence KB article: How to use JavaScript in Confluence | Confluence | Atlassian Documentation

But now I'm a bit stuck - I'm not really a code guy, and this is beyond my technical abilities.

As I read it, I should insert the code directly in a script block like:

<iframe title="Title Here" width="1140" height="541.25" src="" frameborder="0" allowFullScreen="true">

<script type="text/javascript">
let models = window['powerbi-client'].models;
let embedConfiguration = {
type: 'report',
id: 'id here',
embedUrl: '',
tokenType: models.TokenType.Embed,
accessToken: 'token here' };
var $dashboardContainer = $('#embedContainer');
var dashboard = powerbi.embed($dashboardContainer.get(0), embedConfiguration);

I'm not sure where I'm going wrong here, I literally don't have the first clue - does the iframe block need to be inside the script, does the script need to be inside the iframe block, do I need to include something with the JQuery stuff, I just don't know - any advice appreciated.

This is on Confluence Server so I don't have the option of buying an add-on to solve this, nor do I have the option of buying an add-on to replace PowerBI.

0 answers

Suggest an answer

Log in or Sign up to answer
AUG Leaders

Atlassian Community Events