Method: projects.locations.osPolicyAssignments.get

Retrieve an existing OS policy assignment.

This method always returns the latest revision. In order to retrieve a previous revision of the assignment, also provide the revision ID in thename parameter.

HTTP request

GET https://osconfig.googleapis.com/v1/{name=projects/*/locations/*/osPolicyAssignments/*}

The URL usesgRPC Transcoding syntax.

Path parameters

Parameters
name

string

Required. The resource name of OS policy assignment.

Format:projects/{project}/locations/{location}/osPolicyAssignments/{osPolicyAssignment}@{revisionId}

Request body

The request body must be empty.

Response body

If successful, the response body contains an instance ofOSPolicyAssignment.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see theAuthentication Overview.

IAM Permissions

Requires the followingIAM permission on thename resource:

  • osconfig.osPolicyAssignments.get

For more information, see theIAM documentation.

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-07-28 UTC.