Settings → Printer takes the printer's address, serial number and access code (the code stored as a secret, like the other tokens). "Save & test connection" connects to the printer's own MQTT broker on port 8883, subscribes to its reports, asks once for a full report, and listens for a few seconds — then says what it heard: its state, and the filament in each AMS slot or on the external spool holder, with how much is left where the printer knows. Nothing sent to the printer changes what it is doing; the only thing published is the request for a full report. If the printer is in cloud mode and treats even that as a write, the test says it received nothing rather than failing silently. The access code never leaves the server. Adds mqtt as a runtime dependency — server.js now loads it at startup, so the lockfile has to travel with this change. Not verified against a real printer yet: the printer's ports answer on the network, but no connection has been made with its credentials. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
40 lines
943 B
JSON
40 lines
943 B
JSON
{
|
|
"name": "printhive",
|
|
"version": "1.0.0",
|
|
"description": "Printhive — a web app for organizing 3D-printing files (STL, 3MF, OBJ, ...) with URL import",
|
|
"main": "server.js",
|
|
"scripts": {
|
|
"start": "node server.js",
|
|
"dev": "nodemon server.js",
|
|
"test": "node --test test/*.test.js"
|
|
},
|
|
"keywords": [
|
|
"stl",
|
|
"3d-printing",
|
|
"library",
|
|
"manager"
|
|
],
|
|
"author": "",
|
|
"license": "MIT",
|
|
"dependencies": {
|
|
"@huggingface/transformers": "^3.8.1",
|
|
"7z-wasm": "^1.2.0",
|
|
"adm-zip": "^0.5.17",
|
|
"bcryptjs": "^3.0.3",
|
|
"cookie-parser": "^1.4.7",
|
|
"dotenv": "^17.4.2",
|
|
"express": "^4.18.2",
|
|
"jsonwebtoken": "^9.0.3",
|
|
"mqtt": "^5.16.0",
|
|
"multer": "^1.4.5-lts.1",
|
|
"node-stl": "^0.7.0",
|
|
"nodemailer": "^9.0.1",
|
|
"occt-import-js": "^0.0.23",
|
|
"pg": "^8.22.0",
|
|
"rhino3dm": "^8.32.2",
|
|
"tar": "^7.5.22"
|
|
},
|
|
"devDependencies": {
|
|
"nodemon": "^3.0.2"
|
|
}
|
|
}
|