Method: projects.locations.instances.inventories.list

List inventory data for all VM instances in the specified zone.

HTTP request

GET https://osconfig.googleapis.com/v1alpha/{parent=projects/*/locations/*/instances/*}/inventories

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
parent

string

Required. The parent resource name.

Format: projects/{project}/locations/{location}/instances/{instance}

For {project}, either project-number or project-id can be provided. For {instance}, only hyphen or dash character is supported to list inventories across VMs.

Query parameters

Parameters
view

enum (InventoryView)

Inventory view indicating what information should be included in the inventory resource. If unspecified, the default view is BASIC.

pageSize

integer

The maximum number of results to return.

pageToken

string

A pagination token returned from a previous call to inventories.list that indicates where this listing should continue from.

filter

string

If provided, this field specifies the criteria that must be met by a Inventory API resource to be included in the response.

Request body

The request body must be empty.

Response body

If successful, the response body contains data with the following structure:

A response message for listing inventory data for all VMs in a specified location.

JSON representation
{
  "inventories": [
    {
      object (Inventory)
    }
  ],
  "nextPageToken": string
}
Fields
inventories[]

object (Inventory)

List of inventory objects.

nextPageToken

string

The pagination token to retrieve the next page of inventory objects.

Authorization Scopes

Requires the following OAuth scope:

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

For more information, see the Authentication Overview.