Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,


as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.


As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!



Smart Home Forum by FIBARO Team

Search the Community

Showing results for tags 'api'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • FIBARO Community
    • FIBARO Portal and Forum policy
    • FIBARO
    • Say hello!
    • Off-topics
  • FIBARO Update
    • FIBARO System Update
    • FIBARO Mobile Update
  • FIBARO Community Support
    • Scenes and Interface
    • FIBARO Products
    • FIBARO Mobile
    • FIBARO HomeKit
    • FIBARO Assistant Integrations
    • Other Devices / Third-party devices
    • Tutorials and Guides
    • Home Automation
    • Suggestions
  • FIBARO Społeczność
    • FIBARO
    • Przywitaj się!
    • Off-topic
  • FIBARO Aktualizacja
    • FIBARO System Aktualizacja
    • FIBARO Mobile Aktualizacja
  • FIBARO Wsparcie Społeczności
    • Sceny i Interfejs
    • FIBARO Urządzenia
    • FIBARO Mobilnie
    • FIBARO HomeKit
    • Integracja z Amazon Alexa i Google Home
    • Urządzenia Firm Trzecich
    • Poradniki
    • Automatyka Domowa
    • Sugestie


  • Scenes
  • Virtual Devices
  • Quick Apps
  • Icons

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start






