mrlt8 / docker-wyze-bridge

WebRTC/RTSP/RTMP/LL-HLS bridge for Wyze cams in a docker container
GNU Affero General Public License v3.0
2.58k stars 158 forks source link

[bug?] 400 Client Error: Bad Request for url: https://auth-prod.api.wyze.com/user/login #675

Closed keawepoo closed 1 year ago

keawepoo commented 1 year ago

Yes I have entered my username and password. Ive also rebooted the container and even rolled it back.

2023/01/16 19:44:33 [WyzeBridge] 🚀 STARTING DOCKER-WYZE-BRIDGE v1.11.1
2023/01/16 19:44:33 [WyzeBridge] 🔍 Could not find local cache for 'user'
 * Serving Flask app 'frontend'
2023/01/16 19:44:33 [WyzeBridge] 🔍 Could not find local cache for 'auth'
2023/01/16 19:44:33 [WyzeBridge] ☁️ Fetching 'auth' from the Wyze API...
 * Debug mode: off
2023/01/16 19:44:33 [WyzeBridge] WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.
 * Running on all addresses (0.0.0.0)
 * Running on http://127.0.0.1:5000
 * Running on http://172.27.0.2:5000
2023/01/16 19:44:33 [WyzeBridge] Press CTRL+C to quit
2023/01/16 19:44:34 [WyzeBridge] 🚷 Invalid credentials?
2023/01/16 19:44:34 [WyzeBridge] 400 Client Error: Bad Request for url: https://auth-prod.api.wyze.com/user/login
2023/01/16 19:45:06 [WyzeBridge] 192.168.1.100 - - [16/Jan/2023 19:45:06] "GET / HTTP/1.1" 200 -
2023/01/16 19:45:06 [WyzeBridge] 192.168.1.100 - - [16/Jan/2023 19:45:06] "GET /static/site.css HTTP/1.1" 304 -
2023/01/16 19:45:06 [WyzeBridge] 192.168.1.100 - - [16/Jan/2023 19:45:06] "GET /static/site.js HTTP/1.1" 304 -
2023/01/16 19:45:49 [WyzeBridge] ☁️ Fetching 'auth' from the Wyze API...
2023/01/16 19:45:49 [WyzeBridge] 🚷 Invalid credentials?
2023/01/16 19:45:49 [WyzeBridge] 400 Client Error: Bad Request for url: https://auth-prod.api.wyze.com/user/login
2023/01/16 19:47:04 [WyzeBridge] ☁️ Fetching 'auth' from the Wyze API...
2023/01/16 19:47:04 [WyzeBridge] 🚷 Invalid credentials?
2023/01/16 19:47:04 [WyzeBridge] 400 Client Error: Bad Request for url: https://auth-prod.api.wyze.com/user/login
RodgerDJr commented 1 year ago

I am getting the same error. I just posted this as a question a few hours ago. It was all working just fine. i wanted to start over and now I am getting the same error.

WYZE has a big launch tomorrow I wonder if they made some changes.

keawepoo commented 1 year ago

Oh? I didnt see your post. Ill link it here too...

Well I know that the container had gotten a update a few hours ago too. https://github.com/mrlt8/docker-wyze-bridge/discussions/674

RodgerDJr commented 1 year ago

I only posted a question as I was not sure if it was something I was doing. I am very new to Docker and this was my first attempt at it. While I had it all working, I wanted to start over and do it again for "practice" and then it would not work. So, I started looking at the logs and saw what you are seeing. I think I check my username and password 10 times.

RodgerDJr commented 1 year ago

I am using Portainer I just deleted everything out and used the "script" they have below and replaced my email and password and it is now working.

Portainer Setup

keawepoo commented 1 year ago

@RodgerDJr thank you... Its funny I did that something before and it didnt work... so I did it again and ya now it does... lol

saman79 commented 1 year ago

This is interesting. I am having the same issue. I know it works trough the Home Assistant implementation but not working on Portainer.

RodgerDJr commented 1 year ago

@saman79 I have it working on Portainer. However I am dropping the cameras about every 5 minutes. I am running Docker on VM and I saw some people saying it is better to have Docker in a Linux Physical Box, I am working on getting a Linux Box up and running so I can install Docker on it.

saman79 commented 1 year ago

@saman79 I have it working on Portainer. However I am dropping the cameras about every 5 minutes. I am running Docker on VM and I saw some people saying it is better to have Docker in a Linux Physical Box, I am working on getting a Linux Box up and running so I can install Docker on it.

hey, I have Portainer running on Pi so it's linux and still not really working :-/

RodgerDJr commented 1 year ago

