Freebox os dashboard - Reboot

This flow is only a part from Freebox os dashboard, please go to the collection

Freebox os dashboard

Node-RED flows to manage your Freebox with a Raspberry Pi

Language

French only

Install

Node RED installation :

bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)

Palette needed : node-red-contrib-crypto-js-dynamic node-red-dashboard Command line installation :

cd ~/.nodered
npm install node-red-contrib-crypto-js-dynamic
npm install node-red-dashboard

#Features

  • Reboot button
  • Uplink and Downlink gauge speed
  • Upload and Download chart
  • xDSL gain chart
  • xDSL protocol and modulation
  • Uptime
  • Synchronisation and connection state
  • IPv4 and IPv6 display
  • Temperatures and fan speed
  • DHCP main informations
  • Static and dynamic IP - Host tables
[{"id":"4439d6510d32de5f","type":"tab","label":"redémarrer","disabled":false,"info":""},{"id":"061a46aa4aac3213","type":"ui_toast","z":"4439d6510d32de5f","position":"dialog","displayTime":"5","highlight":"","sendall":true,"outputs":1,"ok":"OK","cancel":"","raw":false,"topic":"Redémarrage","name":"","x":1210,"y":80,"wires":[[]]},{"id":"ba27e086d8587127","type":"http request","z":"4439d6510d32de5f","name":"","method":"POST","ret":"obj","paytoqs":"ignore","url":"http://mafreebox.freebox.fr/api/v8/system/reboot/","tls":"","persist":false,"proxy":"","authType":"","x":710,"y":80,"wires":[["ad9499bd40be0c2f","b2c800da1b5c6e98"]]},{"id":"99ed1554b020dc2b","type":"inject","z":"4439d6510d32de5f","name":"Redémarrer","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":"1","topic":"","payloadType":"date","x":390,"y":40,"wires":[["fb058b5f5cda6f3e"]]},{"id":"fb058b5f5cda6f3e","type":"function","z":"4439d6510d32de5f","name":"set body","func":"msg = {};\nmsg.headers = {\n};\nmsg.headers['X-Fbx-App-Auth'] = global.get(\"session_token\");\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"msg.headers = {\n    'Content-Type':'application/json'\n    \n};\nmsg.headers['X-Fbx-App-Auth'] = global.get(\"session_token\");\nmsg.payload = {\n};\nreturn msg;","libs":[],"x":560,"y":80,"wires":[["ba27e086d8587127"]]},{"id":"ad9499bd40be0c2f","type":"switch","z":"4439d6510d32de5f","name":"","property":"payload.success","propertyType":"msg","rules":[{"t":"true"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":870,"y":80,"wires":[["b24d329633cc5e5e"],["ac663d7015ac34d9"]]},{"id":"7b87623ce8b38ed8","type":"ui_button","z":"4439d6510d32de5f","name":"","group":"b1155bbb.d9b25","order":0,"width":0,"height":0,"passthru":false,"label":"Redémarrer","tooltip":"","color":"","bgcolor":"red","icon":"power_settings_new","payload":"Voulez-vous redémarrer la Freebox ?","payloadType":"str","topic":"Voulez-vous redémarrer la Freebox ?","topicType":"str","x":110,"y":80,"wires":[["2ecfc9a605f4571d"]]},{"id":"2ecfc9a605f4571d","type":"ui_toast","z":"4439d6510d32de5f","position":"dialog","displayTime":"5","highlight":"","sendall":true,"outputs":1,"ok":"OK","cancel":"Annuler","raw":false,"topic":"Redémarrer ?","name":"","x":270,"y":80,"wires":[["38f12a240d82eeea"]]},{"id":"38f12a240d82eeea","type":"switch","z":"4439d6510d32de5f","name":"","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"OK","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":410,"y":80,"wires":[["fb058b5f5cda6f3e"]]},{"id":"b24d329633cc5e5e","type":"change","z":"4439d6510d32de5f","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"La freebox va redémarrer.","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1040,"y":80,"wires":[["061a46aa4aac3213"]]},{"id":"ac663d7015ac34d9","type":"link out","z":"4439d6510d32de5f","name":"success false","links":["37179428002096c8"],"x":955,"y":120,"wires":[]},{"id":"b2c800da1b5c6e98","type":"debug","z":"4439d6510d32de5f","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":890,"y":180,"wires":[]},{"id":"b1155bbb.d9b25","type":"ui_group","name":"Redémarrer","tab":"5c0ab36281749b90","order":5,"disp":true,"width":"7","collapse":false},{"id":"5c0ab36281749b90","type":"ui_tab","name":"Home","icon":"network_check","order":1,"disabled":false,"hidden":false}]

Flow Info

Created 4 years ago
Rating: not yet rated

Owner

Actions

Rate:

Node Types

Core
  • change (x1)
  • debug (x1)
  • function (x1)
  • http request (x1)
  • inject (x1)
  • link out (x1)
  • switch (x2)
Other
  • tab (x1)
  • ui_button (x1)
  • ui_group (x1)
  • ui_tab (x1)
  • ui_toast (x2)

Tags

  • Reboot
  • Freebox
  • FreeboxOS
  • API
  • Free
Copy this flow JSON to your clipboard and then import into Node-RED using the Import From > Clipboard (Ctrl-I) menu option