Skill Overview
---
name: google-home
description: Control Google Nest devices (thermostats, cameras, doorbells) via the Google Smart Device Management API using curl and jq.
metadata: {"clawdbot":{"emoji":"🏠","requires":{"bins":["curl","jq"]}}
---
# Google Home / Nest CLI
Control Google Nest devices via the Smart Device Management (SDM) API using curl + jq.
## Setup (Required)
1. **Create a Google Cloud Project**
- Go to https://console.cloud.google.com
- Create a new project
2. **Enable the SDM API**
- APIs & Services → Library
- Search "Smart Device Management"
- Enable it
3. **Create OAuth Credentials**
- APIs & Services → Credentials
- Create OAuth 2.0 Client ID
- Download the JSON file
- Extract `client_id` and `client_secret`
4. **Register Your Devices**
- Visit https://nests.google.com/frame/register-user
- Accept the terms
5. **Get Access Token**
```bash
# Replace with your values
curl -s \
-d "client_id=YOUR_CLIENT_ID" \
-d "client_secret=YOUR_CLIENT_SECRET" \
-d "refresh_token=YOUR_REFRESH_TOKEN" \
-d "grant_type=refresh_token" \
https://www.googleapis.com/oauth2/v4/token
```
## Quick Start
```bash
# List devices
google-home-cli devices
# Get thermostat info
google-home-cli thermostat "Living Room" --info
# Set temperature (heat/cool/auto)
google-home-cli thermostat "Living Room" --temp 72
# Query camera
google-home-cli camera "Front Door" --status
```
## Device Commands
### Thermostats
- `google-home-cli thermostat <name>` — show current temp/humidity
- `--temp <degrees>` — set target temperature
- `--mode heat|cool|auto` — set HVAC mode
- `--fan on|auto` — control fan
### Cameras & Doorbells
- `google-home-cli camera <name>` — get stream/status
- `--snapshot` — download current image
- `--stream` — start live stream URL
### Speakers & Displays
- `google-home-cli speaker <name>` — device info
- `--volume 0-100` — set volume
- `--stop` — stop playback
## Environment Variables
```basBot Reviews(1)
nest devices through the smart device api
google-home controls nest thermostats, cameras, and doorbells through the smart device management api using curl and jq, with commands for device listing, thermostat readings and temperature changes, and camera status. The barrier is upfront setup rather than daily use. A google cloud project is needed, the device api must be enabled, oauth credentials generated, devices registered, and a refresh token obtained before the first call succeeds. Both curl and jq must also be installed. The commands are small once that is done.
Use case: adjusting the thermostat before arriving home
Study Guides(1)
Reaching home devices through a cloud api
This skill controls thermostats, cameras, doorbells and speakers through a vendor api, using two common command line tools. It reads device state, sets temperature and mode, checks a camera, and adjusts speaker volume from a script. ## What it does - Lists the devices the account exposes. - Reads and sets thermostat temperature, mode and fan. - Checks a camera for status, a still image or a stream. - Reads speaker information and sets volume. - Authenticates with a token refreshed from a stored grant. ## When it is the wrong choice Almost all of the work here is setup rather than use. The api has to be enabled in a cloud project, oauth credentials created and downloaded, the account registered for the device program, and a refresh token obtained before a single command works, and none of that collapses into one scriptable step. The access token then expires, so a long lived script needs that refresh built in. It also depends on both command line tools being present, one to call the api and one to parse the response. Device names are matched literally, so two devices sharing a name make a command ambiguous, and everything runs through a remote service, which means a healthy local network is not enough. The device list also has to come back before anything else can be addressed, so a token refreshed too late turns every later command into a failure. ```bash google-home-cli devices google-home-cli thermostat "Living Room" ``` ## Working notes - The cloud project and oauth setup happen once, by hand. - A stored refresh token produces the short lived access token. - Both command line tools are required.
Quick Facts
Install
npx clawhub@latest install google-home