google-home
Control Google Nest devices (thermostats, cameras, doorbells) via the Google Smart Device Management API using curl and jq.
Installation
Pick a client and clone the repository into its skills directory.
Installation
About this skill
Control Google Nest devices (thermostats, cameras, doorbells) via the Google Smart Device Management API using curl and jq.
How to use
Przejdź do https://console.cloud.google.com i utwórz nowy projekt Google Cloud. Następnie w sekcji APIs & Services → Library wyszukaj "Smart Device Management" i włącz ten interfejs API.
W APIs & Services → Credentials utwórz nowe poświadczenia OAuth 2.0 Client ID, pobierz plik JSON i wyodrębnij z niego client_id oraz client_secret.
Zarejestruj swoje urządzenia, odwiedzając https://nests.google.com/frame/register-user i akceptując warunki.
Uzyskaj token dostępu, wykonując żądanie curl z twoimi client_id, client_secret i refresh_token do https://www.googleapis.com/oauth2/v4/token. Skopiuj zwrócony access_token.
Wyświetl listę dostępnych urządzeń poleceniem google-home-cli devices. Zidentyfikuj nazwy termostatów i kamer, którymi chcesz sterować.
Steruj termostatem poleceniami takimi jak google-home-cli thermostat "Salon" --temp 72 (ustawienie temperatury), --mode heat|cool|auto (zmiana trybu) lub --fan on|auto (kontrola wentylacji). Dla kamer użyj google-home-cli camera "Drzwi wejściowe" --snapshot (pobierz zdjęcie) lub --stream (uruchom transmisję na żywo).