---
title: "PATCH /projects/{project}/zones/{zone}/reservations/{reservation}"
method: PATCH
path: "/projects/{project}/zones/{zone}/reservations/{reservation}"
tags: ["reservations"]
---

# PATCH /projects/{project}/zones/{zone}/reservations/{reservation}

`PATCH /projects/{project}/zones/{zone}/reservations/{reservation}`

Update share settings of the reservation.

## Path parameters

- `project` string, required
- `zone` string, required
- `reservation` string, required

## Query parameters

- `paths` string[]
- `requestId` string
- `updateMask` string

## Request body

- Reservation — Represents a reservation resource. A reservation ensures that capacity is held in a specific zone even if the reserved VMs are not running. For more information, read Reserving zonal resources.
  - `description` string — An optional description of this resource. Provide this property when you create the resource.
  - `commitment` string — Output only. [Output Only] Full or partial URL to a parent commitment. This field displays for reservations that are tied to a commitment.
  - `deploymentType` 'DENSE' | 'DEPLOYMENT_TYPE_UNSPECIFIED' — Specifies the deployment strategy for this reservation.
  - `confidentialComputeType` 'CONFIDENTIAL_COMPUTE_TYPE_TDX' | 'CONFIDENTIAL_COMPUTE_TYPE_UNSPECIFIED'
  - `deleteAfterDuration` Duration — A Duration represents a fixed-length span of time represented as a count of seconds and fractions of seconds at nanosecond resolution. It is independent of any calendar and concepts like "day" or "month". Range is approximately 10,000 years.
    - `nanos` integer — Span of time that's a fraction of a second at nanosecond resolution. Durations less than one second are represented with a 0 `seconds` field and a positive `nanos` field. Must be from 0 to 999,999,999 inclusive.
    - `seconds` string, int64 — Span of time at a resolution of a second. Must be from 0 to 315,576,000,000 inclusive. Note: these bounds are computed from: 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years
  - `shareSettings` ShareSettings — The share setting for reservations and sole tenancy node groups.
    - `shareType` 'LOCAL' | 'ORGANIZATION' | 'SHARE_TYPE_UNSPECIFIED' | 'SPECIFIC_PROJECTS' — Type of sharing for this shared-reservation
    - `projectMap` object — A map of project id and project config. This is only valid when share_type's value is SPECIFIC_PROJECTS.
  - `kind` string — Output only. [Output Only] Type of the resource. Alwayscompute#reservations for reservations.
  - `satisfiesPzs` boolean — Output only. [Output Only] Reserved for future use.
  - `schedulingType` 'GROUPED' | 'GROUP_MAINTENANCE_TYPE_UNSPECIFIED' | 'INDEPENDENT' — The type of maintenance for the reservation.
  - `linkedCommitments` string[] — Output only. [Output Only] Full or partial URL to parent commitments. This field displays for reservations that are tied to multiple commitments.
  - `status` 'CREATING' | 'DELETING' | 'INVALID' | 'READY' | 'UPDATING' — Output only. [Output Only] The status of the reservation. - CREATING: Reservation resources are being allocated. - READY: Reservation resources have been allocated, and the reservation is ready for use. - DELETING: Reservation deletion is in progress. - UPDATING: Reservation update is in progress.
  - `specificReservation` AllocationSpecificSKUReservation — This reservation type allows to pre allocate specific instance configuration.
    - `instanceProperties` AllocationSpecificSKUAllocationReservedInstanceProperties — Properties of the SKU instances being reserved. Next ID: 10
      - `localSsds` AllocationSpecificSKUAllocationAllocatedInstancePropertiesReservedDisk[] — Specifies amount of local ssd to reserve with each instance. The type of disk is local-ssd.
        - `diskSizeGb` string, int64 — Specifies the size of the disk in base-2 GB.
        - `interface` 'NVME' | 'SCSI' — Specifies the disk interface to use for attaching this disk, which is either SCSI or NVME. The default isSCSI. For performance characteristics of SCSI over NVMe, seeLocal SSD performance.
      - `minCpuPlatform` string — Minimum cpu platform the reservation.
      - `machineType` string — Specifies type of machine (name only) which has fixed number of vCPUs and fixed amount of memory. This also includes specifying custom machine type following custom-NUMBER_OF_CPUS-AMOUNT_OF_MEMORY pattern.
      - `guestAccelerators` AcceleratorConfig[] — Specifies accelerator type and count.
        - `acceleratorType` string — Full or partial URL of the accelerator type resource to attach to this instance. For example:projects/my-project/zones/us-central1-c/acceleratorTypes/nvidia-tesla-p100 If you are creating an instance template, specify only the accelerator name. See GPUs on Compute Engine for a full list of accelerator types.
        - `acceleratorCount` integer — The number of the guest accelerator cards exposed to this instance.
      - `locationHint` string — An opaque location hint used to place the allocation close to other resources. This field is for use by internal tools that use the public API.
    - `sourceInstanceTemplate` string — Specifies the instance template to create the reservation. If you use this field, you must exclude the instanceProperties field. This field is optional, and it can be a full or partial URL. For example, the following are all valid URLs to an instance template: - https://www.googleapis.com/compute/v1/projects/project/global/instanceTemplates/instanceTemplate - projects/project/global/instanceTemplates/instanceTemplate - global/instanceTemplates/instanceTemplate
    - `count` string, int64 — Specifies the number of resources that are allocated.
    - `assuredCount` string, int64 — Output only. [Output Only] Indicates how many instances are actually usable currently.
    - `inUseCount` string, int64 — Output only. [Output Only] Indicates how many instances are in use.
  - `resourceStatus` AllocationResourceStatus — [Output Only] Contains output only fields.
    - `specificSkuAllocation` AllocationResourceStatusSpecificSKUAllocation — Contains Properties set for the reservation.
      - `sourceInstanceTemplateId` string — ID of the instance template used to populate reservation properties.
      - `utilizations` object — Per service utilization breakdown. The Key is the Google Cloud managed service name.
    - `healthInfo` AllocationResourceStatusHealthInfo — Health information for the reservation.
      - `healthyBlockCount` integer — The number of reservation blocks that are healthy.
      - `healthStatus` 'DEGRADED' | 'HEALTHY' | 'HEALTH_STATUS_UNSPECIFIED' — The health status of the reservation.
      - `degradedBlockCount` integer — The number of reservation blocks that are degraded.
    - `reservationBlockCount` integer — The number of reservation blocks associated with this reservation.
    - `reservationMaintenance` GroupMaintenanceInfo — Maintenance Info for ReservationBlocks.
      - `maintenanceOngoingCount` integer — Progress for ongoing maintenance for this group of VMs/hosts. Describes number of hosts in the block that have ongoing maintenance.
      - `maintenancePendingCount` integer — Progress for ongoing maintenance for this group of VMs/hosts. Describes number of hosts in the block that have pending maintenance.
      - `subblockInfraMaintenancePendingCount` integer — Describes number of subblock Infrastructure that has pending maintenance. Here, Subblock Infrastructure Maintenance pertains to upstream hardware contained in the Subblock that is necessary for a VM Family (e.g. NVLink Domains). Not all VM Families will support this field.
      - `instanceMaintenancePendingCount` integer — Describes number of instances that have pending maintenance.
      - `subblockInfraMaintenanceOngoingCount` integer — Describes number of subblock Infrastructure that has ongoing maintenance. Here, Subblock Infrastructure Maintenance pertains to upstream hardware contained in the Subblock that is necessary for a VM Family(e.g. NVLink Domains). Not all VM Families will support this field.
      - `upcomingGroupMaintenance` UpcomingMaintenance — Upcoming Maintenance notification information.
        - `type` 'MULTIPLE' | 'SCHEDULED' | 'UNKNOWN_TYPE' | 'UNSCHEDULED' — Defines the type of maintenance.
        - `maintenanceStatus` 'ONGOING' | 'PENDING' | 'UNKNOWN'
        - `canReschedule` boolean — Indicates if the maintenance can be customer triggered.
        - `windowEndTime` string — The time by which the maintenance disruption will be completed. This timestamp value is in RFC3339 text format.
        - `maintenanceReasons` string[] — The reasons for the maintenance. Only valid for vms.
        - `windowStartTime` string — The current start time of the maintenance window. This timestamp value is in RFC3339 text format.
        - `maintenanceOnShutdown` boolean — Indicates whether the UpcomingMaintenance will be triggered on VM shutdown.
        - `latestWindowStartTime` string — The latest time for the planned maintenance window to start. This timestamp value is in RFC3339 text format.
      - `schedulingType` 'GROUPED' | 'GROUP_MAINTENANCE_TYPE_UNSPECIFIED' | 'INDEPENDENT' — The type of maintenance for the reservation.
      - `instanceMaintenanceOngoingCount` integer — Describes number of instances that have ongoing maintenance.
  - `reservationSharingPolicy` AllocationReservationSharingPolicy
    - `serviceShareType` 'ALLOW_ALL' | 'DISALLOW_ALL' | 'SERVICE_SHARE_TYPE_UNSPECIFIED' — Sharing config for all Google Cloud services.
  - `protectionTier` 'CAPACITY_OPTIMIZED' | 'PROTECTION_TIER_UNSPECIFIED' | 'STANDARD' — Protection tier for the workload which specifies the workload expectations in the event of infrastructure failures at data center (e.g. power and/or cooling failures).
  - `selfLink` string — Output only. [Output Only] Server-defined fully-qualified URL for this resource.
  - `deleteAtTime` string — Absolute time in future when the reservation will be auto-deleted by Compute Engine. Timestamp is represented inRFC3339 text format.
  - `earlyAccessMaintenance` 'NO_EARLY_ACCESS' | 'WAVE1' | 'WAVE2' — Indicates the early access maintenance for the reservation. If this field is absent or set to NO_EARLY_ACCESS, the reservation is not enrolled in early access maintenance and the standard notice applies.
  - `advancedDeploymentControl` ReservationAdvancedDeploymentControl — Advance control for cluster management, applicable only to DENSE deployment type reservations.
    - `reservationOperationalMode` 'ALL_CAPACITY' | 'HIGHLY_AVAILABLE_CAPACITY' | 'RESERVATION_OPERATIONAL_MODE_UNSPECIFIED' — Indicates chosen reservation operational mode for the reservation.
  - `specificReservationRequired` boolean — Indicates whether the reservation can be consumed by VMs with affinity for "any" reservation. If the field is set, then only VMs that target the reservation by name can consume from this reservation.
  - `creationTimestamp` string — Output only. [Output Only] Creation timestamp inRFC3339 text format.
  - `aggregateReservation` AllocationAggregateReservation — This reservation type is specified by total resource amounts (e.g. total count of CPUs) and can account for multiple instance SKUs. In other words, one can create instances of varying shapes against this reservation.
    - `reservedResources` AllocationAggregateReservationReservedResourceInfo[] — List of reserved resources (CPUs, memory, accelerators).
      - `accelerator` AllocationAggregateReservationReservedResourceInfoAccelerator
        - `acceleratorType` string — Full or partial URL to accelerator type. e.g. "projects/{PROJECT}/zones/{ZONE}/acceleratorTypes/ct4l"
        - `acceleratorCount` integer — Number of accelerators of specified type.
    - `inUseResources` AllocationAggregateReservationReservedResourceInfo[] — Output only. [Output only] List of resources currently in use.
      - `accelerator` AllocationAggregateReservationReservedResourceInfoAccelerator
        - `acceleratorType` string — Full or partial URL to accelerator type. e.g. "projects/{PROJECT}/zones/{ZONE}/acceleratorTypes/ct4l"
        - `acceleratorCount` integer — Number of accelerators of specified type.
    - `workloadType` 'BATCH' | 'SERVING' | 'UNSPECIFIED' — The workload type of the instances that will target this reservation.
    - `vmFamily` 'VM_FAMILY_CLOUD_TPU_DEVICE_CT3' | 'VM_FAMILY_CLOUD_TPU_LITE_DEVICE_CT5L' | 'VM_FAMILY_CLOUD_TPU_LITE_POD_SLICE_CT5LP' | 'VM_FAMILY_CLOUD_TPU_LITE_POD_SLICE_CT6E' | 'VM_FAMILY_CLOUD_TPU_POD_SLICE_CT3P' | 'VM_FAMILY_CLOUD_TPU_POD_SLICE_CT4P' | 'VM_FAMILY_CLOUD_TPU_POD_SLICE_CT5P' | 'VM_FAMILY_CLOUD_TPU_POD_SLICE_TPU7X' — The VM family that all instances scheduled against this reservation must belong to.
  - `name` string — The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply withRFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
  - `enableEmergentMaintenance` boolean — Indicates whether Compute Engine allows unplanned maintenance for your VMs; for example, to fix hardware errors.
  - `params` ReservationParams — Additional reservation params.
    - `resourceManagerTags` object — Input only. Resource manager tags to be bound to the reservation. Tag keys and values have the same definition as resource manager tags. Keys and values can be either in numeric format, such as `tagKeys/{tag_key_id}` and `tagValues/{tag_value_id}` or in namespaced format such as `{org_id|project_id}/{tag_key_short_name}` and `{tag_value_short_name}`. The field is ignored (both PUT & PATCH) when empty.
  - `id` string, uint64 — Output only. [Output Only] The unique identifier for the resource. This identifier is defined by the server.
  - `zone` string — Zone in which the reservation resides. A zone must be provided if the reservation is created within a commitment.
  - `resourcePolicies` object — Resource policies to be added to this reservation. The key is defined by user, and the value is resource policy url. This is to define placement policy with reservation.

## Response `200`

Successful response

---

[API](https://skmtc.net/google/apis/compute.md) · [All operations](https://skmtc.net/google/apis/compute/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/google/compute/versions/6120ed8969d4/schema)
