make python function to Node-RED node
Project description
NodeRED.py
make python function to Node-RED node
🌐 install
- using pip
python -m pip install nodered.py
- using git(dev)
python -m pip install git+https://github.com/oyajiDev/NodeRED.py.git
🛠 usage
server initialize
- default server
from noderedpy import Server, RED
server = Server(
RED(
os.path.join(__dirname, ".node-red"),
"/node-red", 1880
)
)
- standalone(with webview)
from noderedpy import StandaloneServer, RED
server = StandaloneServer(
RED(
os.path.join(__dirname, ".node-red"),
"/node-red", 1880
)
)
register Node
@register("test")
def test(props:dict, msg:dict) -> dict:
# user codes here
return msg
- See noredpy.decorator.register function for details
- See noderedpy._property for details of "Property"
start server
- default server
server.start("{port}")
- standalone(with webview)
server.start("{title}")
Todos
[x] type support for "list" and "dict"
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
nodered.py-0.1.2.tar.gz
(10.7 kB
view hashes)
Built Distribution
nodered.py-0.1.2-py3-none-any.whl
(13.3 kB
view hashes)
Close
Hashes for nodered.py-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 84522851b1c2f9399c5e83363b79c72335491b0f5cb7a680225730a6da15ca8c |
|
MD5 | 4b7bdacf18f135eee8b10db9569d4dbc |
|
BLAKE2b-256 | c86b374d283c8b99ffa250b91bf3ab58501fdc61d5f89695d3312e9a4b354560 |