This is a sample project that you can run on your computer, allowing it to be connected to the Google Assistant through the smart home integration.
- Install dependencies by running
yarn
- Create a new Firebase project (or use an existing project)
- Take note of the project id
- Run
yarn init:firebase <project-id>
- Go to the Google Cloud Console
- Generate a new private key and save the JSON as
service-account-key.json
in this directory.
- Open the Actions Console
- Create a new Actions project, then select your Firebase project.
- On the onboarding page, select Home Control and then Smart Home
- Run
yarn build && yarn deploy
. This will deploy a webhook to Cloud Functions for Firebase. - Follow the directions shown at the bottom of the output.
- In the Actions Console, press Test to begin testing
Create a profile for your PC (this only needs to be run once)
- Run
yarn init:pc
- Answer questions about your device
A configuration file will be created. If this file is deleted, you will need to run this step again.
- In the Google Home app, go to the Home tab and select Add
- Select Set up device
- Select Have something already set up?
- Click on [test] My test app
- Your account will be linked
Run yarn start
to start the client script.
You will be able to control your PC through the Google Assistant
See LICENSE
.