{"library":"node-red-contrib-device-stats","title":"Node-RED Device Statistics","description":"node-red-contrib-device-stats provides a Node-RED node designed to capture and emit various operating system statistics within a Node-RED flow. It collects data such as CPU usage, memory consumption, network statistics, and system load average, embedding this information into `msg.payload` for further processing. The current stable version is 1.1.2. Releases appear to be infrequent, primarily addressing bug fixes and dependency updates, with notable changes like migrating build systems (Grunt to Gulp) in version 1.1.0. A key differentiator is its seamless integration into Node-RED's visual programming paradigm, allowing users to trigger statistic collection based on incoming messages. However, it is explicitly limited to Linux and macOS environments, making it unsuitable for Windows deployments. The node requires an incoming message to its input port to trigger data collection, it does not poll automatically.","language":"javascript","status":"active","last_verified":"Sun Apr 19","install":{"commands":["npm install node-red-contrib-device-stats"],"cli":null},"imports":["cd ~/.node-red\nnpm install node-red-contrib-device-stats","Drag 'Device Statistics' node from the palette into your Node-RED flow.","msg.payload"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"// To install the Node-RED package:\n// cd ~/.node-red\n// npm install node-red-contrib-device-stats\n\n// Once installed and Node-RED is restarted, follow these steps in the Node-RED editor:\n// 1. Open your Node-RED editor (e.g., http://localhost:1880).\n// 2. Drag an 'Inject' node onto the canvas.\n//    - Configure it to repeat every 3 seconds.\n//    - Set 'Payload' to 'timestamp'.\n// 3. Drag a 'Device Statistics' node onto the canvas.\n//    - Connect the 'Inject' node's output to the 'Device Statistics' node's input.\n//    - Double-click the 'Device Statistics' node to configure it:\n//      - Enable desired statistics (e.g., CPU, Memory, Network).\n//      - Ensure 'Output' is set to 'msg.payload'.\n// 4. Drag a 'Debug' node onto the canvas.\n//    - Connect the 'Device Statistics' node's output to the 'Debug' node's input.\n//    - Configure the 'Debug' node to output 'complete msg object' or 'msg.payload'.\n// 5. Deploy the flow.\n// 6. Observe system statistics appearing in the debug sidebar every 3 seconds.","lang":"javascript","description":"Installs the Node-RED package and demonstrates a basic flow to capture system statistics every 3 seconds, displaying them in the debug sidebar.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}