Method: projects.updatePolicy

Creates or updates a project's policy, and returns a copy of the new policy. A policy is always updated as a whole, to avoid race conditions with concurrent policy enforcement (or management!) requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed.

HTTP request


The URL uses gRPC Transcoding syntax.

Path parameters



Output only. The resource name, in the format projects/*/policy. There is at most one policy per project.

Request body

The request body contains an instance of Policy.

Response body

If successful, the response body contains an instance of Policy.

Authorization scopes

Requires the following OAuth scope:


For more information, see the Authentication Overview.