---
title: "POST /{resourceId}/providers/Microsoft.PolicyInsights/policyTrackedResources/{policyTrackedResourcesResource}/queryResults"
method: POST
path: "/{resourceId}/providers/Microsoft.PolicyInsights/policyTrackedResources/{policyTrackedResourcesResource}/queryResults"
---

# POST /{resourceId}/providers/Microsoft.PolicyInsights/policyTrackedResources/{policyTrackedResourcesResource}/queryResults

`POST /{resourceId}/providers/Microsoft.PolicyInsights/policyTrackedResources/{policyTrackedResourcesResource}/queryResults`

## Request

- Base URL: `https://management.azure.com`
- URL: `https://management.azure.com/{resourceId}/providers/Microsoft.PolicyInsights/policyTrackedResources/{policyTrackedResourcesResource}/queryResults`
- Auth: OAuth 2
  - Implicit: `https://login.microsoftonline.com/common/oauth2/authorize`
  - Scopes: `user_impersonation`

Queries policy tracked resources under the resource.

## Path parameters

- `resourceId` string, required
- `policyTrackedResourcesResource` 'default', required

## Query parameters

- `$top` integer
- `$filter` string
- `api-version` string, required

## Response `200`

Query results.

- PolicyTrackedResourcesQueryResults: Query results.
  - `value` PolicyTrackedResource[]: Query results.
    - `trackedResourceId` string: The ID of the policy tracked resource.
    - `policyDetails` PolicyDetails: The policy details.
      - `policyDefinitionId` string: The ID of the policy definition.
      - `policyAssignmentId` string: The ID of the policy assignment.
      - `policyAssignmentDisplayName` string: The display name of the policy assignment.
      - `policyAssignmentScope` string: The scope of the policy assignment.
      - `policySetDefinitionId` string: The ID of the policy set definition.
      - `policyDefinitionReferenceId` string: The policy definition reference ID within the policy set definition.
    - `createdBy` TrackedResourceModificationDetails: The details of the policy triggered deployment that created or modified the tracked resource.
      - `policyDetails` PolicyDetails: The policy details.
        - `policyDefinitionId` string: The ID of the policy definition.
        - `policyAssignmentId` string: The ID of the policy assignment.
        - `policyAssignmentDisplayName` string: The display name of the policy assignment.
        - `policyAssignmentScope` string: The scope of the policy assignment.
        - `policySetDefinitionId` string: The ID of the policy set definition.
        - `policyDefinitionReferenceId` string: The policy definition reference ID within the policy set definition.
      - `deploymentId` string: The ID of the deployment that created or modified the tracked resource.
      - `deploymentTime` string, date-time: Timestamp of the deployment that created or modified the tracked resource.
    - `lastModifiedBy` TrackedResourceModificationDetails: The details of the policy triggered deployment that created or modified the tracked resource.
      - `policyDetails` PolicyDetails: The policy details.
        - `policyDefinitionId` string: The ID of the policy definition.
        - `policyAssignmentId` string: The ID of the policy assignment.
        - `policyAssignmentDisplayName` string: The display name of the policy assignment.
        - `policyAssignmentScope` string: The scope of the policy assignment.
        - `policySetDefinitionId` string: The ID of the policy set definition.
        - `policyDefinitionReferenceId` string: The policy definition reference ID within the policy set definition.
      - `deploymentId` string: The ID of the deployment that created or modified the tracked resource.
      - `deploymentTime` string, date-time: Timestamp of the deployment that created or modified the tracked resource.
    - `lastUpdateUtc` string, date-time: Timestamp of the last update to the tracked resource.
  - `nextLink` string: The URL to get the next set of results.

## Other responses

- `default`: Error response describing why the operation failed.

---

[API](https://skmtc.dev/azure/apis/policytrackedresourcesclient.md) - [All operations](https://skmtc.dev/azure/apis/policytrackedresourcesclient/llms.txt) - [OpenAPI document](https://skmtc.dev/azure/apis/policytrackedresourcesclient/revisions/e36af633b43f?raw)
