For {project}, either project-number or project-id can be provided. For {instance}, either instance-name, instance-id, or - can be provided. If '-' is provided, the response will include OSPolicyAssignmentReports for all instances in the project/location. For {assignment}, either assignment-id or - can be provided. If '-' is provided, the response will include OSPolicyAssignmentReports for all OSPolicyAssignments in the project/location. Either {instance} or {assignment} must be -.
For example: projects/{project}/locations/{location}/instances/{instance}/osPolicyAssignments/-/reports returns all reports for the instance projects/{project}/locations/{location}/instances/-/osPolicyAssignments/{assignment-id}/reports returns all the reports for the given assignment across all instances. projects/{project}/locations/{location}/instances/-/osPolicyAssignments/-/reports returns all the reports for all assignments across all instances.
Query parameters
Parameters
pageSize
integer
The maximum number of results to return.
filter
string
If provided, this field specifies the criteria that must be met by the OSPolicyAssignmentReport API resource that is included in the response.
pageToken
string
A pagination token returned from a previous call to the reports.list method that indicates where this listing should continue from.
Request body
The request body must be empty.
Response body
A response message for listing OS Policy assignment reports including the page of results and page token.
If successful, the response body contains data with the following structure:
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-07-28 UTC."],[[["\u003cp\u003eThis webpage details how to list OS policy assignment reports for Compute Engine VM instances within a specified zone using the OS Config API.\u003c/p\u003e\n"],["\u003cp\u003eThe HTTP request uses a \u003ccode\u003eGET\u003c/code\u003e method directed to a URL with path parameters, which include project, location, instance, and assignment identifiers, to pinpoint the desired reports.\u003c/p\u003e\n"],["\u003cp\u003eThe API allows for filtering results by utilizing query parameters, such as \u003ccode\u003epageSize\u003c/code\u003e to limit the number of results, \u003ccode\u003efilter\u003c/code\u003e to set criteria, and \u003ccode\u003epageToken\u003c/code\u003e for pagination.\u003c/p\u003e\n"],["\u003cp\u003eThe request body for listing reports is empty, while the response includes a list of \u003ccode\u003eOSPolicyAssignmentReport\u003c/code\u003e objects and a \u003ccode\u003enextPageToken\u003c/code\u003e for further pagination.\u003c/p\u003e\n"],["\u003cp\u003eAccessing the reports requires OAuth scope \u003ccode\u003ehttps://www.googleapis.com/auth/cloud-platform\u003c/code\u003e and the \u003ccode\u003eosconfig.osPolicyAssignmentReports.list\u003c/code\u003e IAM permission on the parent resource.\u003c/p\u003e\n"]]],[],null,["# Method: projects.locations.instances.osPolicyAssignments.reports.list\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.ListOSPolicyAssignmentReportsResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [IAM Permissions](#body.aspect_1)\n- [Try it!](#try-it)\n\nList OS policy assignment reports for all Compute Engine VM instances in the specified zone.\n\n### HTTP request\n\n`GET https://osconfig.googleapis.com/v1/{parent=projects/*/locations/*/instances/*/osPolicyAssignments/*}/reports`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n### Query parameters\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nA response message for listing OS Policy assignment reports including the page of results and page token.\n\nIf successful, the response body contains data with the following structure:\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/cloud-platform`\n\nFor more information, see the [Authentication Overview](/docs/authentication#authorization-gcp).\n\n### IAM Permissions\n\nRequires the following [IAM](https://cloud.google.com/iam/docs) permission on the `parent` resource:\n\n- `osconfig.osPolicyAssignmentReports.list`\n\nFor more information, see the [IAM documentation](https://cloud.google.com/iam/docs)."]]