REST Resource: folders

Resource: Folder

A Folder in an Organization's resource hierarchy, used to organize that Organization's resources.

JSON representation
{
  "name": string,
  "parent": string,
  "displayName": string,
  "lifecycleState": enum (LifecycleState),
  "createTime": string,
  "tags": {
    string: string,
    ...
  }
}
Fields
name

string

Output only. The resource name of the Folder. Its format is folders/{folder_id}, for example: "folders/1234".

parent

string

Required. The Folder's parent's resource name. Updates to the folder's parent must be performed via folders.move.

displayName

string

The folder's display name. A folder's display name must be unique amongst its siblings, e.g. no two folders with the same parent can share the same display name. The display name must start and end with a letter or digit, may contain letters, digits, spaces, hyphens and underscores and can be no longer than 30 characters. This is captured by the regular expression: [\p{L}\p{N}]([\p{L}\p{N}_- ]{0,28}[\p{L}\p{N}])?.

lifecycleState

enum (LifecycleState)

Output only. The lifecycle state of the folder. Updates to the lifecycleState must be performed via folders.delete and folders.undelete.

createTime

string (Timestamp format)

Output only. Timestamp when the Folder was created. Assigned by the server.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

tags

map (key: string, value: string)

Optional. Input only. Immutable. Tag keys/values directly bound to this folder. Each item in the map must be expressed as " : ". For example: "123/environment" : "production", "123/costCenter" : "marketing"

Note: Currently this field is in Preview.

LifecycleState

Folder lifecycle states.

Enums
LIFECYCLE_STATE_UNSPECIFIED Unspecified state.
ACTIVE The normal and active state.
DELETE_REQUESTED The folder has been marked for deletion by the user.

Methods

create

Creates a Folder in the resource hierarchy.

delete

Requests deletion of a Folder.

get

Retrieves a Folder identified by the supplied resource name.

getIamPolicy

Gets the access control policy for a Folder.

list

Lists the Folders that are direct descendants of supplied parent resource.

move

Moves a Folder under a new resource parent.

patch

Updates a Folder, changing its display_name.
Search for folders that match specific filter criteria.

setIamPolicy

Sets the access control policy on a Folder, replacing any existing policy.

testIamPermissions

Returns permissions that a caller has on the specified Folder.

undelete

Cancels the deletion request for a Folder.