Method: googleapis.cloudresourcemanager.v2.folders.list

Lists the Folders that are direct descendants of supplied parent resource. List provides a strongly consistent view of the Folders underneath the specified parent resource. List returns Folders sorted based upon the (ascending) lexical ordering of their display_name. The caller must have resourcemanager.folders.list permission on the identified parent.

Arguments

Parameters
pageSize

integer (int32 format)

Optional. The maximum number of Folders to return in the response. The server can return fewer folders than requested. If unspecified, server picks an appropriate default.

pageToken

string

Optional. A pagination token returned from a previous call to ListFolders that indicates where this listing should continue from.

parent

string

Required. The resource name of the Organization or Folder whose Folders are being listed. Must be of the form folders/{folder_id} or organizations/{org_id}. Access to this method is controlled by checking the resourcemanager.folders.list permission on the parent.

showDeleted

boolean

Optional. Controls whether Folders in the DELETE_REQUESTED state should be returned. Defaults to false.

Raised exceptions

Exceptions
ConnectionError In case of a network problem (such as DNS failure or refused connection).
HttpError If the response status is >= 400 (excluding 429 and 503).
TimeoutError If a long-running operation takes longer to finish than the specified timeout limit.
TypeError If an operation or function receives an argument of the wrong type.
ValueError If an operation or function receives an argument of the right type but an inappropriate value. For example, a negative timeout.

Response

If successful, the response contains an instance of ListFoldersResponse.

Subworkflow snippet

Some fields might be optional or required. To identify required fields, refer to the API documentation.

YAML

- list:
    call: googleapis.cloudresourcemanager.v2.folders.list
    args:
        pageSize: ...
        pageToken: ...
        parent: ...
        showDeleted: ...
    result: listResult

JSON

[
  {
    "list": {
      "call": "googleapis.cloudresourcemanager.v2.folders.list",
      "args": {
        "pageSize": "...",
        "pageToken": "...",
        "parent": "...",
        "showDeleted": "..."
      },
      "result": "listResult"
    }
  }
]