---
title: "POST /v1/{+name}:setLocations"
method: POST
path: "/v1/{+name}:setLocations"
tags: ["projects"]
---

# POST /v1/{+name}:setLocations

`POST /v1/{+name}:setLocations`

Sets the locations for a specific cluster. Deprecated. Use [projects.locations.clusters.update](https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1/projects.locations.clusters/update) instead.

## Path parameters

- `name` string, required

## Request body

- SetLocationsRequest — SetLocationsRequest sets the locations of the cluster.
  - `locations` string[] — Required. The desired list of Google Compute Engine [zones](https://cloud.google.com/compute/docs/zones#available) in which the cluster's nodes should be located. Changing the locations a cluster is in will result in nodes being either created or removed from the cluster, depending on whether locations are being added or removed. This list must always include the cluster's primary zone.
  - `projectId` string — Deprecated. The Google Developers Console [project ID or project number](https://cloud.google.com/resource-manager/docs/creating-managing-projects). This field has been deprecated and replaced by the name field.
  - `clusterId` string — Deprecated. The name of the cluster to upgrade. This field has been deprecated and replaced by the name field.
  - `name` string — The name (project, location, cluster) of the cluster to set locations. Specified in the format `projects/*/locations/*/clusters/*`.
  - `zone` string — Deprecated. The name of the Google Compute Engine [zone](https://cloud.google.com/compute/docs/zones#available) in which the cluster resides. This field has been deprecated and replaced by the name field.

## Response `200`

Successful response

---

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