- HTTP request
- Path parameters
- Query parameters
- Request body
- Response body
- Authorization scopes
- IAM Permissions
Returns a list of the reservations that are in the parent parameter and match your specified filters.
HTTP request
GET https://capacityplanner.googleapis.com/v1beta/{parent=folders/*/locations/*}/reservations:query
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
| parent | 
 Required. The compute engine resource and location for the time series values to return. The format is: projects/{project}/locations/{location} or organizations/{organization}/locations/{location} or folders/{folder}/locations/{location} | 
Query parameters
| Parameters | |
|---|---|
| locationLevel | 
 Optional. The location level of the reservations usage timeseries. | 
| machineFamily | 
 Optional. The machine family to use to select the aggregate reserved values to return. Possible values include "n1", and "n2d" etc. Empty machineFamily will return results matching all machine families. | 
| machineShape | 
 Optional. The machineShape as a filter to select matching reservations. | 
| gpuType | 
 Optional. The GPU type for the reserved values to return. Sample values are "nvidia-tesla-t4", and "nvidia-tesla-a100". See https://cloud.google.com/compute/docs/gpus for a list. Empty gpuType will return results matching all GPUs. | 
| cloudResourceType | 
 Optional. The resource for the reserved values to return. Possible values include "gce-vcpus", "gce-ram", "gce-local-ssd", "gce-gpu" and "gce-vm". | 
| reservationType | 
 Optional. The Reservation type for example, future reservation request and allocation. If unspecified, all types are included. | 
| shareType | 
 Optional. Types of share settings to filter reservations in response. If unspecified, all types are included. | 
| ownershipType | 
 Optional. Types of ownerships to filter reservations based on. In case of OWNED, it filters reservations which are owned by selected parent project/folder/organization. If unspecified, all types are included. | 
| reservationDataLevel | 
 Optional. Reservations output data format. | 
| includeUnapprovedReservations | 
 Optional. Whether to include pending for approval reservations in the response. This field is only applicable for future reservations. | 
| aggregationMethod | 
 Optional. Aggregation Method of the historical reservation usage | 
| startDate | 
 Optional. The start date of reservations usage. | 
| endDate | 
 Optional. The end date of reservations usage. | 
Request body
The request body must be empty.
Response body
If successful, the response body contains an instance of QueryReservationsResponse.
Authorization scopes
Requires one of the following OAuth scopes:
- https://www.googleapis.com/auth/cloud-platform
- https://www.googleapis.com/auth/devstorage.full_control
For more information, see the Authentication Overview.
IAM Permissions
Requires the following IAM permission on the parent resource:
- capacityplanner.usageHistories.list
For more information, see the IAM documentation.