v1

latestOpenAPI 3.0.0Apache 2.0 License2026-07-14168671.3 KB

Attaches a resource-based policy to a cluster. This policy defines access permissions and conditions for the cluster, allowing you to control which principals can perform actions on the cluster.

post/cluster/{identifier}/policy

Path parameters

identifierstring required

The ID of the cluster.

Request body

policystring required

A resource-based policy document in JSON format. Length constraints: Minimum length of 1. Maximum length of 20480 characters (approximately 20KB).

bypassPolicyLockoutSafetyCheckboolean

A flag that allows you to bypass the policy lockout safety check. When set to true, this parameter allows you to apply a policy that might lock you out of the cluster. Use with caution.

expectedPolicyVersionstring

The expected version of the current policy. This parameter ensures that you're updating the correct version of the policy and helps prevent concurrent modification conflicts.

clientTokenstring

Idempotency token so a request is only processed once.

Response

Success

policyVersionstring required

The version of the policy after it has been updated or created.