List metadata instances on folder


Retrieves all metadata for a given folder. This can not be used on the root folder with ID 0.



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.


application/jsonMetadata instances

Returns all the metadata associated with a folder.

This API does not support pagination and will therefore always return all of the metadata associated to the folder.

application/jsonClient error

Returned when the request parameters are not valid.

  • forbidden - this operation is not allowed on the Root folder.
application/jsonClient error

Returned when the user does not have access to the folder.

application/jsonClient error

An unexpected client error.

List metadata instances on folder
You can now try out some of our APIs live, right here in the documentation.
Log in

Request Example

curl -i -X GET "" \
     -H "Authorization: Bearer <ACCESS_TOKEN>"
BoxFolder file = new BoxFolder(api, "id");
Iterable<Metadata> metadataList = folder.getAllMetadata();
for (Metadata metadata : metadataList) {
    // Do something with the metadata.
folder_metadata = client.folder(folder_id='22222').get_all_metadata()
for instance in folder_metadata:
    if 'foo' in instance:
        print('Metadata instance {0} has value "{1}" for foo'.format(instance['id'], instance['foo']))
client.metadata.list(forFolderId: "22222") { (result: Result<[MetadataObject], BoxSDKError>) in
    guard case let .success(metadata) = result {
        print("Error retrieving metadata")

    print("Retrieved \(metadata.count) metadata instances:")
    for instance in metadata {
        print("- \(instance.template)")

Response Example

  "entries": [
      "$parent": "folder_59449484661,",
      "$template": "marketingCollateral",
      "$scope": "enterprise_27335",
      "$version": 1
  "limit": 100