node-red | Low-code programming for event-driven applications | Runtime Evironment library

 by   node-red JavaScript Version: 3.1.3 License: Apache-2.0

kandi X-RAY | node-red Summary

kandi X-RAY | node-red Summary

node-red is a JavaScript library typically used in Server, Runtime Evironment, Nodejs applications. node-red has no bugs, it has no vulnerabilities, it has a Permissive License and it has medium support. You can install using 'npm i tekos-flow' or download it from GitHub, npm.

Low-code programming for event-driven applications

            kandi-support Support

              node-red has a medium active ecosystem.
              It has 16785 star(s) with 3115 fork(s). There are 536 watchers for this library.
              There were 5 major release(s) in the last 6 months.
              There are 276 open issues and 1917 have been closed. On average issues are closed in 113 days. There are 75 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of node-red is 3.1.3

            kandi-Quality Quality

              node-red has 0 bugs and 0 code smells.

            kandi-Security Security

              node-red has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              node-red code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              node-red is licensed under the Apache-2.0 License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              node-red releases are available to install and integrate.
              Deployable package is available in npm.
              Installation instructions, examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi has reviewed node-red and discovered the below as its top functions. This is intended to give you an instant insight into node-red implemented functionality, and help decide if they suit your requirements.
            • Verify dependencies .
            • Generate a script script for a script
            • Update a module package . json
            • Replace contents of a file .
            Get all kandi verified functions for this library.

            node-red Key Features

            No Key Features are available at this moment for node-red.

            node-red Examples and Code Snippets

            No Code Snippets are available at this moment for node-red.

            Community Discussions


            Docker Container Containing Multiple Services
            Asked 2022-Mar-28 at 15:59

            I am trying to build a container containing 3 applications, for example:

            • Grafana;
            • Node-RED;
            • NGINX.

            So I will just need to expose one por, for example:

            NGINX reverse proxy on port 3001/grafana redirects to grafana on port 3000 and; NGINX reverse proxy on port 3001/nodered redirects to nodered on port 1880.

            Does it make any sense in your vision? Or this architecture is not feasible if compared to docker compose?



            Answered 2022-Mar-28 at 15:59

            If I understand correctly, your concern is about opening only one port publicly.

            For this, you would be better off building 3 separate containers, each with their own service, and all in the same docker network. You could plug your services like you described within the virtual network instead of within the same container.

            Why ? Because containers are specifically designed to hold the environment for a single application, in order to provide isolation and reduce compatibility issues, with all the network configuration done at a higher level, outside of the containers.

            Having all your services inside the same container thwart these mentioned advantages of containerized applications. It's almost like you're not even using containers.



            Cant hit Node-Red web page on Vultr Machine
            Asked 2022-Mar-26 at 15:53

            I have just finished setting up Node-red on the a cloud machine hosted with vultr ( Ubuntu 20.04 x64 ) and I am wanting to be able to hit the Node-Red web page but I am failing to do so.

            I have setup WireGuard so I can VPN into the machine

            I am able to ping the servers Local IP address from my Windows PC

            But I am still unable to hit the Node-Red Web Page

            Even though Node-Red is running

            I am fairly new to working with cloud machines so any help would be highly appreciated.



            Answered 2022-Mar-26 at 15:53

            I'm going to guess that you haven't opened port 1880 for the server.

            This could be in one of 2 places

            1. Vultr appear to have their own firewall which you will need to ensure a suitable rule to allow TCP traffice on port 1880 exists. How to configure the firewall appears to be documented here
            2. You will need to make sure that the port is open in the Ubuntu Firewall as well. Running sudo ufw allow 1880/tcp should do this.



            Node Redis does not work on my windows computer even though the server is up and running
            Asked 2022-Mar-16 at 08:54
            const express = require("express");
            const redis = require("redis");
            const app = express();
            const client = redis.createClient({
              url: "redis://",
            client.on("connect", function () {
              console.log("redis connected");
              console.log(`connected ${redisClient.connected}`);
            client.on("error", (err) => {
            app.listen(process.env.PORT || 3000, () => {
              console.log("Node server started");


            Answered 2021-Nov-28 at 17:30

            Please check your ec2 redis connection



            While Loop in Node Red
            Asked 2022-Mar-14 at 20:07

            I have one system that is connected to some sensors. The main job is to send error numbers when one or more of the sensors are on.

            In order to print the error description I have one csv-File with two columns, the first one with the numbers and the second one with the description.

            In order to make this task I have created one flow in Node-Red:

            1. In one line I save the array with the error numbers coming from the system in one flow variable (RandomNum).
            2. In another line I read the csv-file with the error description, I transform it in an array of objects and then in fuction node I make a search in order to find the error number and the description.

            The search function has as entance the array of objects. I save the flow variable (RandomNum) in an array (ranNum) and I define a new array (newMsg) where I save the description of the errors. Then I use a while-loop in order to go through the array of objects and compare the value of the first column of this array with the number in ranNum. Then I save the description of the error in the array newMsg and I do this while-loop for each value of the ranNum array.

            And here is my problem. When I execute the flow, it works correctly for the first value of the array ranNum but only for this. I get only the description of the first number in the ranNum array as payload, it looks like as the while-loop is used only once, and then it breaks and gives me the array newMsg.

            When I check in the Conetxt, RandomNum is one array,

            An when I ask to get the array ranNum, it's also an array,

            I have check the while-loop at least 20-times, and I have did not found why it does not work.

            Can anyone help me with this topic? Is there a problem with the flow variable or there is big difference between JavaScript and NodeJS that I did not found?

            Here is the flow I have created:



            Answered 2022-Mar-14 at 20:07

            So, I finally found it. The payload in the while-loop was breaking the loop immediately. So I changed the code in the while-loop using a similar code I found on the net. Now it works.

            Old code:



            NODE-RED (Error: Cannot set headers after they are sent to the client) multiple devices sending request
            Asked 2022-Mar-09 at 14:55

            I made a flow to a chatbot on node-red using the IBM cloud AI through http connections and I have the following problem, when sending simultaneous messages in different chats/accounts, this error occurs: "Error: Cannot set headers after they are sent to the client". I know it's related to the request that it can't be overridden. But what would be the way to have multiple devices accessing the same flow without interfering with the request already in progress?

            I'm simulating sending messages through facebook messenger and instagram

            thanks for the time



            Answered 2022-Mar-08 at 21:31

            The last change node implies you are stashing the msg.res field somewhere and putting it back.

            I'm guessing you are using the same context variable to do this so it's getting overwritten by the second invocation, so both events try to respond on the last msg.res and the second one fails because they can only be used once.

            You shouldn't need to do this if all the nodes in the flow behave properly and don't discard msg properties. If there is a node discarding properties then you should raise an issue with it's author to get it fixed.

            In the meantime you need to make sure each invocation keeps track of it's own msg.res which may mean storing it under a unique id (possibly msg._id but if a node is discarding properties this might also change) to they all respond to the correct session.



            TypeError: Class extends value undefined is not a constructor or null (svelte redis)
            Asked 2022-Mar-04 at 20:35

            I just got started with svelte and was trying to make an app with redis as the db. I made a typescript file with all the db functions I would need and tried to import it into my svelte components, but when I did that I got the following error



            Answered 2022-Jan-04 at 20:45

            Normally, because the redis - npm package is designed for Node.js, I would say to follow How to use npm modules in browser? and use browserify so that it's able to run in the browser.

            After reading Can I connect directly to a Redis server from JavaScript running in a browser?, I would say that you need a server-side setup to connect to your redis server and then you can query your server-side as you need.



            How to customize the Split node in Node-Red in a way not to send all msgs at once?
            Asked 2022-Mar-04 at 12:21

            I am trying to customize the Split node in Node-Red in a way to send the next message only when the first arrives to the Join node; as I am doing some processing in between, and would like to process each msg separately before joining them.

            So I have cloned the Split node from Node-Red project, and at the part where the splitting of an array happens; I register listeners to events (random IDs generated by the original Split node).



            Answered 2022-Mar-04 at 12:21

            Modifying the split node is the wrong way to do this.

            There are rate limiting nodes that will do this for you. e.g.

            Or you can use the delay node with it's release function



            How to install back the npm module in Node.js
            Asked 2022-Feb-28 at 13:14

            Today, I wanted to download a module via NPM.
            Thought, because Node.js can't find the NPM modules that I install, maybe, I need to run NPM via the admin PowerShell, in the folder C:\Program Files\nodejs\node_modules. So, did it, ran the command:



            Answered 2022-Feb-28 at 13:14

            Thank you, @Anis, for the answer.

            1. Run the Node.js installer (if you haven't deleted it)
            2. Click Next, then Repair.
            3. Then, click Repair again and wait
            4. Click Finish Now you should have the C:\Program Files\nodejs\node_modules\npm module.



            Node-Red Get File from SFTP
            Asked 2022-Feb-22 at 14:40

            I am using Node-red to connect to SFTP and to get a file. Th Problem is that it returns always this error:

            "Error: sftp.realPath: The "string" argument must be of type string or an instance of Buffer or ArrayBuffer. Received type number (1645531908336) 1645531908336"

            Note: I did not get this error on "List" and i have tried many SFTP servers. Always the same error

            this is the image of my node



            Answered 2022-Feb-22 at 14:40

            1645531908336 looks like it is the timestamp from a standard msg.payload value from an inject node.

            Assuming this is the node-red-contrib-better-sftp node then it looks like it is badly written and will always take the value of msg.payload and override any configured path and filename in the node config. This is a really bad design and should only use the input message if the value is left blank in the config.


            So the quick option for you to test is to remove the msg.payload from the inject node you are testing with.

            You should also raise an issue with the nodes author to fix this behaviour.

            EDIT: There already is an open issue (from mid 2020)



            Flutter HTTP Post Request does not reach Node-RED on Raspberry Pi
            Asked 2022-Feb-22 at 09:42

            I am trying to send data from Flutter to Node-RED (to Raspberry Pi) over HTTP (not HTTPS). The URL is from NO-IP (DDNS). The transfer to a test server from a Youtube Tutorial works fine. But when I change the URL from "" to "" I get no input in the debug window of Node-RED. I tried in the AndroidManifest.xml to add the entry so that http is allowed, but that didn't solve the problem either. Furthermore I checked the port forwarding in the WLAN router configuration of the network where the Raspberry Pi is located. Here a port forwarding of HTTP and 1880 (Node-RED) was configured. The connection of the IP addresses should be ok, because I can access a database from an external port, which is also located on the Raspberry Pi. Can it be that only httpS post requests are possible ?



            Answered 2022-Feb-18 at 14:20

            Change your code to this:


            Community Discussions, Code Snippets contain sources that include Stack Exchange Network


            No vulnerabilities reported

            Install node-red

            Check out for full instructions on getting started.
            sudo npm install -g --unsafe-perm node-red
            Open http://localhost:1880


            More documentation can be found here. For further help, or general discussion, please use the Node-RED Forum or slack team.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
          • npm

            npm i node-red

          • CLONE
          • HTTPS


          • CLI

            gh repo clone node-red/node-red

          • sshUrl


          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link