---
title: "Transfer cluster ownership"
method: POST
path: "/clusters/{clusterId}/members/_transfer-ownership"
tags: ["Clusters"]
---

# Transfer cluster ownership

`POST /clusters/{clusterId}/members/_transfer-ownership`

## Request

- Base URL: `/management/v2/environments/DEFAULT` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/management/v2/environments/DEFAULT/clusters/{clusterId}/members/_transfer-ownership`
- Auth: one of:
  - HTTP basic
  - API key in cookie `Auth-Graviteeio-APIM`

Transfer the ownership of the Cluster to a user, a group or an cluster member.

Return a 404 HTTP Error if Cluster cannot be found.

User must have the CLUSTER_MEMBER[UPDATE] permission.

## Request body

- ClusterTransferOwnership
  - `newPrimaryOwnerId` string: The new primary owner ID (user's technical identifier). Can be null if userReference is defined.
  - `userReference` string: The new primary owner reference (user's reference provided by an identity provider). Can be null if userId is defined.
  - `currentPrimaryOwnerNewRole` string: The name of the role that will be assigned to the current primary owner after the transfer.

## Response `204`

Ownership has been transferred successfully

## Other responses

- `default`: Generic error response

---

[API](https://skmtc.dev/gravitee-io/apis/gravitee-io-apim-management-api-environments.md) - [All operations](https://skmtc.dev/gravitee-io/apis/gravitee-io-apim-management-api-environments/llms.txt) - [OpenAPI document](https://skmtc.dev/gravitee-io/apis/gravitee-io-apim-management-api-environments/revisions/b736a7e375df?raw)
