matijse / eufy-ha-mqtt-bridge

Receive Eufy alerts and thumbnails in Home Assistant via MQTT
124 stars 25 forks source link

Region parameter #110

Open vlumikero opened 1 year ago

vlumikero commented 1 year ago

Hi,

Since the Eufy Security Add-on stopped working for a lot of people, I'm back to trying to use this one instead. I know it's not actively maintained, but it's still worth a shot in my opinion.

I can't start the add-on anymore, and I suspect it has to do with the region parameter, that's required these days to log in to the service. Can anyone confirm this suspicion?

I'm getting this in the logs:


debug: ---- EUFY INITIALIZE START ---- {"timestamp":"2023-01-11T18:02:02.467Z"}
debug: ----  Created classes... {"timestamp":"2023-01-11T18:02:02.501Z"}
debug: Refreshing devices... {"timestamp":"2023-01-11T18:02:02.507Z"}
error: Error -- httpService.listDevices Response code 403 (Forbidden) {"name":"HTTPError","timings":{"start":1673460124305,"socket":1673460124307,"lookup":1673460124310,"connect":1673460124334,"secureConnect":1673460124402,"upload":1673460124404,"response":1673460124438,"end":1673460124442,"phases":{"wait":2,"dns":3,"tcp":24,"tls":68,"request":2,"firstByte":34,"download":4,"total":137}},"stack":"HTTPError: Response code 403 (Forbidden)\n    at Request.<anonymous> (/app/node_modules/got/dist/source/as-promise/index.js:117:42)\n    at processTicksAndRejections (internal/process/task_queues.js:93:5)","timestamp":"2023-01-11T18:02:04.472Z"}
debug: ----  Refreshed devices {"timestamp":"2023-01-11T18:02:04.480Z"}
debug: ----  Set up MQTT handler {"timestamp":"2023-01-11T18:02:04.483Z"}
debug: Subscribed to homeassistant/status {"timestamp":"2023-01-11T18:02:05.082Z"}
debug: ----  Connected to MQTT {"timestamp":"2023-01-11T18:02:05.085Z"}
debug: ----  Set up auto discovery {"timestamp":"2023-01-11T18:02:10.106Z"}
info: Credentials found -> reusing them... {"timestamp":"2023-01-11T18:02:10.111Z"}
debug: ----  Retrieved push credentials {"timestamp":"2023-01-11T18:02:10.118Z"}
debug: ----  Started push client {"timestamp":"2023-01-11T18:02:10.379Z"}
error: Error -- httpService.registerPushToken Response code 401 (Unauthorized) {"name":"HTTPError","timings":{"start":1673460130398,"socket":1673460130403,"lookup":1673460130405,"connect":1673460130475,"secureConnect":1673460130610,"upload":1673460130610,"response":1673460130641,"end":1673460130645,"phases":{"wait":5,"dns":2,"tcp":70,"tls":135,"request":0,"firstByte":31,"download":4,"total":247}},"stack":"HTTPError: Response code 401 (Unauthorized)\n    at Request.<anonymous> (/app/node_modules/got/dist/source/as-promise/index.js:117:42)\n    at processTicksAndRejections (internal/process/task_queues.js:93:5)","timestamp":"2023-01-11T18:02:10.657Z"}
debug: ----  Registered push token {"timestamp":"2023-01-11T18:02:10.661Z"}
debug: ----  Retrieved device thumbnails {"timestamp":"2023-01-11T18:02:10.665Z"}
debug: ---- EUFY INITIALIZE DONE! ---- {"timestamp":"2023-01-11T18:02:10.668Z"}
AseKarlsson commented 1 year ago

Hi All, Having the same issue "httpService.listDevices Response code 403 (Forbidden) ", did anyone solve it? I know this Bridge is depricated, but could not get picture and video working on the eufy Security Add-On

AseKarlsson commented 1 year ago

@matijse, is this something you are interested in to look in to, even if your integration sadly is deprecated?

matijse commented 1 year ago

No, I don't think it is relevant to update this, as the alternatives are much better and have more features. (see readme) This integration never had any video, only the handing of push messages into events (and a thumbnail of the last event)

If anybody really wants to give it a shot, there is a PR open #105 to migrate to use eufy-security-client, which is actively maintained. This PR uses a rather old version of eufy-security-client, which probably won't work either. But it might be a starting point to include the newest version of eufy-security-client, which probably would be able to include the region parameter.