Method: accessPolicies.create

Create an AccessPolicy. Fails if this organization already has a AccessPolicy. The longrunning Operation will have a successful status once the AccessPolicy has propagated to long-lasting storage. Syntactic and basic semantic errors will be returned in metadata as a BadRequest proto.

HTTP request

POST https://accesscontextmanager.googleapis.com/v1alpha/accessPolicies

The URL uses gRPC Transcoding syntax.

Request body

The request body contains data with the following structure:

JSON representation
{
  "name": string,
  "parent": string,
  "title": string,
  "createTime": string,
  "updateTime": string,
  "etag": string
}
Fields
name

string

Output only. Resource name of the AccessPolicy. Format: accessPolicies/{policy_id}

parent

string

Required. The parent of this AccessPolicy in the Cloud Resource Hierarchy. Currently immutable once created. Format: organizations/{organization_id}

title

string

Required. Human readable title. Does not affect behavior.

createTime

string (Timestamp format)

Output only. Time the AccessPolicy was created in UTC.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".

updateTime

string (Timestamp format)

Output only. Time the AccessPolicy was updated in UTC.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".

etag

string

Output only. An opaque identifier for the current version of the AccessPolicy. This will always be a strongly validated etag, meaning that two Access Polices will be identical if and only if their etags are identical. Clients should not expect this to be in any specific format.

Response body

If successful, the response body contains a newly created instance of Operation.

Authorization Scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

Try it!