A TapHome API sablon egy PacketParser HTTP sablon, amely a TapHome Core saját REST API-ját integrálja vissza a TapHome-ba. Ez lehetővé teszi a Core-to-Core kommunikációt — az egyik TapHome Core-on megosztott eszközök natív eszközökként tükrözhetők egy másik Core-on. A sablon HTTPS-en (felhő: api.taphome.com:443) vagy HTTP-n (helyi hálózat: http://{core-ip}/api/...) kommunikál, bearer token hitelesítéssel.
A sablon 15 egyedi eszköztípust biztosít, mindegyikből 15 példánnyal (összesen 225 eszköz), amelyek kapcsolókat, fényerőszabályzókat, érzékelőket, mérőket, redőnyöket, világítást, termosztátokat és egyebeket fednek le. Minden eszköz a getDeviceValue és setDeviceValue végpontokon keresztül olvas és ír értékeket, meghatározott valueTypeId paraméterekkel.
Konfiguráció
A TapHome API sablon két konfigurációs paramétert igényel:
API token — a forrás Core-on generálható a Beállítások > Eszközök megosztása > TapHome API menüpontban. A token egyedi bearer formátumot használ (Authorization: TapHome {token}). Egyszerre csak egy token aktív — új token generálása érvényteleníti az előzőt.
Eszköz ID — minden sablon példány egy adott eszköz ID-hez van rendelve a forrás Core-on. A discovery végpont (/api/TapHomeApi/v1/discovery) használatával listázhatod az összes megosztott eszközt az ID-jükkel és támogatott értéktípusaikkal.
A sablon két hozzáférési módot támogat, azonos API struktúrával:
Helyi hálózat — http://{core-ip}/api/TapHomeApi/v1/ (LAN/VPN hozzáférés, alacsonyabb késleltetés, Core 2021.3+ szükséges)
A helyi hálózati hozzáférés kiküszöböli az internet-függőséget és csökkenti a késleltetést. Rendelj statikus IP-t vagy DHCP foglalást a forrás Core-nak, mivel a TapHome Core nem támogatja az mDNS discovery-t.
Eszközfunkciók
A sablon 15 eszköztípust fed le. Minden típus specifikus ValueType ID-ket használ az eszközállapot olvasásához és írásához az API JSON válaszán keresztül ($.values[?(@.valueTypeId == N)].value).
Kapcsolás és kimenet vezérlés
Switch — bináris be/ki vezérlés a ValueType 48 (SwitchState) segítségével. 1 (BE) vagy 0 (KI) értéket olvas és ír.
Analog Output — folyamatos 0–100 % szint a ValueType 42 (AnalogOutputValue) segítségével. Fényerőszabályzókhoz, szelephajtásokhoz vagy bármilyen analóg kimeneti eszközhöz használható.
Multi-Value Switch — numerikus módválasztó 0–9 értékekkel a ValueType 49 segítségével. Felhasználó által definiált állapotokhoz rendelhető többmódú eszközvezérléshez.
Érzékelők és mérés
Analog Input — általános numerikus bemenet a ValueType 55 (AnalogInputValue) segítségével. Csak olvasható.
Temperature Sensor — hőmérséklet (°C) a ValueType 5 (RealTemperature) és páratartalom (%) a ValueType 3 segítségével. Csak olvasható, 15 másodperces lekérdezési időköz.
Brightness Sensor — környezeti fényszint (lux) a ValueType 2 segítségével. Csak olvasható, 15 másodperces lekérdezési időköz.
Wind Speed Sensor — szélsebesség (m/s) a ValueType 14 segítségével. Csak olvasható, 15 másodperces lekérdezési időköz.
Electricity Meter — összesített energia (kWh) a ValueType 59 és pillanatnyi teljesítményfelvétel (kW) a ValueType 60 segítségével. Csak olvasható, 15 másodperces lekérdezési időköz.
Reed Contact — bináris nyitva/zárva állapot a ValueType 44 segítségével. 1 (Nyitva) vagy 0 (Zárva) értéket ad vissza. Csak olvasható.
Világítás
Dual White Light — fényerő (%) a ValueType 65 (HueBrightness) és korrelált színhőmérséklet a ValueType 89 (CCT) segítségével.
RGB Light — teljes HSB színvezérlés: árnyalat (0–360°) a ValueType 40, telítettség (0–100 %) a ValueType 41, fényerő a ValueType 65 és CCT a ValueType 89 segítségével.
Klíma és árnyékolás
Thermostat — aktuális hőmérsékletet (ValueType 5), páratartalmat (ValueType 3) olvas és hőmérséklet alapjelet (ValueType 6) vezérel.
Blind — pozíciószint (%) a ValueType 46 (BlindsLevel) és lamella dőlésszög a ValueType 10 (BlindsSlope) segítségével.
Slide — pozíciószint (%) a ValueType 46 (BlindsLevel) segítségével. Ugyanazt a ValueType-ot használja mint a Blind, de dőlésvezérlés nélkül.
Általános
Variable — általános célú numerikus változó a ValueType 62 (VariableState) segítségével. Bármilyen egyedi értéket képviselhet a TapHome-ban.
Szervizdiagnosztika
A modul egy szervizattribútumot tesz elérhetővé — Devices — amely az /api/TapHomeApi/v1/discovery végpont meghívásával listázza az összes megosztott eszközt az ID-jükkel és típusaikkal.
Az érzékelő típusú eszközök (Brightness, Variable, Wind Speed) egy további eszközszintű szervizattribútumot tartalmaznak — Value Types — amely az adott eszközön elérhető összes ValueType ID-t és nevet listázza.
További funkciók
A TapHome API több rendszerszintű ValueType-ot is elérhetővé tesz, amelyeket a sablon jelenleg nem kérdez le: Device Status (ID 7) az eszköz állapotához, Operation Mode (ID 22) és Manual Timeout (ID 23) a manuális/automatikus mód vezérléséhez. Léteznek alapjel-változatok az Analog Output (ID 67), Hue Brightness (ID 68) és Multi-Value Switch (ID 71) számára, valamint a Blinds Is Moving jelző (ID 66). A discovery és location végpontok diagnosztikai információkat nyújtanak a Core-ról. A webhook push értesítések (300 ms-os korlátozás) valós idejű alternatívát kínálnak a lekérdezéssel szemben. Ezek a funkciók egy jövőbeli sablon frissítésben adhatók hozzá.
Hibaelhárítás
Az API 401 Unauthorized választ ad
Ellenőrizd, hogy a token helyes és nem lett újragenerálva — új token generálása érvényteleníti az összes korábbi tokent
Ellenőrizd az engedélyezési fejléc formátumát: Authorization: TapHome {token} (figyelj a TapHome előtagra a Bearer helyett)
Győződj meg róla, hogy a token a megfelelő Core lokációhoz tartozik
Az API 403 Forbidden választ ad
A kért eszköz nincs megosztva a TapHome API-n keresztül. A forrás Core-on navigálj a Beállítások > Eszközök megosztása > TapHome API menüpontra, és ellenőrizd, hogy az eszköz szerepel a listában.
Gyorsítótárazott vagy elavult értékek
Az API 500 ms-os intervallumra korlátozza a getDeviceValue kérések gyakoriságát. Az ennél gyorsabb kérések gyorsítótárazott értékeket adhatnak vissza. Hasonlítsd össze a válaszban lévő timestamp mezőt — az azonos időbélyegek gyorsítótárazott adatokra utalnak. Növeld a lekérdezési intervallumot legalább 1 másodpercre.
Az írási kérések HTTP 503-at adnak vissza
A setDeviceValue végpont 503-at (Service Unavailable) ad vissza, ha 500 ms-nál gyakrabban hívják. Oszd el az írási kéréseket megfelelő késleltetéssel.
Core-onként egyszerre csak egy API token aktív. Ha egy másik rendszer újragenerálja a tokent (pl. Home Assistant beállítás során), a TapHome sablon elveszíti a hozzáférést. Koordináld a token használatát az összes integráció között.
Elérhető eszközök
TapHome APIModul
Szerviz attribútumok
Eszközök
Egyéni változók
API_token(string)
TapHome API bearer token for authentication (generate in TapHome app under Settings → API)
TapHome API
Szerviz attribútumok
Devices
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/discovery", "GET", "", "Authorization: TapHome " + API_token);
IF response.IsSuccess
var max := PARSEJSON(response.content, "$.devices[-1:].deviceId");
var ret := "";
var i := 0;
do
ret := ret + "(" + PARSEJSON(response.content, "$.devices[" + tostring(i) + "].deviceId", true) + ") ";
ret := ret + PARSEJSON(response.content, "$.devices[" + tostring(i) + "].name", true);
ret := ret + " - " + PARSEJSON(response.content, "$.devices[" + tostring(i) + "].type", true);
ret := ret + "\n";
i := i + 1;
loop while i < max
RETURN(ret);
END
Analóg bemenet (1)Analóg bemenetCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Analóg bemenet (1)
Bemeneti szint olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 55)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Analóg kimenet (1)Fényerőszabályzó
Folyamatos kimeneti szint (0–100 %) fényerőszabályzókhoz, szelephajtásokhoz vagy analóg kimeneti eszközökhöz
numericEgység: %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Analóg kimenet (1)
Szint olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 42)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szint írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=42&value=" + Le, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kapcsoló (1)Kapcsoló
numericjson_path
Értékek / Állapotok: ON · OFF
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Kapcsoló (1)
Kapcsoló állapot olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 48)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (1)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (1)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (1)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (1)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (1)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (1)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (1)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (1)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (1)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (1)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (1)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (1)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (1)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (1)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (2)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (2)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (2)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (2)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (2)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (2)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (2)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (2)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (2)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (2)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (2)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (2)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (2)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (2)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (3)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (3)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (3)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (3)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (3)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (3)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (3)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (3)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (3)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (3)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (3)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (3)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (3)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (3)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (4)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (4)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (4)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (4)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (4)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (4)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (4)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (4)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (4)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (4)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (4)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (4)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (4)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (4)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (5)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (5)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (5)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (5)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (5)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (5)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (5)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (5)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (5)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (5)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (5)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (5)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (5)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (5)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (6)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (6)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (6)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (6)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (6)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (6)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (6)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (6)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (6)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (6)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (6)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (6)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (6)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (6)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (7)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (7)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (7)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (7)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (7)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (7)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (7)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (7)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (7)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (7)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (7)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (7)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (7)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (7)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (8)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (8)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (8)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (8)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (8)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (8)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (8)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (8)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (8)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (8)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (8)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (8)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (8)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (8)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (9)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (9)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (9)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (9)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (9)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (9)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (9)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (9)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (9)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (9)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (9)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (9)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (9)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (9)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (10)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (10)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (10)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (10)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (10)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (10)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (10)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (10)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (10)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (10)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (10)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (10)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (10)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (10)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (11)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (11)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (11)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (11)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (11)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (11)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (11)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (11)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (11)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (11)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (11)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (11)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (11)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (11)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (12)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (12)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (12)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (12)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (12)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (12)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (12)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (12)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (12)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (12)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (12)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (12)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (12)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (12)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (13)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (13)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (13)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (13)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (13)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (13)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (13)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (13)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (13)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (13)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (13)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (13)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (13)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (13)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (14)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (14)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (14)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (14)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (14)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (14)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (14)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (14)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (14)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (14)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (14)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (14)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (14)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (14)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Összesített energiafogyasztás (kWh) és pillanatnyi teljesítményfelvétel (kW)
numericEgység: kWh / kWjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Villamosenergia-mérő (15)
Összes fogyasztás olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 59)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Igény olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 60)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Fényerő érzékelő (15)VáltozóCsak olvasható
numericEgység: luxjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Fényerő érzékelő (15)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 2)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Változó (15)Változó
numericjson_path
Szerviz attribútumok
Értéktípusok
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Változó (15)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 62)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Írás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=62&value=" + Va, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
RGB lámpa (15)HSB lámpa
Teljes HSB színvezérlés — árnyalat, telítettség, fényerő és korrelált színhőmérséklet
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
RGB lámpa (15)
Fényerő olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 65)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Szélsebesség érzékelő (15)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 14)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Szerviz attribútumok
Value Types
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var ret := "";
var i := 0;
do
if ! isnull(PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true))
ret := ret + PARSEJSON(response.content, "$.values[" + i + "].valueTypeId", true);
ret := ret + " - " + PARSEJSON(response.content, "$.values[" + i + "].valueTypeName", true);
ret := ret + "\n";
end
i := i + 1;
loop while i < 10
RETURN(ret);
END
Reed kontaktus (15)Reed kontaktusCsak olvasható
numericjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Reed kontaktus (15)
Olvasás
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 44)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet érzékelő (15)Hőmérséklet-érzékelőCsak olvasható
Hőmérséklet (°C) és páratartalom (%) mérés
numericEgység: °C / %json_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Hőmérséklet érzékelő (15)
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Termosztát (15)Termosztát
Aktuális hőmérséklet, páratartalom és állítható hőmérséklet alapjel
numericEgység: °Cjson_path
Változó: Id — TapHome device ID — set to the ID of the device you want to control (find in TapHome app or via /discovery endpoint)
Termosztát (15)
Hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 5)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Páratartalom olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 3)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet olvasása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/getDeviceValue/" + Id, "GET", "", "Authorization: TapHome " + API_token);
IF(response.IsSuccess)
var value := PARSEJSON(response.content, "$.values[?(@.valueTypeId == 6)].value", true);
IF ISNULL(value)
ADDERROR("Incorrect device type for ID " + Id);
RETURN(NaN);
ELSE
RETURN(TODOUBLE(value));
END
ELSE
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END
Kívánt hőmérséklet írása
VAR response := SENDHTTPREQUEST("/api/taphomeapi/v1/setDeviceValue/" + Id + "?valueTypeId=6&value=" + Se, "GET", "", "Authorization: TapHome " + API_token);
IF(!response.IsSuccess)
ADDERROR("Response:" + response.StatusCode + "|" + PARSEJSON(response.content, "$.title") + " - " + PARSEJSON(response.content, "$.detail"));
RETURN(NaN);
END