Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Is there a way to fetch ReportId and DatasetId as well from API while fetching tiles data using 'GetTilesInGroupAsyn' method defined in Microsoft.PowerBI.Api.V2 namespace.
Required to be accessible for app generated for non-Power BI Users(i.e. using app owns data).
Solved! Go to Solution.
The returned JSON for Get Tiles API would give the reportId and the DatasetId:
Check the API reference:
The corresponding Tile data is stored under the ODataResponseListTile.Value property, which should be a Tile list.
For the Tile class, see:
For example, to get the first tile ReportId:
using Microsoft.PowerBI.Api.V2;
using Microsoft.PowerBI.Api.V2.Models;
// To retrieve the tile, you first need to retrieve the dashboard.
// You will need to provide the GroupID where the dashboard resides.
ODataResponseListDashboard dashboards = client.Dashboards.GetDashboardsInGroup(GroupId);
// Get the first report in the group.
Dashboard dashboard = dashboards.Value.FirstOrDefault();
// Get a list of tiles from a specific dashboard
ODataResponseListTile tiles = client.Dashboards.GetTilesInGroup(GroupId, dashboard.Id);
// Get the first tile in the group.
Tile tile = tiles.Value.FirstOrDefault();
//Get the first tile ReportId
string rptId = tile.ReportId
or
string rptId = tiles.Value[0].ReportId
Regards,
Michael
Thanks for the reply.
I am using the same approach but Tile class does not have ReportId and DatasetId properties in API version 2.0.2. See screenshot attached.
I am not sure but I think this version of API does not return these properties. Let me know if this is the case which API version should I use which will suffice all my needs or still am I missing something?
Could anyone suggest on this?
API version 2.0.11 resolved my issue. Thanks
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
3 | |
3 | |
3 | |
2 | |
2 |