Get items in folder


Retrieves a page of items in a folder. These items can be files, folders, and web links.

To request more information about the folder itself, like its size, please use the Get a folder endpoint instead.



Path Parameters

stringin pathrequired

The unique identifier that represent a folder.

The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the url https://* the folder_id is 123.

The root folder of a Box account is always represented by the ID 0.

Query Parameters

stringin queryoptional

The direction to sort items in.

Value is one of "ASC", "DESC"

string arrayin queryoptional

A comma-separated list of attributes to include in the response. This can be used to request fields that are not normally returned in a standard response.

Be aware that specifying this parameter will have the effect that none of the standard fields are returned in the response unless explicitly specified, instead only fields for the mini representation are returned, additional to the fields requested.

integer / int64in queryoptional

The maximum number of items to return per page.

stringin queryoptional

The position marker at which to begin the response.

This requires usemarker to be set to true.

integer / int64in queryoptional

The offset of the item at which to begin the response.

stringin queryoptional

Defines the second attribute by which items are sorted.

Items are always sorted by their type first, with folders listed before files, and files listed before web links.

This parameter is not supported for marker-based pagination on the root folder (the folder with an ID of 0).

Value is one of "id", "name", "date", "size"

booleanin queryoptional

Specifies whether to use marker-based pagination instead of offset-based pagination. Only one pagination method can be used at a time.

By setting this value to true, the API will return a marker field that can be passed as a parameter to this endpoint to get the next page of the response.



Returns a collection of files, folders, and web links contained in a folder.

application/jsonClient Error

Returned when the access token provided in the Authorization header is not recognized or not provided.

application/jsonClient Error

Returned if the folder is not found, or the user does not have access to the folder.

application/jsonClient Error

Returned if the folder_id is not in a recognized format.

You can now try out some of our APIs live, right here in the documentation.
Log In

Request Example

curl -X GET \
     -H "Authorization: Bearer <ACCESS_TOKEN>"
BoxCollection<BoxItem> folderItems = await client.FoldersManager.GetFolderItemsAsync("11111", 100);
BoxFolder folder = new BoxFolder(api, "id");
for (BoxItem.Info itemInfo : folder) {
    if (itemInfo instanceof BoxFile.Info) {
        BoxFile.Info fileInfo = (BoxFile.Info) itemInfo;
        // Do something with the file.
    } else if (itemInfo instanceof BoxFolder.Info) {
        BoxFolder.Info folderInfo = (BoxFolder.Info) itemInfo;
        // Do something with the folder.
items = client.folder(folder_id='22222').get_items()
for item in items:
    print('{0} {1} is named "{2}"'.format(item.type.capitalize(),,
        fields: 'name',
        offset: 0,
        limit: 25
    .then(items => {
        /* items -> {
            total_count: 2,
            [ { type: 'folder',
                id: '11111',
                sequence_id: '1',
                etag: '1',
                name: 'Personal Documents' },
                { type: 'file',
                id: '22222',
                sequence_id: '0',
                etag: '0',
                name: 'Q2 Strategy.pptx' } ],
            offset: 0,
            limit: 25,
            [ { by: 'type', direction: 'ASC' },
                { by: 'name', direction: 'ASC' } ] }

Response Example

  "total_count": 5000,
  "limit": 1000,
  "offset": 2000,
  "order": [
      "by": "type",
      "direction": "ASC"
  "entries": [
      "id": 12345,
      "etag": 1,
      "type": "file",
      "sequence_id": 3,
      "name": "Contract.pdf"