node-red-contrib-influxdb3-read 1.0.2
A Node-RED node for executing SQL queries against InfluxDB 3 using the HTTP API.
node-red-contrib-influxdb3-read
A Node-RED node that allows querying InfluxDB 3 using SQL over the HTTP API.
This node complements write-only packages such as node-red-contrib-influxdb3, enabling complete read/write workflows.
β Features
- Execute SQL queries against InfluxDB 3
- HTTP-based implementation
- Custom host, database and authentication token
- Node-REDβfriendly output format
- Fully open source and extensible
π Requirements
| Component | Version |
|---|---|
| Node.js | β₯ 16 |
| npm | β₯ 8 |
| Node-RED | β₯ 3.0.0 |
| InfluxDB 3 | Any HTTP-compatible edition |
π¦ Installation
Node-RED Palette Manager
Search for:
node-red-contrib-influxdb3-read
Or install manually:
cd ~/.node-red npm install node-red-contrib-influxdb3-read
Restart Node-RED afterwards.
βοΈ Configuration
The node requires:
- Host β
http://host.docker.internal:8181orhttp://localhost:8181or host in the cloud - Database β the InfluxDB 3 database name
- Token β an InfluxDB 3 API token
π₯ Input Format
Send a message with a SQL query in:
{
"q": "SELECT * FROM tanque LIMIT 10"
}
Node-RED example:
msg.payload = { q: "SELECT * FROM tanque WHERE sensor = 'ultrasonico'" }; return msg;
π€ Output Format
The result is returned inside:
{ "payload": { "results": [...] } }
π Example Flows
Read last 5 minutes of data msg.payload = { q: "SELECT * FROM tanque WHERE time >= now() - interval '5 minutes'" }; return msg;
Filter by tag msg.payload = { q: "SELECT * FROM tanque WHERE sensor IN ('ultrasonico')" }; return msg;
Select specific fields msg.payload = { q: "SELECT time, value FROM tanque ORDER BY time DESC LIMIT 20" }; return msg;
π Development
Clone this repo:
git clone https://github.com/DanielVickG87/node-red-contrib-influxdb3-read.git
Install dependencies:
npm install
Link into Node-RED:
npm link cd ~/.node-red npm link node-red-contrib-influxdb3-read
Restart Node-RED.
π Issues
Report bugs at:
https://github.com/DanielVickG87/node-red-contrib-influxdb3-read/issues
π License
MIT License
Β© 2025 Daniel Vick