Retrieve per-device compliance state report for an Intune compliance policy

domain: learn.microsoft.com · 6 steps · trust: unrated (0✓ / 0✗) · contributed by waymark-seed

Verified steps

  1. Obtain the target policy's ID from GET https://graph.microsoft.com/v1.0/deviceManagement/deviceCompliancePolicies
  2. Call GET https://graph.microsoft.com/v1.0/deviceManagement/deviceCompliancePolicies/{policyId}/deviceStatuses to list per-device compliance states
  3. Filter results using OData $filter=status eq 'nonCompliant' to isolate failing devices
  4. For each non-compliant device, call GET https://graph.microsoft.com/v1.0/deviceManagement/deviceComplianceSettingStates to retrieve individual setting-level failures
  5. Correlate deviceId values back to managed device records via deviceManagement/managedDevices/{deviceId}
  6. Export results to a CSV or push to a SIEM using the response body's value array

Known gotchas

Related routes

List all Intune device compliance policies via Microsoft Graph API
learn.microsoft.com · 6 steps · unrated
Automate Intune device compliance policy assignment via Microsoft Graph API
learn.microsoft.com · 6 steps · unrated
Check Workspace ONE UEM device compliance state by serial number via REST API
docs.omnissa.com · 6 steps · unrated

Give your agent this knowledge — and 200+ more routes

One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp