npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

homebridge-nest-debounced

v1.1.4

Published

Nest plugin for homebridge

Downloads

2

Readme

homebridge-nest

Nest plugin for HomeBridge

This repository contains the Nest plugin for homebridge that was previously bundled in the main homebridge repository.

Installation

  1. Install homebridge using: npm install -g homebridge
  2. Install this plugin using: npm install -g homebridge-nest
  3. Update your configuration file. See sample-config.json snippet below.

It is Strongly advised that you switch to the new API but it is not required at the moment. It will fall back to the old API, but no new development will be done on the old API.

Until an alternative is determined (like Nest Weave which hasn't been released yet or setting up a website for generating tokens specifically for HomeBridge-Nest), you will have to setup an developer account for Nest. Its a simple process and if you specify that it is for Individual, then you are auto approved (at least in my experience).

WARNING: Switching to the new API means it will show up as brand new device. This is do to the fact that the unofficial API used a different device id and we have no way to link it to the official cloud device id. This means any configurations, alarms, scenes, etc to which the Nest was associated will have need to be updated with the new Nest device.

Note: The name of the device will change as well. It matches the name displayed in the Nest app. In my case, I originally configured the Nest app so the the "Where" of my Nest was "Hallway" and I also added a label which was "Nest", so the display was "Hallway (Nest)". To fix the name to say "Nest", you can use the Nest app and blank out the "Label" and use the custom "Where" of "Nest". Anther option to fix the name is through HomeKit. HomeKit allows you to rename Accessories and Services, but it requires an app like Insteon+ that has the ability to change the name.

How to Setup New API

  1. Go to https://developer.nest.com
  2. Choose Sign In
  3. Use your normal account to sign in
  4. Fill in you info in 'Step 1'
  5. In 'Step 2' set:
    • Company Name: HomeBridge-Nest
    • Company URL: https://github.com/kraigm/homebridge-nest
    • Country: [Your Country]
    • Size of Company: Individual
  6. Then just agree to the terms and submit
  7. Go to Products and create a new product
  8. Fill in:
    • Product Name: HomeBridge
    • Description: Open source project to provide HomeKit integration
    • Categories: HomeAutomation
    • Support URL: https://github.com/kraigm/homebridge-nest
    • Redirect URL: [LEAVE BLANK]
    • Permissions (minimum):
      • Enable Thermostat with read/write v4
      • Enable Away with read/write v2
      • Enable Smoke+CO alarm with read v4 (if you ever might want Nest Protect)
      • Enable Camera with read v2 (if you ever might want Nest Cam, motion detection only)
  9. Now you should have a product. Now locate the Keys section on the right of your product's page
  10. Copy the Product ID to your HomeBridge config as the clientId in the Nest config
  11. Copy the Product Secret to your HomeBridge config as the clientSecret in the Nest config
  12. Navigate to the Authorization URL
  13. Accept the terms and copy the Pin Code to your HomeBridge config as the code in the Nest config
  14. Run HomeBridge once (do not include the token in the config at this time) and you should find a log that says something like "CODE IS ONLY VALID ONCE! Update config to use {'token':'c.5ABsTpo88k5yfNIxZlh...'} instead." Copy the c.5ABsTpo88k5yfNIxZlh... portion to your HomeBridge config as the token in the Nest config
  15. You should be able to restart HomeBridge and it should succeed with the new token.

After that you will be FINALLY done (Huzzah!). If the token is working correctly, you no longer NEED the other three configs (clientId, clientSecret, and code) nor the original username and password from the legacy system (but you can keep them around if you wish, they will be ignored).

Configuration

Configuration sample:

"platforms": [
   	{
   		"platform": "Nest",
   		
   		"token" : "c.5ABsTpo88k5yfNIxZlh...",
   		
   		"clientId": "developer client id",
   		"clientSecret": "developer client secret.",
   		"code": "Pin Code",
   		
   		"username" : "username",
   		"password" : "password"
   	}
   ],

Fields:

  • "platform": Must always be "Nest" (required)

  • "token": The only (and final) authentication piece you need to use the new API (required for new api, after determined)

  • "clientId": Can be anything (required for new api, if token not yet determined)

  • "clientSecret": Can be anything (required for new api, if token not yet determined)

  • "code": Can be anything (required for new api if trying to determine token)

Legacy Fields:

  • "username": Nest login username, same as app (required for legacy api)
  • "password": Nest login password, same as app (required for legacy api)