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 an HTTP GET request.\u003c/p\u003e\n"],["\u003cp\u003eThe request URL utilizes gRPC Transcoding syntax and requires a \u003ccode\u003eparent\u003c/code\u003e path parameter specifying the project, location, instance, and assignment to target reports for.\u003c/p\u003e\n"],["\u003cp\u003eOptional query parameters, including \u003ccode\u003epageSize\u003c/code\u003e, \u003ccode\u003efilter\u003c/code\u003e, and \u003ccode\u003epageToken\u003c/code\u003e, allow for controlling the number of results, filtering reports, and implementing pagination.\u003c/p\u003e\n"],["\u003cp\u003eThe request body must be empty, and the successful response will contain an array of OS policy assignment reports and a pagination token for retrieving additional pages if needed.\u003c/p\u003e\n"],["\u003cp\u003eAuthorization for this API call requires the \u003ccode\u003ehttps://www.googleapis.com/auth/cloud-platform\u003c/code\u003e OAuth scope 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/v1alpha/{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)."]]