SmartLight
  • SmartLight
  • About
    • How does it work?
    • Links
  • Setup
    • Build the Hardware
      • Get required components
      • Assemble the PCB(s)
      • Install Firmware
    • Connect your devices
    • Setup the Server (optional)
  • Integrations
    • API
      • Examples
        • IFTTT & Google Assistant
    • Google Home
Powered by GitBook
On this page
  • 0. Open IFTTT and create a new action
  • 1. Create Action Trigger
  • 2. Create Action
  • 3. Test it - "Hey Google, turn on the kitchen light"

Was this helpful?

Edit on GitHub
  1. Integrations
  2. API
  3. Examples

IFTTT & Google Assistant

This page shows, how you can use the natural language API in combination with Google Assistant to control SmartLight with your voice.

PreviousExamplesNextGoogle Home

Last updated 3 years ago

Was this helpful?

You need an to continue.

0. Open IFTTT and create a new action

Open:

1. Create Action Trigger

  1. Choose "Google Assistant" as the Service

  2. Choose "Say a phrase with a text ingredient"

  3. Enter some phrases with a $ placeholders like: "Turn the light $" (figure 1) and choose your language.

  4. Click "Create Trigger"

2. Create Action

  1. Choose "Webhooks" (figure 2) as your action service.

  2. Fill in the webhook form

    1. URL: http://localhost:5000/aj-smartlight/us-central1/api/units/setNL

    2. Method: POST

    3. Content Type: application/JSON

    4. Body

      1. Open the Web-App, go to settings and create your personal access token. (figure 3)

      2. Body Content: { "userid": "YOUR USERID", "token": "YOUR ACCESS TOKEN", "lang": "de", "payload": "{{TextField}}" }

  3. Click "Create Action"

3. Test it - "Hey Google, turn on the kitchen light"

That's it. Now enjoy using your voice to control your home. The API understands a lot of colors and all the named gradients you have saved. If you discover that the Assistant doesn't understand some words correctly, you can give your lamps and groups "tags" which will be handled like aliases.

IFTTT Account
https://ifttt.com/create
figure 1
figure 3
figure 2