You can also run a free energy simulation from a gbXML export with bim, OpenStudio, and EnergyPlus.
Revit automation from the command line
powershell.exe -NoProfile -ExecutionPolicy Bypass -Command 'iwr -useb https://bimcli.com/install.ps1?src=site -OutFile $env:TEMP\bim-install.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\bim-install.ps1'
Most Revit automation tools require a Revit plugin, a Python environment, or a Dynamo graph. bim-cli is one Windows program plus a small Revit add-in it installs for you. It starts Revit or attaches to the session you have open, and runs commands against the live model over a local TCP bridge. No admin rights, no per-seat license.
Export sheets, update parameters, extract schedules, and process PDFs -- all from a terminal or AI assistant. Revit runs in its own window; bim-cli handles the commands.
Export sheets to PDF
Export one sheet or every sheet in the model. The sheets go to a folder; one PDF per sheet, named by sheet number.
bim revit export --all-sheets --per-sheet --output ./drawings/
bim revit export-views --filter "FLOOR" --output ./drawings/
Revit's own PDF engine handles the export -- vector output, embedded element IDs, the same quality as File > Export > PDF. bim-cli drives it from the terminal, so nobody clicks through the export dialog.
Bulk-update parameters
Read parameter values from an Excel file and write them back into Revit elements. Hundreds of elements at once, no Revit dialog boxes.
bim excel read assembly-codes.xlsx | bim revit param set --only "Assembly Code" --dry-run
bim excel read assembly-codes.xlsx | bim revit param set --only "Assembly Code"
bim revit param set takes rows with an element id column and one column per parameter, checks and sets each value on its own, and returns every row's old and new value plus an undo block. bim revit param get reads the current values in the same shape. For logic no verb covers, bim revit exec --file script.cs runs a C# script against the live Revit API.
Bulk parameter update details ->
Extract schedules to Excel
Pipe a Revit schedule directly to an Excel file. No schedule view export dialog, no text file intermediate, no reformatting. bim revit schedule-read returns the schedule's rows, and bim excel write takes them from the pipe.
bim revit schedule-read --name "Door Schedule" | bim excel write ./doors.xlsx
{"path":"doors.xlsx","sheet":"Data","rows":47,"columns":["Mark","Type","Width","Height","Level"],"applied":true}
Run arbitrary Revit API code
bim revit exec compiles and runs a C# snippet against the live model on Revit's main thread. No Visual Studio, no .NET SDK, no add-in project -- just a string or a .cs file.
bim revit exec --no-transaction --code "return doc.GetWarnings().Count;"
{"ok":true,"result":14}
bim revit exec --no-transaction --code "return new FilteredElementCollector(doc).OfCategory(BuiltInCategory.OST_Rooms).Cast<Room>().Where(r => r.Area > 0).Select(r => new { r.Name, r.Number, area = Math.Round(r.Area, 1) }).ToList();"
Every Revit API type is available in the execution context: doc, app, uiDoc, uiApp. Return any JSON-serializable value and it comes back as stdout.
Automate with an AI assistant
Your AI coding tool (Claude Code, Cursor, Codex) can install bim-cli, inspect the model, and run commands without you touching the terminal. Describe the task; the assistant handles the commands.
Automate a Revit task using bim-cli.Step 1 -- install bim-cli if not already installed: powershell.exe -NoProfile -ExecutionPolicy Bypass -Command 'iwr -useb https://bimcli.com/install.ps1?src=site -OutFile $env:TEMP\bim-install.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\bim-install.ps1'
Step 2 -- refresh PATH: pwsh: $env:Path += ";$env:LOCALAPPDATA\bim-cli"
Step 3 -- check Revit (bim revit launch starts it if needed) and orient: bim revit status bim describe --json
Then describe what you need done in the model. Examples:
- "Export all A- sheets to PDF in C:\drawings"
- "List all rooms with area under 50 sqft"
- "Set the Assembly Code on all exterior walls to match doors.xlsx"
Headless Revit with Claude Code ->
Install
One command, no admin rights required.
iwr -useb https://bimcli.com/install.ps1?src=site -OutFile $env:TEMP\bim-install.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\bim-install.ps1
Works on Revit 2024 through 2027. The first bim revit command detects your Revit version and places the add-in in %APPDATA%\Autodesk\Revit\Addins\. Your models stay on your machine.
powershell.exe -NoProfile -ExecutionPolicy Bypass -Command 'iwr -useb https://bimcli.com/install.ps1?src=site -OutFile $env:TEMP\bim-install.ps1; powershell -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\bim-install.ps1'
Then ask your assistant to run bim describe --json. See what the installer does.