@saman79 I just finished setting up Ubuntu 22.04 on an old i5-4570 with 4GB and an old 1TB SATA drive. Docker is installed and Portainer is running I added a stack using the Web Configuration with my Wyze user name and password. Started the Stack and it is working. It has only been running for about 10 minutes now but I have not dropped any of the 4 cameras I have. When I was using my Windows VM I was dropping the cameras about every 4 to 5 minutes for at least a minute. So far so good.

saman79 commented 1 year ago

@saman79 I just finished setting up Ubuntu 22.04 on an old i5-4570 with 4GB and an old 1TB SATA drive. Docker is installed and Portainer is running I added a stack using the Web Configuration with my Wyze user name and password. Started the Stack and it is working. It has only been running for about 10 minutes now but I have not dropped any of the 4 cameras I have. When I was using my Windows VM I was dropping the cameras about every 4 to 5 minutes for at least a minute. So far so good.

That is amazing. i'm not having the same luck. is there any changes made to the web configuration text other than user and password?

Did you leave a space between the "=" and the email and password?

RodgerDJr commented 1 year ago

That is the only think I changed was the email and password. No spaces and the =, just how you have it. I have had it up and running for about an hour now and it has not dropped once.

RodgerDJr commented 1 year ago

@saman79 Did you get it working? I just checked and I have not had any drops like I was before when I was using a Windows VM to run Docker.

saman79 commented 1 year ago

@saman79 Did you get it working? I just checked and I have not had any drops like I was before when I was using a Windows VM to run Docker.

I will try using ubuntu instead of linux pi for the OS and will see if that helps

saman79 commented 1 year ago

@saman79 I just finished setting up Ubuntu 22.04 on an old i5-4570 with 4GB and an old 1TB SATA drive. Docker is installed and Portainer is running I added a stack using the Web Configuration with my Wyze user name and password. Started the Stack and it is working. It has only been running for about 10 minutes now but I have not dropped any of the 4 cameras I have. When I was using my Windows VM I was dropping the cameras about every 4 to 5 minutes for at least a minute. So far so good.

That is amazing. i'm not having the same luck. is there any changes made to the web configuration text other than user and password?

Did you leave a space between the "=" and the email and password?

do you have the tutorial for the docker and portainer install on ubuntu? thanks

saman79 commented 1 year ago

@RodgerDJr do you have the tutorial for the docker and portainer install on ubuntu?

thanks

RodgerDJr commented 1 year ago

@saman79 I do. https://docs.docker.com/desktop/install/ubuntu/ https://docs.portainer.io/start/install/server/docker/linux

saman79 commented 1 year ago

@saman79 I do. https://docs.docker.com/desktop/install/ubuntu/ https://docs.portainer.io/start/install/server/docker/linux

thanks @RodgerDJr no luck. tried linux pi, ubuntu (twice) and nothing... very frustrating

RodgerDJr commented 1 year ago

Are you getting everything installed and it is not connecting where is the point of failure?


From: saman79 @.> Sent: Thursday, January 19, 2023 23:37 To: mrlt8/docker-wyze-bridge @.> Cc: Rodger Dill @.>; Mention @.> Subject: Re: [mrlt8/docker-wyze-bridge] [bug?] 400 Client Error: Bad Request for url: https://auth-prod.api.wyze.com/user/login (Issue #675)

@saman79https://github.com/saman79 I do. https://docs.docker.com/desktop/install/ubuntu/ https://docs.portainer.io/start/install/server/docker/linux

thanks @RodgerDJrhttps://github.com/RodgerDJr no luck. tried linux pi, ubuntu (twice) and nothing... very frustrating

— Reply to this email directly, view it on GitHubhttps://github.com/mrlt8/docker-wyze-bridge/issues/675#issuecomment-1397913704, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AL3SUOGQUATPHGYB25SIOBLWTIJAHANCNFSM6AAAAAAT5C22RE. You are receiving this because you were mentioned.Message ID: @.***>

mrlt8 commented 1 year ago

@saman79 Do you by any chance have any special characters like $ or % in your password? If you do, you will need to double them to escape them in docker. e.g. pa$$word would be pa$$$$word.

Some other users were having issues with the production API and had to switch to the beta API for some reason, you could try that with:

- WYZE_BETA_API=True

You could also try switching to the Android API key to see if that helps:

- WYZE_APP_API_KEY=RckMFKbsds5p6QY3COEXc2ABwNTYY0q18ziEiSEm
RodgerDJr commented 1 year ago

@saman79 Did you get it working?

giorgi1324 commented 6 months ago

Huh I bumped into this thread and decided to change Wyze password to something without special characters and I was able to log back in!