Share via

Intune device get DetectedApps via Graph (different results for different methods)

Vladimir Tataurov 0 Reputation points
2023-11-23T19:10:27.3933333+00:00

Trying to obtain DetectedApps via Graph.

DeviceManagement.ManagedDevices[deviceId].DetectedApps.Request().GetAsync() - 17 items as a result

(DeviceManagement.ManagedDevices[deviceId].Request().Expand(d => d.DetectedApps).GetAsync()).DetectedApps - 63 items as a result

Why do we have such a difference?

Microsoft Security | Intune | Other
Microsoft Security | Microsoft Graph
0 comments No comments

1 answer

Sort by: Most helpful
  1. Crystal-MSFT 54,311 Reputation points Microsoft External Staff
    2023-11-24T01:30:31.79+00:00

    @Vladimir Tataurov, Thanks for posting in Q&A. The reason for the difference in the number of detected apps obtained through the two methods is due to the difference in the way the data is queried.

    The first method DeviceManagement.ManagedDevices[deviceId].DetectedApps.Request().GetAsync() returns only the detected apps for the specific device ID provided, whereas the second method (DeviceManagement.ManagedDevices[deviceId].Request().Expand(d => d.DetectedApps).GetAsync()).DetectedApps returns all the detected apps for the device ID provided and any related devices.

    Therefore, the second method returns a larger number of detected apps as it includes those detected on related devices.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.