potmat / homebridge-google-nest-sdm

A Homebridge plugin for Google Nest devices that uses the Google Smart Device Management API. Supports Cameras, Doorbells, Displays, and Thermostats. Includes support for HomeKit Secure Video.
ISC License
148 stars 17 forks source link

Implement Custom UI to Facilitate Refresh Token Generation #131

Open jvartanian opened 9 months ago

jvartanian commented 9 months ago

Using the Homebridge Custom Plugin UI library, implements a custom config UI that makes it easier to generate refresh tokens.

The new UI requires that the user input a client ID, client secret, SDM project ID, & PubSub subscription. Once these values are present, the user can click the Initiate Google Login button, which will open the Google OAuth URL in a new tab.

Once the user completes the login flow, they can copy the resulting google.com link into the Auth URL text box. A refresh token will then be automatically generated and populated into the config.

Screenshot 2023-12-30 at 9 38 08 AM

Addresses #16

potmat commented 9 months ago

Wow, this is amazing! I’m afraid I’m out of the country for a week or two so I’ll review it as soon as I get back. I really appreciate your contribution making no mistake.

potmat commented 8 months ago

When I open the settings screen on an already configured system I just see this:

image
jvartanian commented 7 months ago

When I open the settings screen on an already configured system I just see this:

image

I'm having a hard time reproducing this issue. I just tested the upgrade path on my mac's homebridge server, and my raspberry pi's, both displayed the custom UI successfully.

Do you see an error toast, or a console log?

potmat commented 6 months ago

Hi @jvartanian, I'm so sorry this hasn't been merged yet. I've been extremely busy with work and life. I haven't forgotten, I promise I'll get to it.