The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
The /datasets()/dependentitems and /datasets()/properties endpoints of the SSRS/PBIRS REST API is returning a "No HTTP resource was found that matches the request URI" error. For example, I can pull the basic information for an existing dataset:
invoke-restmethod "https://xxxxxxx/reports/api/v2.0/DataSets(e03c9b1a-5369-423f-9172-91c6975f4274)" -UseDefaultCredentials
@odata.context : https://xxxxxx/reports/api/v2.0/$metadata#DataSets/$entity
Id : e03c9b1a-5369-423f-9172-91c6975f4274
Name : ExecutionStatus
Description :
Path : /ecubic/SystemsAdmin/Datasets/ExecutionStatus
Type : DataSet
Hidden : False
Size : 882
ModifiedBy : INTRA\MCDONALDG
ModifiedDate : 2013-03-18T11:28:34.21-04:00
CreatedBy : INTRA\MCDONALDG
CreatedDate : 2013-03-18T11:28:34.21-04:00
ParentFolderId : 69e44497-8184-4039-8a21-716eb02fa8a0
IsFavorite : False
ContentType :
Content :
HasParameters : False
QueryExecutionTimeOut : 0
Roles : {}
But attempting to list the dependent items of the dataset results in an error:
invoke-restmethod "https://xxxxxxxx/reports/api/v2.0/DataSets(e03c9b1a-5369-423f-9172-91c6975f4274)/DependentItems" -UseDefaultCredentials
invoke-restmethod : {"error":{"code":"","message":"No HTTP resource was found that matches the request URI
'https://xxxxxx/reports/api/v2.0/DataSets(e03c9b1a-5369-423f-9172-91c6975f4274)/DependentItems'."}}
At line:1 char:1
+ invoke-restmethod "https://xxxxxxx/reports/api/v2.0/DataSets(e ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebExc
eption
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand
Retrieving depdendent items works for other supported item types such as datasources and reports.
Can anyone else confirm this behavior or if this is a known issue?
Thx
I found a solution after digging into the entity definitions and watching what happens in the RSHost log when you view dependencies from the UI. If you use the "CatalogItems" endpoint you can get the DependentItems information:
/reports/api/v2.0/CatalogItems(e03c9b1a-5369-423f-9172-91c6975f4274)/DependentItems
Watch out for the Swagger file that's out there for the REST API. It has lots of issues.
😤😠