Data Types


Lists the folder's contents.

The result may be paginated: subsequent pages can be requested by passing the cursor from the response into the cursor request parameter.

Pagination is complete when the response includes isPaginationComplete=true.

GET /v2/accounts/{accountId}/folders/list
1curl "{accountId}/folders/list?folderPath=/uploads" \
2 -H "Authorization: Bearer YOUR_API_KEY"
Response (200)
2 "cursor": "/uploads/file.jpg",
3 "folder": {
4 "folderPath": "/uploads",
5 "settings": {
6 "description": "This is an example folder description.",
7 "publicPermissions": [
8 {
9 "permissions": {
10 "file": {
11 "downloadFile": [
12 "*"
13 ]
14 }
15 },
16 "scope": "Children"
17 }
18 ],
19 "storageLayer": {
20 "type": "InternalStorageV2"
21 }
22 },
23 "type": "Folder",
24 "virtual": true
25 },
26 "isPaginationComplete": true,
27 "items": [
28 {
29 "filePath": "/uploads/image.jpg",
30 "fileUrl": "",
31 "lastModified": 1615680311115,
32 "size": 43182,
33 "type": "File"
34 }
35 ]

Your account ID.

This is visible on the settings page:

Example: A623uY2

Type: String

Length: 7

Pagination cursor. This is used to fetch subsequent pages of results from large folders.

To fetch the next page of results, you must set this to the value of the cursor field from the previous ListFolderResponse.

Pagination is complete when ListFolderResponse contains isPaginationComplete=true.

Example: aGVsbG8=

Type: String

This parameter allows you to simulate a CopyFolder or DeleteFolder operation without performing the operation.

When set to true this operation will return the same set of items that would be operated on by the CopyFolder and DeleteFolder operations, assuming you provide the same folderPath and include* parameters to this operation as you do to the CopyFolder and DeleteFolder operations.

Default: false

Type: Boolean

Absolute path to a folder. Begins with a /. Should not end with a /.

Example: /uploads

Type: String

Min Length: 1

Max Length: 512

If true then files will be included in the result.

Default: true

Type: Boolean

If true then includes files from folders that have overridden storage settings, else skips them. The current folder is treated the same: if it has overridden storage settings, then its files will only be included if this flag is true, else they will be skipped.

You can ignore this setting if your account does not use folders with overridden storage settings (e.g. custom AWS S3 buckets).

Default: true

Type: Boolean

If true then folders automatically created by file upload operations will be included.

This field is automatically set to false when recursive=true.

Default: true

Type: Boolean

If true then folders explicitly created using PutFolder will be included.

Default: true

Type: Boolean

The maximum number of items to return.

The response might contain fewer items but will never contain more.

This limit is applied on the unfiltered result, which means the response may contain fewer items than the limit even when there are more items to return. This will occur only when one or more include* flags are set to false.

Example: 50

Type: Integer

Minimum: 1

Maximum: 1000

If true then iterates sub-folders recursively.

Default: false

Type: Boolean

Add one of these Authorization header values to your request:

Option 1: prefix "Bearer " to your API key. The result is your Authorization header value.

Option 2: use HTTP basic authorization with apikey as your username and your API key as your password.

Type: String

Was this section helpful? Yes No

You are using an outdated browser.

This website requires a modern web browser -- the latest versions of these browsers are supported: