NEWS
Fyta Daten auslesen
-
Moin,
hat schon einmal jemand versucht die FYTA Daten in ioBroker zu bekommen, ohne IFTTT zu nutzen? in der API Beschreibung sieht das wie folgt aus:
Auth API
URL: https://web.fyta.de/api/auth/login
Method: POST
Body:
{ "email": "example@example.com", "password": "examplepassword" }
Response:
{ "access_token": "111111111111111111111111111111111111111", "token_type": "Bearer", "expires_in": 5184000, "refresh_token": "2222222222222222222222222222222222222222", "scope": "mobile" }
Get User Plants
URL: https://web.fyta.de/api/user-plant
Method: GET
Response:
{ "gardens": [ { "id": 123, "garden_name": "Home", "origin_path": null, "thumb_path": null, "mac_address": null } ], "plants": [ { "id": 12, "nickname": "Ficus benjamina 1", "scientific_name": "Ficus benjamina", "status": 2, "plant_id": 201, "family_id": null, "wifi_status": 1, "thumb_path": "<url>", "origin_path": "<url>", "plant_thumb_path": "<url>", "plant_origin_path": "<url>", "received_data_at": "2023-01-00 10:10:00", "temperature_optimal_hours": 22, "light_optimal_hours": 0, "temperature_status": 2, "light_status": 1, "moisture_status": 3, "salinity_status": 2, "garden": { "id": 123 }, "sensor": { "id": "AA:AA:AA:2B:AF:F4", "has_sensor": true, "status": 1, "uuid_android": null, "uuid_ios": "4AAAAAA6F-0457-3233-8A43-032B5377E763", "version": "0.30.0", "is_battery_low": false, "received_data_at": "2023-01-01 10:10:00" }, "hub": { "id": 123, "hub_id": "AA:AA:AA:27:7D:6A", "status": 1, "received_data_at": "2023-01-01 01:10:01", "reached_hub_at": "2023-01-01 10:10:01" } } ] }
In meinem jugendlichen Leichtsinn habe ich nun gedacht, man könnte dafür die neuen Blöcke http get und http post nutzen, aber irgendwie bekomme ich es nicht hin, gerade das mit dem Token.
Jörn