Package Exports
- @datadrivenconstruction/cad2data
- @datadrivenconstruction/cad2data/lib/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@datadrivenconstruction/cad2data) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
@datadrivenconstruction/cad2data
CAD/BIM converter pipeline — convert Revit, IFC, DWG, DGN files to structured Excel/DAE/PDF data with validation and quantity takeoff.
Part of the Data Driven Construction ecosystem
Supported Formats
| Input | Output | Converter |
|---|---|---|
.rvt |
XLSX, DAE, PDF | RvtExporter |
.ifc |
XLSX, DAE | IfcExporter |
.dwg |
XLSX, PDF | DwgExporter |
.dgn |
XLSX | DgnExporter |
.rvt |
IFC 2x3/4/4x3 | RVT2IFCconverter |
Revit versions: 2015–2026 • IFC versions: 2x3, 4.x • DWG: 1983–2026 • DGN: v7–v8
Requirements
- Windows (converters are native .exe)
- Node.js >= 16
- Microsoft Visual C++ Redistributable 2015–2022 (x64)
Installation
npm install -g @datadrivenconstruction/cad2dataAfter installation, copy your converter executables into the converters directory:
cad2data list # shows the converters directory path and statusCopy these files into the shown directory:
RvtExporter.exeIfcExporter.exeDwgExporter.exeDgnExporter.exeRVT2IFCconverter.exe
CLI Usage
# Convert a single file
cad2data convert Model.rvt
cad2data convert Model.rvt --mode standard --bbox
cad2data convert Model.ifc -o ./output/
# Convert Revit to IFC
cad2data rvt2ifc Model.rvt --ifc-version 4x3
# Batch convert a directory
cad2data batch C:\Projects --format .rvt --format .ifc -r
# List available converters
cad2data list
# Shorthand — pass file directly
cad2data Model.rvtConvert Options
| Flag | Description |
|---|---|
--output, -o <path> |
Output file or directory |
--mode, -m <mode> |
basic / standard / complete |
--bbox |
Include bounding box data |
--room |
Include room data |
--schedule |
Export schedules |
--sheets2pdf |
Export sheets to PDF |
--no-xlsx |
Skip XLSX generation |
--no-collada |
Skip DAE/Collada generation |
--category-file <path> |
Category filter file |
--timeout <ms> |
Timeout in milliseconds |
Export Modes
- basic — 309 categories
- standard — 724 categories
- complete — all 1209 categories
Node.js API
const { CAD2Data } = require('@datadrivenconstruction/cad2data');
const cad = new CAD2Data();
// Single file conversion
const result = await cad.convert('C:/Projects/Model.rvt', {
mode: 'standard',
bbox: true,
room: true,
});
// Revit to IFC
await cad.convertRevitToIfc('Model.rvt', {
ifcVersion: '4x3',
outputFile: 'Model.ifc',
});
// Batch conversion
const { results, errors } = await cad.batch('C:/Projects', {
formats: ['.rvt', '.ifc'],
recursive: true,
onProgress: (file, i, total) => console.log(`[${i}/${total}] ${file}`),
});
// Check installed converters
const converters = cad.listConverters();
console.log(converters);API Reference
cad.convert(inputFile, options?)
Convert a single CAD/BIM file.
inputFile— path to.rvt/.ifc/.dwg/.dgnoptions.outputDir— output directoryoptions.outputFile— explicit output pathoptions.mode—'basic'|'standard'|'complete'options.bbox— include bounding boxoptions.room— include room dataoptions.schedule— export schedulesoptions.sheets2pdf— export sheets to PDFoptions.noXlsx— skip Excel outputoptions.noCollada— skip DAE outputoptions.timeout— timeout in ms
Returns Promise<{ stdout, stderr }>
cad.convertRevitToIfc(inputFile, options?)
Convert Revit file to IFC format.
options.outputFile— output.ifcpathoptions.ifcVersion—'2x3'|'4'|'4x3'
cad.batch(dir, options?)
Batch convert all supported files in a directory.
options.formats— filter extensions, e.g.['.rvt', '.ifc']options.recursive— scan subdirectoriesoptions.convertOpts— options for each conversionoptions.onProgress—(file, index, total) => void
Returns Promise<{ results, errors, total }>
cad.listConverters()
Returns array of available converters with installation status.
n8n Workflows
This package includes pre-built n8n workflow templates in the workflows/ directory:
- Basic Revit/IFC/DWG conversion
- All settings configuration
- Batch converter pipeline
- CAD/BIM data validation
- AI classification with LLM and RAG
- Construction price estimation with LLM
- Carbon footprint / CO2 estimator
- Phase extraction with XLSX parsing
- Quantity takeoff HTML report generator
Import them into your n8n instance from the workflows/ folder.
Links
License
MIT — see LICENSE