---
title: "POST /projects/{project}/regions/{region}/disks/{disk}/updateKmsKey"
method: POST
path: "/projects/{project}/regions/{region}/disks/{disk}/updateKmsKey"
tags: ["regionDisks"]
---

# POST /projects/{project}/regions/{region}/disks/{disk}/updateKmsKey

`POST /projects/{project}/regions/{region}/disks/{disk}/updateKmsKey`

Rotates the customer-managed
encryption key to the latest version for the specified persistent disk.

## Path parameters

- `project` string, required
- `region` string, required
- `disk` string, required

## Query parameters

- `requestId` string

## Request body

- RegionDiskUpdateKmsKeyRequest
  - `kmsKeyName` string — Optional. The new KMS key to replace the current one on the disk. If empty, the disk will be re-encrypted using the primary version of the disk's current KMS key. The KMS key can be provided in the following formats: - projects/project_id/locations/location/keyRings/key_ring/cryptoKeys/key Where project is the project ID or project number.

## 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)
