API with Mitsubishi MELCloud for heatingpumps - Printable Version +- Logic Machine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8) +--- Thread: API with Mitsubishi MELCloud for heatingpumps (/showthread.php?tid=2186) |
API with Mitsubishi MELCloud for heatingpumps - thomasoppida - 06.08.2019 Hi, Is there anybody that has done an integration with Mitsubishi`s cloud portal MELCloud through api? I found this french guy that has reversed engineered this and created a python script to communicate with it. http://mgeek.fr/blog/un-peu-de-reverse-engineering-sur-melcloud From web searches I have found plugins created for Home Assistant and Domoticz based on this. It would be awsome to have my heating pump also visualized on the HomeLynk. kind regards thomas RE: API with Mitsubishi MELCloud for heatingpumps - admin - 12.08.2019 Can you send cloud login/password via PM so I can provide a working example? RE: API with Mitsubishi MELCloud for heatingpumps - thomasoppida - 12.08.2019 PM sent :-) RE: API with Mitsubishi MELCloud for heatingpumps - admin - 12.08.2019 Here's a working example, it will log all devices from your account. Code: email = 'test@test.com' RE: API with Mitsubishi MELCloud for heatingpumps - thomasoppida - 12.08.2019 Nice! Thank you very much :-) RE: API with Mitsubishi MELCloud for heatingpumps - meicker - 04.02.2020 (12.08.2019, 11:54)thomasoppida Wrote: Nice! Thank you very much :-)Hello, this topic is a bit older but I hope it can be active again and maybe someone can help ... I am using ioBroker and Melcloud. There is an adapter for homebridge which I am using actually. But I think that it could be done with objects and status. I am serching for a solution to make states which can be read from a json like I do it already for my homepilot or the controme heating system. But I have no idea because I am new to this ... Maybe here is someone knowing the iobroker and knows maybe how to handle the script in this topic correctly. Or maybe it is not possible ... I think the probelm is to get the JSON - For controme I have this javascript - but I also have already the json api available, which I do not have for melcloud -Example für the kitchen and the sensors: Code: const request = require('request'); So the question is - is someone using iobroker and melcloud and has done something like that or has anybody any idea how to do it ? I would like to learn out of this but I have no idea and I am a bloody newbe. Any ideas ... Thanks so far ... Best regards, Marc RE: API with Mitsubishi MELCloud for heatingpumps - admin - 05.02.2020 Start by checking HTTP communication. This script will send a GET request and log the result (change IP as needed): Code: url = 'http://192.168.1.12/get/json/v1/1/temps/1/' RE: API with Mitsubishi MELCloud for heatingpumps - meicker - 05.02.2020 Hey, thanks for your reply ... :-) It seems I can not use it in iobroker as a Javascript. I get errors on the log: javascript.0 2020-02-05 18:36:42.446 error (13885) at Script.runInContext (vm.js:133:20) javascript.0 2020-02-05 18:36:42.445 error (13885) at script.js.Mitsubishi.Skript_1:5:14 javascript.0 2020-02-05 18:36:42.445 error (13885) TypeError: Cannot set property 'TIMEOUT' of undefined javascript.0 2020-02-05 18:36:42.445 error (13885) ^ javascript.0 2020-02-05 18:36:42.445 error (13885) http.TIMEOUT = 5 javascript.0 2020-02-05 18:36:42.444 error (13885) script.js.Mitsubishi.Skript_1: script.js.Mitsubishi.Skript_1:5 javascript.0 2020-02-05 18:36:42.443 error (13885) at Script.runInContext (vm.js:133:20) javascript.0 2020-02-05 18:36:42.442 error (13885) at script.js.Mitsubishi.Skript_1:4:1 javascript.0 2020-02-05 18:36:42.442 error (13885) script.js.Mitsubishi.Skript_1: Error: Cannot find module '/opt/iobroker/node_modules/iobroker.javascript/lib/../../json' javascript.0 2020-02-05 18:36:42.439 error (13885) at Script.runInContext (vm.js:133:20) javascript.0 2020-02-05 18:36:42.439 error (13885) at script.js.Mitsubishi.Skript_1:3:8 javascript.0 2020-02-05 18:36:42.439 error (13885) script.js.Mitsubishi.Skript_1: Error: Cannot find module '/opt/iobroker/node_modules/iobroker.javascript/lib/../../socket.http' Maybe I need to run the script elswhere but not in iobroker ? If yes, how and where ... For URL I need to use the melcloud, I guess. But before I need to logon there ... see the script in topic #4 - I tried this also in iobroker but has errors in log also ... seems not to be JAVA. If possible I should login with Java, then find possible devices and the create the datapoints ... Best regards, Marc RE: API with Mitsubishi MELCloud for heatingpumps - admin - 05.02.2020 My example is in Lua for LM |