- HTTP request
- Path parameters
- Request body
- Response body
- Authorization scopes
- IAM Permissions
- Try it!
Retrieves details of a specific zone VM extension policy.
HTTP request
GET https://compute.googleapis.com/compute/beta/projects/{project}/zones/{zone}/vmExtensionPolicies/{vmExtensionPolicy}
The URL uses gRPC Transcoding syntax. To know more about valid error responses that can be thrown by this HTTP request, please refer to the service error catalog
Path parameters
| Parameters | |
|---|---|
| project | 
 Project ID for this request. | 
| zone | 
 Name of the zone for this request. | 
| vmExtensionPolicy | 
 Name of the VM extension policy resource to return. | 
Request body
The request body must be empty.
Response body
Represents a VM extension policy.
If successful, the response body contains data with the following structure:
| JSON representation | 
|---|
| { "kind": string, "id": string, "creationTimestamp": string, "updateTimestamp": string, "name": string, "description": string, "selfLink": string, "selfLinkWithId": string, "extensionPolicies": { string: { "stringConfig": string, "pinnedVersion": string }, ... }, "instanceSelectors": [ { "labelSelector": { "inclusionLabels": { string: string, ... } } } ], "priority": integer, "managedByGlobal": boolean, "globalResourceLink": string, "state": enum } | 
| Fields | |
|---|---|
| kind | 
 [Output Only] Type of the resource. Always  | 
| id | 
 [Output Only] The unique identifier for the resource. This identifier is defined by the server. | 
| creationTimestamp | 
 [Output Only] Creation timestamp in RFC3339 text format. | 
| updateTimestamp | 
 [Output Only] zoneVmExtensionPolicies.update timestamp in RFC3339 text format. | 
| name | 
 Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression  | 
| description | 
 An optional description of this resource. | 
| selfLink | 
 [Output Only] Server-defined fully-qualified URL for this resource. | 
| selfLinkWithId | 
 [Output Only] Server-defined URL for this resource's resource id. | 
| extensionPolicies[] | 
 Required. A map of extension names (e.g., "cloudops") to their corresponding policy configurations. | 
| extensionPolicies[].stringConfig | 
 Optional. String-based configuration data for the extension. | 
| extensionPolicies[].pinnedVersion | 
 Optional. The specific version of the extension to install. If not set, the latest version is used. | 
| instanceSelectors[] | 
 Optional. Selectors to target VMs for this policy. VMs are selected if they match any of the provided selectors (logical OR). If this list is empty, the policy applies to all VMs. | 
| instanceSelectors[].labelSelector | 
 Optional. LabelSelector selects VMs based on their labels. | 
| instanceSelectors[].labelSelector.inclusionLabels | 
 Optional. A map of key-value pairs representing VM labels. VMs must have all of the labels specified in this map to be selected (logical AND). e.g. If the  If the map is empty, it's considered a match. | 
| priority | 
 Optional. Priority of this policy. Used to resolve conflicts when multiple policies apply to the same extension. The policy priority is an integer from 0 to 65535, inclusive. Lower integers indicate higher priorities. If you do not specify a priority when creating a rule, it is assigned a priority of 1000. If priorities are equal, the policy with the more recent creation timestamp takes precedence. | 
| managedByGlobal | 
 Optional. [Output Only] Indicates if this policy is managed by a global policy. | 
| globalResourceLink | 
 Optional. [Output Only] Link to the global policy that manages this zone policy, if applicable. | 
| state | 
 Optional. [Output Only] Current state of the policy: ACTIVE or DELETING. | 
Authorization scopes
Requires one of the following OAuth scopes:
- https://www.googleapis.com/auth/compute.readonly
- https://www.googleapis.com/auth/compute
- https://www.googleapis.com/auth/cloud-platform
For more information, see the Authentication Overview.
IAM Permissions
In addition to any permissions specified on the fields above, authorization requires one or more of the following IAM permissions:
- compute.vmExtensionPolicies.get
To find predefined roles that contain those permissions, see Compute Engine IAM Roles.