Skip to main content
This script extracts metadata details for all the files and folders in any Box folder and saves the result in a CSV spreadsheet for each metadata template.

Prerequisites

Windows

Install the latest version of .NET core.

macOS & Linux

Install PowerShell. Run the pwsh command to test the installation.
Depending on the directory you are running the command in, the output may differ. For example:
If you encounter issues make sure you installed both .NET core and PowerShell.

Box CLI

To use the script, you need the Box CLI installed and configured. You can do this by following our .

Configure the script

  1. Clone the boxcli GitHub repository and cd into this example’s folder or download the files from the examples directory.
  2. Specify the folderID and userID parameters to tell the script which folder to scan, and who is the user running the script.
    If you don’t want to specify the parameters directly in the script, you can either pass them as flags or allow the script to prompt you to enter them. A sample command with flags looks as follows:

Run the script

  1. Run the Powershell command.
  2. Run the script.
    When the script finishes, you will see the following output or a similar one.

Logs

Logs are stored in a logs folder located in the main folder. You have access to these log files:
  • Metadata-extraction_all.txt that contains all log entries.
  • Metadata-extraction_errors.txt that contains only errors.
Last modified on March 19, 2026