Authentication issues
Describe the issue
Hi,
just started freshly with homeassistant, through velbus signum, but every time I try to login, it gives authentication error.
Error log Logger: bimmer_connected.api.authentication Bron: components/bmw_connected_drive/config_flow.py:54 Eerst voorgekomen: 20:52:21 (1 gebeurtenissen) Laatst gelogd: 20:52:21
MyBMWAuthError due to HTTPStatusError: invalid_client - Client authentication failed (e.g., login failure, unknown client, no client authentication included or unsupported authentication method)
Expected behavior
Login
Which Home Assistant version are you using?
core on signum
What was the last working version of Home Assistant Core?
No response
What is your region?
Rest of world
MyBMW website
- [x] I can still successfully login to the BMW MyBMW website and the car status is available there.
- [x] I have MyBMW enabled for my vehicle.
Number of cars
- [ ] I have 2 or more cars linked to the MyBMW account.
- [ ] I have a Mini vehicle linked to my account.
- [ ] I have a Toyota Supra vehicle linked to my account.
Output of bimmer_connected fingerprint
Anything in the logs that might be useful for us?
Additional information
No response
What Core version are you using exactly (settings > about)? Before 2024.12 an API change on BMW side broke the integration.
2024.12 am I using.
I have the same issue since February. Same version, same message.
I can't log in either, I don't get an option to get any captcha info (uk based)
Having the same error when running via Python. I'm sure the credentials are correct and the captcha code was fresh each time too.
account = MyBMWAccount(BMW_USERNAME, BMW_PASSWORD, Regions.REST_OF_WORLD, hcaptcha_token=CAPTCHA) asyncio.run(account.get_vehicles())
MyBMWAuthError due to HTTPStatusError: invalid_client - Client authentication failed (e.g., login failure, unknown client, no client authentication included or unsupported authentication method)
httpx.HTTPStatusError: Client error '401 Unauthorized' for url 'https://customer.bmwgroup.com/gcdm/oauth/authenticate' For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/401
I get the same issue with trying to use the CLI:
$ bimmerconnected status --captcha-token [token] [uname] [passwd] north_america
MyBMWAuthError due to HTTPStatusError: invalid_client - Client authentication failed (e.g., login failure, unknown client, no client authentication included or unsupported authentication method)
MyBMWAuthError: HTTPStatusError: invalid_client - Client authentication failed (e.g., login failure, unknown client, no client authentication included or unsupported authentication method)
I'm experience similar issue - 401 Unauthorized - I had same thing for couple of weeks in a row on Monday. (I also see ERROR: MyBMWCaptchaMissingError: Missing hCaptcha token for login.) Getting a new captcha solves it ... for a week. Are the capthas getting invalidated more often ? (new BMW policy??) PS I also connect to a MiniCooper SE -> works fine ...
Personally seeing this error:
Logger: homeassistant.config_entries
Source: config_entries.py:781
First occurred: 3:37:07 PM (1 occurrences)
Last logged: 3:37:07 PM
Config entry '[email protected]' for bmw_connected_drive integration could not authenticate: Login requires captcha validation
and
Logger: bimmer_connected.api.authentication
Source: components/bmw_connected_drive/coordinator.py:80
First occurred: 3:37:07 PM (1 occurrences)
Last logged: 3:37:07 PM
MyBMWAuthError due to HTTPStatusError: invalid_request - The request is missing a required parameter, includes an unsupported parameter value (other than grant type), repeats a parameter, includes multiple credentials, utilizes more than one mechanism for authenticating the client, or is otherwise malformed
and
Logger: bimmer_connected.api.client
Source: components/bmw_connected_drive/coordinator.py:80
First occurred: 3:36:56 PM (1 occurrences)
Last logged: 3:36:56 PM
MyBMWAPIError due to HTTPStatusError: Internal Server Error
Happens upon reboot pretty much every time. Reauthorizing (Password in HA and then copying captcha token from https://bimmer-connected.readthedocs.io/en/stable/captcha/north_america.html fixes the issue.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.