Website URL





  1. I like to initialize an empty table (like HomeTable) from a scene if it is not exist. I tried the simple following lua code but it fails. -- Check if variable exist if (fibaro:getGlobal(DDDTable) == nil) then fibaro:debug("Creating Variable Table "..varName) jsonDDD = { settings = { version='0.1' }, } jDDDTable = json.encode(jsonDDD) fibaro:setGlobal("DDDTable", jDDDTable) -- store table in global else fibaro:debug('Existing Variable') end It sounds crazy but I stuck on this point for 2 days...and my Bosch/Siemens Home-Connect project (I will share it with you guys) is on halt due to this **small** detail. Any help is more than welcome! P.S. @10der I know that you help people (high appreciate, thank you) like me on first steps... what a fool....! here is the code: api.post("/globalVariables", { name="testTable", value="Table", -- optional }) -- Modify existing variable to "predefined" style api.put("/globalVariables/testTable", { name="testTable", value="Table", -- optional isEnum=true, enumValues= { "Table", } }) here is the source: Another question is howto check if a variable is a table or something gone wrong during writing (human interaction).
  2. Hi I tried to use a Hue API command in my scene, but it's not working. I copied the LUA code from a working Hue VD and modify a bit, as the original is to switch off a Hue. I'd like to switch "group/0" in Hue-bridge to turn off all hue lights at once. here is how it looks like and is not working. I guess the problem is : Hue = Net.FHttp(hueIP,huePort) response ,status, errorCode = Hue:PUT('/api/'..hueuser..'/groups/0/action', '{"on":'..on..'}') Any help on that is welcome
  3. Version: 4.510 HC2 REST API Hi guys, since update to version 4.510 i get sometimes this email: "Suspicious Login Attempts Prevented: We noticted 5 failed login attempts to your HC2 that seemed suspicious. For your security, the following IP address xxx has been locked for 30 min" Why? The REST Auth are right. At start status code 200 with successful result and a little bit later 401 bad user and pass. All request, in the previous version, ran flawlessly...
  4. Hi, I have a strange issue. I am trying to do an API call to my HCL from the commandline: local config=assert(io.popen('curl -s "http://username:[email protected]:80/api/devices/118"')) and then do a json decode in order to retrieve the value of 'value' (true of false) The device is a Fibaro Motionsensor, but I don't get a respons, only a nil return. I use 'retrievedvalue = properties.value' If I do the same for this call: config=assert(io.popen('curl -s "http://username:[email protected]:80/api/weather"')) and retrieve value 'Temperature', it works perfect Is there anything different from calling a Fibaro device? How to get it working? I am on software version 4.170 for the HCL Thx, Rik
  5. I have a itho ventilation box, wich can be switched with a wifi rf remote. In a browser it works fine, but not in a VD... How do i do this? Commands are; The box is in the same LAN
  6. Hello, Is it posible to send text to a cell in a Google spreadsheet from Fibaro Lua? My central heating is a zone-heating controlled bij a Fibaro HC2 with zwave Secure thermostats in every room in my house. The heating works by a central gas boiler and electric Heimeier valves with Fibaro relais I like to log the on/off times (then i can calculate the heating minutes per day) so that i can show it in a graph according to the room temperature and outside temperature. With this information i can make my heating even smarter, i can automatically calculate the starting time to heat in the morning depending on the room and outside temperature to reach a certain temp at 9:00 If sending text to a external document is possible it can be used for a lot of other things: - Temperature logs (pir/smoke sensor) - Room usage (pir) - Usage of devices (koffeemachine, radio, tv, computer, lights, .....) - Graphical views - ......
  7. Guest


    Version 1.0.0


    This is an API for Honeywell Lyric T6. The idea is based on Remco B's version for the Honeywell Evo. Using a virtual device with API scene, you can change setpoint and set away, holiday and schedule modes. Because it is a virtual device, you can call these buttons from any other scene. For example I use it while tracking my phones location, this creates options for GeofenceMode in combination with ScheduleMode You will need a webserver (or access to a webserver) for the initial setup. This is to retrieve some keys from Honeywell. As soon as you have the keys, you do not need the webserver anymore. For further details please follow instruction in the pdf and use at own risk. release 1.1 added checkCertificate option to bypass https check. Installation instructions Honeywell Lyric API.pdf Fibaro_Lyric_API.lua
  8. Hi API -> How can i read the latest events from a device. I need the device ID. not all Only from a device ID. - > Thank you.
  9. Hi all, I tried to find similar topic, but without expected success. I'm wondering if it is possible to import the "OUTDOOR AIR QUALITY" indicator from NETATMO sensor to the LUA scene via API? Has anyone of you tried similar solution or maybe wrote a scene which can perform such action? Your advice would be much appreciated. Thanks
  10. Witam, Panowie i Panie oraz drogie wsparcie Fibaro. Nie bardzo wiem w jakom watku umiescic tego posta, dlatego umieszczam go tutaj. Mam nastepujace pytania: 1. Kiedy bedzie wypuszczony nowy plugin do satel integra, ktory bedzie poprawnie obslugiwal Integre 256 ? - to raczej pytanie do fibaro 2. Czy mozna z bloczkow uzbroic strefe w satelu ? -> jakos mi to nie dziala. Rusza z LUA po zmianie z armed na arm. 3. Czy jest jakas komenda w lua do uzbrojenia strefy w satelu z opcjami (takimi jak w satelu 0-wszystko 2-bez wewnetrznych) ? 4. Jak podmienic ikonki czujnikow satela w fibaro ? Pozdrawiam serdecznie Leszek
  11. Hi to all, Sorry if I started a new discussion but I don't find information about my doubt. My main need is to send some information from an external server to HC2 ... to a scena ... or a virtual device... I try to call HC2 through API from another server using REST API but i cannot find the correct syntax to ... for examples "press a button " in a virtual devices... There is someone that can help me? Thanks a lot in advance Paolino
  12. Hello guys! I come from a *nix background and would like to push changes to my LUA scripts to the HC2 without having to copy/paste into a web console. This also makes it a lot easier to have everything under source control. Has anyone taken the time to create scripts for this?
  13. Hi, I need an as complete list as possible of device actions that you may envoke in Lua that takes an additional argument. (That is, not "turnOn", because this is the entire command.) These are the ones that I have found in when going through my devices: "setValue" "setSetpointMode" "setThermostatSetpoint" (2 arguments) "setMode" "setFanMode" "setVolume" "setInterval" "setSlider" (2 arguments) "setProperty" (2 arguments) "pressButton" Have I missed some command? Please note that I need only Actions that a device can perform, not all calls you can make on a device to ask it about its state. Fredrik
  14. My HC2 with firmware 4.140 does not list all registered devices when I do a ///api/devices. It only returns 10 devices in the JSON response array. When I try to access a device that is not listed in this response I get a "404 page not found" error. Some background: I have only installed the HC2 a few days ago. The first devices I registered appear in the JSON device list. Then I moved the HC2 to another floor and registered more devices. These devices do not appear in the JSON, although they work perfectly fine in the HC2 GUI. I have also rebooted the HC2, but it still won't allow API access to all devices. Any idea what's happening here? Thank you for your assistance Thomas
  15. All I tend to be a little lazy when using API calls from LUA in VD and Scenes. I also recently spotted "api.get" in some posts but have seen any information on that in ip/docs or the various fibaro websites. For those that are considerably more professional in the LUA and Fibaro development than me, could you comment on your best practice e.g. error handling, debugging, parsing JSON etc. I will try to curate and consolidate in the first entry of this topic for everyone's benefit. Tutorial for API in VD and scenes by the prolific AutoFrank Also, I should of thought Wikipedia for HTTP error codes. Wikipedia HTTP Error Codes So perhaps comment away on the extract from my announcer VD that uses jishi SONOS API bridge below and lets make that a good example of best practice for those learning the ropes (me included)? thanks in advance local device = fibaro:getSelfId(); local ipaddress = fibaro:getValue(device, "IPAddress"); local port = fibaro:getValue(device, "TCPPort"); local cmd = "/sayall/" local vol = "/50" Debug(true,"white","Ready to send to "..ipaddress..":"..port) Debug(true,"white", "Raw:"..cmd.."Hello"..vol); -- use an encodeTSS function here in cmd = cmd .. encodeTTS(announce).. vol; -- Issue API call sonos = Net.FHttp(ipaddress, port); response, status, errorcode = sonos:GET(cmd); -- simple error checking if tonumber(status)==200 then response=json.decode(response) else Debug(true,"red","Error calling Sono API:"..errorcode.." status: "..status); end
  16. I've recently purchased a Fibaro Home Center 2. And linked up three fibaro dimmer 2, two nexa AD-146 Dimmers and one AD-147. Suddenly (as within adding the first few devices) the admin interface has become unusable due to slowness. I'm seeing that the api call api/refreshStates often returns at around ~30s which is propably a timeout in the code. Since this call is used quite a lot in per page. I'm often getting 3-5 minute page load times. I'm really unsure about where to start debugging this issue. Mem and CPU and other systems stats seem to be working fine. But my home center admin interface is now basically unusable. Anyone seen similar issues? Update: I disabled one of the Nexa AD-146'es. And the problem disappeared. Funny thing is, the sluggishness didn't return when i Re-enabeld it.
  17. Hi, I'm new to HC2 and to scripting in general and am hoping someone can point me in the right direction. I have a Efergy energy monitor on my mains which displays my power consumption in watts and has an API at Energyhive.com. If I input this address into a web browser https://engage.efergy.com/mobile_proxy/getInstant?token=OAuB2POIvD-----------------afpKsGVCnD (I have blanked out part of the access token so the link won't work) it returns this string {"age":0,"last_reading_time":1502878245000,"reading":1851} "reading" = 1851 Watts Is it possible to get that "reading" into Fibaro and use it to monitor energy consumption. I have looked through the forum and have found posts on similar exercises but can't make sense of the scripting required or where to start. I'l be happy just to be able to get the data through Fibaro for now and work out the rest as I learn more. Any help would be greatly appreciated. Thanks, Paul Larkin
  18. Hi, Is it possible to start a scene through an http command with specific attributes? e.g. /api/SceneControl?action=start&id=sceneID&var1=5 Or should I change a global variable using /api/globalVariables first? I feel I will then get in trouble when multiple instances of a scene are ran simultaneously. Thanks, J
  19. Hi all, In an effort to ultimately build some artificial intelligence into/alongside the HC2, I am trying to get as much relevant information out of the system as possible. From the events api I can roughly monitor what is going on. However, I do not know what actually was the trigger for an event. Was it a scene, button or associated device? Is it possible to get this data out as well that you know? Thanks, J
  20. Hi, well beyond my capability and I have no idea how easy or difficult it is to do but I would like to get information from owl intuition PV energy monitor and display it in the HC2. The owl intuition has an api and can push data via multicast or UDP, information attached. I have also attached a PC program that displays the data from the network owl. There is an explanation of how this works here: https://theowl.zendesk.com/hc/en-gb/articles/201284603-Multicast-UDP-API-Information along with some other programs. If anyone is interested in a little project, I would be very happy to test Thanks Network OWL API [Public].pdf Network OWL Multicast.pdf intuition-listener-windows.zip
  21. I was starting to read thru and try the docs as available on my HCL (IP Address/docs). So I created a variable to try. I tried the PUT command and it all works like a charm after some trial and error. But how do I translate this into a string to be used e.g. for a button in a virtual device? the docs subpage provides no clue about this. Currently I have given up as it is just trial and error without having a clue what is wrong. It would be incredible helpful if the docs page would show the string as well in the format it has to be put into the VD String section. It would definitely help beginners like me
  22. Morning all! i am looking to send a plain text command from Fibaro into other systems; however I am struggling getting the command to send. From my understanding you cannot put the username/password in the string that is inside the 'Virtual Device' button. The command I want to send from a VD button is - http://Username:[email protected]:50000/dev/sps/HallLight/Pulse It works using web browsers and applications like Postman. Any ideas?
  23. All, I was wondering if someone has any experience with the Honeywell Lyric T6 Thermostat and "integration" with the Fibaro HC2 ? Looks like a great (simple) device from a "respected" Corporation and has, as far as I see, great potential to be integrated with Fibaro (VD and Senes).
  24. Good evening, I'm stuck trying to read the status of a device and use it on a local website. (I want to have a tablet with a continuously refreshing page displaying the status of some devices.) When i use this line in a browser: http://username:[email protected]//api/devices/5 i get the following json response from the HC2 {"id":5,"name":"Kerst Takken","roomID":4,"type":"com.fibaro.binarySwitch","baseType":"com.fibaro.actor","enabled":true,"visible":true,"isPlugin":false,"parentId":4,"remoteGatewayId":0,"interfaces":["deviceGrouping","light","zwave","zwaveConfiguration","zwaveSwitchAll"],"properties":{"parameters":[],"pollingTimeSec":0,"zwaveCompany":"TKB Home","zwaveInfo":"6,3,40","zwaveVersion":"1.4","configured":"true","dead":"false","deviceControlType":"2","deviceGroup":"[]","deviceGroupMaster":"0","deviceIcon":"2","emailNotificationID":"0","emailNotificationType":"0","endPointId":"0","isLight":"true","liliOffCommand":"","liliOnCommand":"","log":"","logTemp":"","manufacturer":"","markAsDead":"true","model":"","nodeId":"2","parametersTemplate":"201","productInfo":"1,24,1,1,1,3,1,4","pushNotificationID":"0","pushNotificationType":"0","remoteGatewayId":"0","saveLogs":"true","serialNumber":"","smsNotificationID":"0","smsNotificationType":"0","switchAllMode":"SWITCH_ALL_INCLUDED_IN_THE_ALL_ON_ALL_OFF_FUNCTIONALITY","useTemplate":"true","userDescription":"","value":"true"},"actions":{"getParameter":1,"reconfigure":0,"setParameter":2,"turnOff":0,"turnOn":0},"created":1487237572,"modified":1487237572,"sortOrder":11} ID=5 and properties.value=true so device 5 is switched on. If i save this in a text file as jsondata.txt and use the following example code i found on the net and modified: <html> <head> <title>The jQuery Example</title> <script type = "text/javascript" src = "https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script> <script type = "text/javascript" language = "javascript"> $(document).ready(function() { $("#driver").click(function(event){ $.getJSON('jsondata.txt', function(jd) { $('#stage').html('<p> id: ' + jd.id + '</p>'); $('#stage').append('<p>Value : ' + jd.properties.value+ '</p>'); }); }); }); </script> </head> <body> <p>Click on the button to load result.html file:</p> <div id = "stage" style = "background-color:#cc0;"> STAGE </div> <input type = "button" id = "driver" value = "Load Data" /> </body> </html> i get the following response: id: 5 Value : true and that is exactly what i want, only i want it with the http api call. so i changed the "$.getjson" line in: $.getJSON('http://user:[email protected]//api/devices/5', function(jd) { But that does not give any response. So the http request is correct, ( i get the right json response direct from the url in the browser) and the script is correct, ( i get the right response using the textfile) the php file and the jsondata.txt are on a webserver are and accessed from a laptop. What am i missing ? Mike.
  25. Hej, Czy komuś z Was może udało się przy pomocy urządzenia wirtualnego (HCL - bez LUA) zawołać akcje na jakimś urządzeniu wykorzystując REST API? Pogrzebałem na forum, ale nic z podanych rozwiązań nie działa...
  • Create New...