Freeboard load/save to file

Freeboard integration is easy to add but how do you read/write your freeboard configuration.

I am working on a Database List, Read/Write/Create REST flow and plugin for Freeboard. In the mean time I wanted a simple way to read/write to a file.

[{"id":"bc6d16e5.4392e8","type":"http in","name":"POST Freeboard FILE","url":"/freeboard/file","method":"post","x":103,"y":580,"z":"80882c18.7f77d","wires":[["317047b5.ce8fb8","9752e2c7.68ad2"]]},{"id":"317047b5.ce8fb8","type":"http response","name":"","x":349,"y":560,"z":"80882c18.7f77d","wires":[]},{"id":"9752e2c7.68ad2","type":"file","name":"","filename":"testfreeboard.json","appendNewline":true,"overwriteFile":"true","x":358,"y":597,"z":"80882c18.7f77d","wires":[]},{"id":"7a681f24.8597e","type":"comment","name":"Freeboard Integration","info":"Look at better REST implementation. \n\nCan we for example have separate flows for same path\nGET /x = list, GET /x/:id - one object\nPOST /x - create","x":98,"y":533,"z":"80882c18.7f77d","wires":[]},{"id":"331f1876.cce0e8","type":"http in","name":"GET Freeboard FILE","url":"/freeboard/file","method":"get","x":109,"y":635,"z":"80882c18.7f77d","wires":[["77ca7539.88358c"]]},{"id":"77ca7539.88358c","type":"file in","name":"","filename":"testfreeboard.json","format":"utf8","x":316,"y":639,"z":"80882c18.7f77d","wires":[["c2dc322d.3d23d"]]},{"id":"c2dc322d.3d23d","type":"http response","name":"","x":515,"y":636,"z":"80882c18.7f77d","wires":[]}]
scottp

Flow Info

created 2 years, 9 months ago

Node Types

Core
  • comment (x1)
  • file (x1)
  • file in (x1)
  • http in (x2)
  • http response (x2)

Tags

  • freeoard
  • file
  • http
Copy this flow JSON to your clipboard and then import into Node-RED using the Import From > Clipboard (Ctrl-I) menu option