Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
We are currently working on developing an reporting application in react. For that we have added service layer to get accesstoken and embed token.
My Question is do we need to trigger "Get Reports In Group" api endpoint to get the embed url or the format will always be the same and only the report and group id can be changed.
I see embed url format is https://app.powerbi.com/reportEmbed?reportId=<<REPORTID>>&groupId=<<GROUPID>>.
Need an confirmation, so that additional api call be avoided and as part of the token api we will get the reportid, embedtoken and internally formed embedUrl.
Thanks in advance
Srinivasan
@schandr You have to call the API for getting the embed URL.
Please refer to this link.https://docs.microsoft.com/en-us/rest/api/power-bi/reports/getreportingroup
Then click Try it and test this API call.
It will return something similar to below. The embed URL contains an extra config parameter.
{
"@odata.context":"http://wabi-europe-north-b-redirect.analysis.windows.net/v1.0/myorg/groups/63ef8228-4301-45f1-b2d4-20d9675d9dde/$metadata#reports/$entity",
"id":"8eba6559-566f-4ca5-bec2-9c01e9c8a749",
"reportType":"PowerBIReport",
"name":"Global Superstore",
"webUrl":"https://app.powerbi.com/groups/63ef8228-4301-45f1-b2d4-20d9675d9dde/reports/8eba6559-566f-4ca5-bec2-9c01e9c8a749",
"embedUrl":"https://app.powerbi.com/reportEmbed?reportId=8eba6559-566f-4ca5-bec2-9c01e9c8a749&groupId=63ef8228-4301-45f1-b2d4-20d9675d9dde&config=eyJjbHVzdGVyVXJsIjoiaHR0cHM6Ly9XQUJJLUVVUk9QRS5OT1JUSC1CLXJlZGlyZWN0LmFuYWx5c2lzLndpbmRvd9MubmV9IiwiZW1iZWRGZWF0dXJlcyI7eyJtb2Rlcm5FbWJlZCI6dHJ1ZX19",
"isOwnedByMe":true,
"datasetId":"21bf3a7f-57bd-9aa1-b1fc-16c74d56d0f1"
}
Did I answer your question? Mark my post as a solution!
Appreciate with a kudos 🙂
Thanks @nandukrishnavs .
Do you have details on what is the purpose of config parameter in the embedUrl? I dont see any difference in report rendering with and without the additional parameter as part of embedded url.
Inorder to get embed token we are already accessing 2 APIs. One to get accesstoken and other one is generatetoken api of the group and report it. If it is mandatory to have the report API, then we have to make 3 api calls. Instead the embedUrl should be part of generate token api end point.
User | Count |
---|---|
5 | |
4 | |
4 | |
2 | |
2 |
User | Count |
---|---|
8 | |
4 | |
4 | |
4 | |
3 |