Forum Discussion
Unknown Gateway and Datasource Id's in Admin - Datasets GetDatasourcesAsAdmin API Response
afernand0
I believe the API you're looking for is https://api.powerbi.com/v1.0/myorg/admin/groups/{groupId}/datasets/upstreamDataflows.
Full info is here: https://learn.microsoft.com/en-us/rest/api/power-bi/admin/datasets-get-dataset-to-dataflows-links-in-group-as-admin
Essentially you map the datasetObjectId with the dataflowObjectId using this API. So it has nothing to do with the datasourceId or gatewayId, but if it has {"datasourceType": "Extension", "connectionDetails": {"path": "PowerPlatformDataflows", "kind": "PowerPlatformDataflows"} and the datasetObjectId is in the return of that API, then it's using internal "cloud" connection.
What I'm having issue with, is when a datasource doesn't have an objectId or gatewayId... Solve one problem create a new one!