This was caused by the bridge not starting correctly.
The solution provided by AI was to downgrade Node.js.
Problem Analysis
Root Cause: Line 354 of install.ps1 calls npm incorrectly
Key code:
PowerShell
$npmCmd = (Get-Command npm -ErrorAction SilentlyContinue)
...
& $nodePath $npmCmd install --production
On Node.js v26.4.0, Get-Command npm resolved to npm.ps1 (a PowerShell script) instead of the traditional npm.cmd. As a result, the actual command executed became:
Plain Text
C:\Program Files\nodejs\node.exe "C:\Program Files\nodejs\npm.ps1" install --production
Node.js attempted to parse npm.ps1 as a JavaScript file, but the first line was PowerShell syntax: Set-StrictMode -Version 'Latest'. Naturally, this resulted in a SyntaxError: Unexpected string.
The npm dependencies were never successfully installed (the node_modules directory was empty). When Bridge started, it could not find dependencies like Express, and thus could not listen on the port.
Solutions (Choose One)
Solution 1: Manually Install Dependencies (Fastest)
Open PowerShell as an administrator and run:
PowerShell
cd "C:\Program Files\Bambu Studio\bridge"
npm.cmd install --production
Or use directly:
PowerShell
& "C:\Program Files\nodejs\npm.cmd" install --production
After installing the dependencies, Bridge will start normally.
Solution 2: Downgrade Node.js to LTS Version (Recommended)
Node.js v26 is an unconventional version released in October 2026, with changes to how npm is packaged. It is recommended to uninstall v26.4.0 and install Node.js v22 LTS:
- Uninstall the current Node.js v26.4.0
- Download Node.js v22 LTS from https://nodejs.org
- Re-run
install.bat
Solution 3: Explicitly Call npm.cmd
Call the cmd version of npm directly in PowerShell:
PowerShell
npm.cmd install --production
Executing this after switching to the installation directory is more reliable than node npm.ps1.
One-sentence Root Cause: On v26, Get-Command npm returns npm.ps1, and the script uses node.exe to execute the .ps1 file. Node.js does not recognize PowerShell syntax and throws an error directly. Using npm.cmd (a batch wrapper) bypasses this issue.