New Item From MQTT String



How can i import new interface item from mqtt in. Is there any way? I tried with this;

MQTT in Message is (Just Button):




Can you explain a bit more what you are trying to do?

It looks like you have published a ui_button node config over mqtt. And you want to dynamically add that to your dashboard? If that is the case, then there is no practical way of doing that. You can only add/remove nodes by deployed them to the runtime. At a stretch, you could create a flow that uses the Node-RED http admin API to get your current flows, merge in the new node(s) into the flow JSON and then post it back to the runtime to deploy it. But that's really quite an involved process.

It may be easier to hear what your actual user need is, and we may be able to suggest more practical ways of satisfying it.



If you were happy to not have the convenience of Dashboard, this is possible with node-red-contrib-uibuilder which allows you to dynamically pass html and javascript from Node-RED to the front-end.

Currently, though, you would have to build your own widgets as that is a project that I've not yet had time to start. I do want to create a widget library for uibuilder that allows dynamic addition of widgets but I just don't have the time to start such a project right now.