Forum Discussion
Get PowerBi Audience users via REST API?
Hi
with reports as
(
select
distinct
appId,
id,
name
from
reportsasadmin
)
select distinct
audience.AudienceName,
audience.providerId,
audience.AppId,
audience.AppDisplayName,
audience.Users,
audience.AdName,
audience.`Group`,
reports.id as ReportId,
reports.name as ReportName
from audience
left join reports on reports.appid = audience.AppId
order by AudienceName, Users asc
anwarbham thanks for the explaination. Here I am trying to get the list of reports the traget audiance group has access to. The reportIds[] array has list of visibile reports for each target audiance group. This array dosent have actual report GUID.Instead it has '2202319'.So how can I get the reports for each target audiance group?
Please advise.
- anwarbham1 year agoFrequent Visitor
can you extract the providerKey that is the app ID, Power bi has an api that lists the reports linked to an APP, Or check the "navigationJson" attribute it has ObjectId , this is the Report ID
- Sabarivel1 year agoRegular Visitor
With app ID we can get the associated reports through API call. Also in the navigationJson, we have Report IDs(Object ID) as you mentioned. The challenge here is only in the appViewDetails we have the visilbe report IDs ('2202319') for the Target Audiance. With this string ' 2202319' I need to get the actual report GUID.
Please suggest.- anwarbham1 year agoFrequent Visitor
you need to get the provider id from your first Get call
and make another get call to
the response contains the short report id and the long report id