joeyhage / homebridge-alexa-smarthome

Connect Alexa devices to HomeKit
MIT License
64 stars 20 forks source link

Unable to authenticate Alexa #15

Closed duckida closed 10 months ago

duckida commented 10 months ago

Describe Your Problem:

I can't get the Amazon cookie because it just leads to a 404 page, http://homebridge.local:2345/www.amazon.com/404 Also it refreshes every few seconds on the 2FA code page.

Logs:

No logs from the Alexa plugin about the issue

Plugin Config:

{
  "devices": [],
            "amazonDomain": "amazon.com",
            "language": "en-US",
            "debug": true,
            "platform": "HomebridgeAlexaSmartHome"
        }

Screenshots:

None

Environment: Raspberry Pi Zero 2

rcoletti116 commented 10 months ago

I saw this too at first. I was getting a SMS code and a notification from the Amazon app to verify the activity. Did you get the Amazon app notification? If so, go back and log in again, try allowing in the Amazon app first when prompted.

sebaslag commented 10 months ago

Same problem here

joeyhage commented 10 months ago

@sebaslag what happened when you followed the steps recommended by rcoletti?

sebaslag commented 10 months ago

I changed Amazon.com instead of .ca and it works now. Yet I am in Canada. But I have a lot of: [8/31/2023, 6:05:18 PM] [HomebridgeAlexaSmartHome] Convecteur - Get cooling temperature - DeviceOffline(ENDPOINT_UNREACHABLE) [8/31/2023, 6:05:18 PM] [HomebridgeAlexaSmartHome] Convecteur - Get heating temperature - DeviceOffline(ENDPOINT_UNREACHABLE) [8/31/2023, 6:05:19 PM] [HomebridgeAlexaSmartHome] Obtained device states from cache [8/31/2023, 6:05:19 PM] [HomebridgeAlexaSmartHome] Obtained device states from cache [8/31/2023, 6:05:19 PM] [HomebridgeAlexaSmartHome] Convecteur - Get heating temperature - DeviceOffline(ENDPOINT_UNREACHABLE) [8/31/2023, 6:05:19 PM] [HomebridgeAlexaSmartHome] Convecteur - Get cooling temperature - DeviceOffline(ENDPOINT_UNREACHABLE)

joeyhage commented 10 months ago

It depends on which your Alexa account is linked to, but glad you were able to connect with Amazon.com. that error means your thermostat device is not connected to Alexa.

If you login to the Alexa app with the same username/password, are you able to see and control the thermostat?

sebaslag commented 10 months ago

Yes it works with Alexa and even in Homekit I can control the temperature and it works but at the same time it tells me that it is not responding.

joeyhage commented 10 months ago

Ah I think I know the issue. I just added thermostat support yesterday so the messages aren’t perfect yet. Those are not an issue - I will clean those up in the next release

sebaslag commented 10 months ago

I disabled the plugin because of these messages: [8/31/2023, 6:15:34 PM] [HomebridgeAlexaSmartHome] Convecteur - Get cooling temperature - InvalidResponse(State not available) [8/31/2023, 6:16:23 PM] [HomebridgeAlexaSmartHome] Convecteur - Get heating temperature - InvalidResponse(State not available) [8/31/2023, 6:57:06 PM] [homebridge-alexa-smarthome] This plugin slows down Homebridge. The read handler for the characteristic 'Target Heating Cooling State' was slow to respond! See https://homebridge.io/w/JtMGR for more info. [8/31/2023, 6:57:06 PM] [homebridge-alexa-smarthome] This plugin slows down Homebridge. The read handler for the characteristic 'Current Temperature' was slow to respond! See https://homebridge.io/w/JtMGR for more info. [8/31/2023, 6:57:06 PM] [homebridge-alexa-smarthome] This plugin slows down Homebridge. The read handler for the characteristic 'Target Temperature' was slow to respond! See https://homebridge.io/w/JtMGR for more info. [8/31/2023, 6:57:06 PM] [homebridge-alexa-smarthome] This plugin slows down Homebridge. The read handler for the characteristic 'Temperature Display Units' was slow to respond! See https://homebridge.io/w/JtMGR for more info. [8/31/2023, 6:57:06 PM] [homebridge-alexa-smarthome] This plugin slows down Homebridge. The read handler for the characteristic 'Cooling Threshold Temperature' was slow to respond! See https://homebridge.io/w/JtMGR for more info. [8/31/2023, 6:57:06 PM] [homebridge-alexa-smarthome] This plugin slows down Homebridge. The read handler for the characteristic 'Heating Threshold Temperature' was slow to respond! See https://homebridge.io/w/JtMGR for more info. [8/31/2023, 6:57:08 PM] [HomebridgeAlexaSmartHome] Convecteur - Get thermostat mode - HttpError(Error getting smart home device state. Reason: Timeout)

joeyhage commented 10 months ago

@sebaslag Someone else reported Timeout errors as well. They were able to fix the issue by explicitly providing the list of device names in the plugin config.

sebaslag commented 10 months ago

I have already specified the name of the device I want and I have this problem.

Le 31 août 2023 à 21:05, Joey Hage @.***> a écrit :

meone else reported Timeout errors as well. They were able to fix the issue by explicitly providing the list of device names in the plugin config.

joeyhage commented 10 months ago

@sebaslag thanks for providing all this information. I have just released a new version of the plugin, v0.1.1, which has two new settings that I hope will help. For your specific case, I would recommend the following settings (screenshot attached).

Screen Shot 2023-09-01 at 3 26 37 PM
joeyhage commented 10 months ago

@sebaslag all the issues you reported have been addressed as of version v0.1.2 of this plugin. Please create a new GitHub issue if you are still having issues with this plugin. Thanks!