chrisjshull / homebridge-nest

Nest plugin for HomeBridge
699 stars 112 forks source link

cookies as per instruction gives me error. #573

Closed Wirepower closed 1 year ago

Wirepower commented 1 year ago
    "platform": "Nest",
    "googleAuth": {
        "issueToken": "https://accounts.google.com/o/oauth2/iframerpc?action=issueToken&response_type=token id_token&login_hint=AJDLj6LQu-SMCQLMJfOUep6S7tCemOhanOAsLbTxuDw2ZKfYRlZq4juKm021xOMbZFk90zams6mqsnAMk4KMCF-Z6490DriAVA&client_id=733249279890-44tchle2kaa9afr5v9ov7jbuojfr9lrq.apps.googleusercontent.com&origin=https://home.nest.com&scope=openid profile email https://www.googleapis.com/auth/nest-account&ss_domain=https://home.nest.com&include_granted_scopes=true",
        "cookies": "__Secure-3PSID=Pgjx79L80ZM4FCAzYtZq2rdmXDh00PSQOhL9jPaAkZJFsxMk-G6JoTcRT0UNq4knf_tDXQ.; __Secure-3PAPISID=D80-SKn5cKBCSQJE/Adj4YZcXF8ctNO1BY; NID=511=ETwxtba107ZqolsjicMFfkXshIs3087rjNwtXgfvYJtU4tMVsC49FNoGG88z0gKa2xhLfbr7ovv5LVV1qPeyLaQ0CVssRxM5RjjSNr5UTqyy0aSd6LIdohkFpLth1PA9HEFYV_5WBvFMRlNU7LdzwyaGnUMvGpYdCcFvgrwRTToT1r6HaDImzoYgXKB7wQxEXQeIgCAckg; __Host-3PLSID=s.AU|s.youtube:Pgjx74OObq99CanIijXtBWOhAIZbMwAiuxlLZg5s7euKMy3boBwEnQ0kXGJuqV5h6upm5Q.; __Secure-3PSIDCC=AEf-XMTYl4pJJ_HqKcyyAVLHY7rKYlkwTQEyCRaaL5rwu6c7jldJPl89JXjh0Fz20uiZ3sNarh"
    },

Above I have changed some characters in token/cookie.

Pasting the above in the Config, gives me a invalid JSON. Highlighted yellow is "platform": :googleAuth": "cookies":

says "incorrect type. Expected "object". What am i doing wrong?

Wirepower commented 1 year ago

ok so i seem to got it but i it wont authenticate. I get: [17/10/2022, 3:25:42 pm] [Nest] Auth failed: access token specified in Homebridge configuration rejected [17/10/2022, 3:25:42 pm] [Nest] Unable to authenticate with Google/Nest. [17/10/2022, 3:25:42 pm] [Nest] NOTE: Because we couldn't connect to the Nest service, your Nest devices in HomeKit will not be responsive.

adriancable commented 1 year ago

Paste your whole config, please.

Wirepower commented 1 year ago

Hi Adrian, thanks for prompt response, so i manged to get config file working. but nest wont authenitcate: [17/10/2022, 3:25:42 pm] [Nest] Auth failed: access token specified in Homebridge configuration rejected [17/10/2022, 3:25:42 pm] [Nest] Unable to authenticate with Google/Nest. [17/10/2022, 3:25:42 pm] [Nest] NOTE: Because we couldn't connect to the Nest service, your Nest devices in HomeKit will not be responsive.

Wirepower commented 1 year ago

This is what i have: { "name": "Nest", "googleAuth": { "issueToken": "https://accounts.google.com/o/oauth2/iframerpc?action=issueToken&response_type=token id_token&login_hint=AJDLj6LQu-SMCQLMJfOUep6S7tCemOhanOAsLbTxuDw2ZKfYRlZq4juKm021xOMbZFk90zams6mqsnAMk4KMCF-Z6490DriAVA&client_id=733249279899-44tchle2kaa9afr5v9ov7jbuojfr9lrq.apps.googleusercontent.com&origin=https://home.nest.com&scope=openid profile email https://www.googleapis.com/auth/nest-account&ss_domain=https://home.nest.com&include_granted_scopes=true", "cookies": "Secure-3PSID=Pgjx79L80ZM4FCAzYtZq2rdmXDh00PSQOhL9jPaAkZJFsxMk-G6JoTcRT0UNq4knf_tDXQ.; __Secure-3PAPISID=D80-SKn5cKBCSQJE/Adj4YZcXF8ctNO1BY; NID=511=ETwxtba107ZqolsjicMFfkXshIs3087rjNwtXgfvYJtU4tMVsC49FNoGG88z0gKa2xhLfbr7ovv5LVV1qPeyLaQ0CVssRxM5RjjSNr5UTqyy0aSd6LIdohkFpLth1PA9HEFYV_5WBvFMRlNU7LdzwyaGnUMvGpYdCcFvgrwRTToT1r6HaDImzoYgXKB7wQxEXQeIgCAckg; Host-3PLSID=s.AU|s.youtube:Pgjx74OObq99CanIijXtBWOhAIZbMwAiuxlLZg5s7euKMy3boBwEnQ0kXGJuqV5h6upm5Q.; __Secure-3PSIDCC=AEf-XMTYl4pJJ_HqKcyyAVLHY7rKYlkwTQEyCRaaL5rwu6c7jldJPl89JXjh0Fz20uiZ3sNarg" }, "platform": "Nest"

adriancable commented 1 year ago

It's missing a } at the end. That can't be your complete config. Please post your complete config.

adriancable commented 1 year ago

OK, thanks. I'll take a look tomorrow and get back to you.

Wirepower commented 1 year ago

awesome, thanks :)

Wirepower commented 1 year ago

ok i think i got it working, seems because its a child bridge, it isnt a matter of just rebooting the child. so i rebooted the whole lot and it seems to have worked. Thanks for your help Adrian :)