@ismaillowkey/node-red-contrib-pcresource 1.0.0

A Node-RED node to fetch PC resources like CPU usage, RAM, etc.

npm install @ismaillowkey/node-red-contrib-pcresource

node-red-contrib-pcresource

A comprehensive Node-RED node package to fetch real-time PC hardware and system resources. This package uses the systeminformation library to provide detailed data on CPU, RAM, Disk, OS, and more across Windows, Linux, and macOS.

Installation

Run the following command in your Node-RED user directory (typically ~/.node-red or %USERPROFILE%\.node-red on Windows):

npm install node-red-contrib-pcresource

Nodes

This package provides 5 distinct nodes grouped under the pc resource category in your Node-RED palette:

1. pc resource (All-in-One)

Fetches a comprehensive, aggregated list of available PC metrics concurrently.

  • Designed with built-in timeouts and error handling to prevent system hangs on slower platforms (e.g., Windows WMI).
  • Returns deep nested objects covering cpu, memory, os, system, disk, fileSystems, network, graphics, and battery.

2. get cpu

Fetches real-time CPU statistics.

  • Data payload: usagePercent, totalCore, manufacturer, brand.

3. get ram

Fetches current Memory (RAM) statistics.

  • Data payload: usagePercent, freeSpacePercent, totalRAMGB, usageGB, freeGB.

4. get disk

Fetches aggregate disk usage and free space across all mounted drives.

  • Data payload: usagePercent, freeSpacePercent, totalUsageGB, freeSpaceGB.

5. get os

Fetches operating system details and system uptime.

  • Data payload: platform, distro, release, kernel, arch, hostname, uptimeSeconds, uptimeHours.

Usage & Outputs

Simply trigger any of the nodes with any input (e.g., using an Inject node) to fetch the resource metrics.

Each node provides exactly 2 outputs:

  • Output 1 (Top): Yields the requested resource data inside msg.payload as a JSON object.
  • Output 2 (Bottom): Yields an error message inside msg.payload if the fetch operation fails.

Dependencies

Node Info

Version: 1.0.0
Updated 5 days ago
License: MIT
Rating: not yet rated

Categories

Actions

Rate:

Downloads

0 in the last week

Nodes

  • pc-resource
  • get cpu
  • get ram
  • get disk
  • get os

Keywords

  • node-red
  • cpu
  • ram
  • resource
  • system

Maintainers