itchannel / fordpass-ha

Fordpass integration for Home Assistant
310 stars 56 forks source link

1.70 Tests #509

Open SquidBytes opened 4 months ago

SquidBytes commented 4 months ago

This is an Issue thread for people who are trying/testing out branch 1.70

Relevant question and answers:

Relevant Wiki's

TerrorSource commented 4 months ago

i've made a PR for version 1.70 to let the plugin create an URL for NL users.

https://github.com/itchannel/fordpass-ha/pull/510

Giancky79 commented 4 months ago

Hi, i'm try to change only part from const.py

REGIONS = {
    "UK&Europe": {
        "region": "1E8C7794-FF5F-49BC-9596-A1E0C86C5B19",
        "locale": "it-IT",
        "locale_short": "ITA", #Temp fix 
        "locale_url": "https://login.ford.it" <-- from app ford open with .com

worked for now , i'm try to open a PR

seebaer1976 commented 4 months ago

hi, which of these two id's is the region id

login.ford.de/4566605f-43a7-400a-946e-89cc9fdb0bd7 or ford_application_id=260ea066-aa5e-4344-995d-b8a3d7dd0fca client_id=89f879a5-4474-413f-a090-46649584706d scope=89f879a5-4474-413f-a090-46649584706d

this is the whole link when I log in normally at ford: https://login.ford.de/4566605f-43a7-400a-946e-89cc9fdb0bd7/B2C_1A_SignInSignUp_de-DE/oauth2/v2.0/authorize?redirect_uri=https%3A%2F%2Fwww.ford.de%2Fmein-ford-account%2F&response_type=code&state=%7B%22policy%22%3A%22email_susi_policy%22%2C%22lang%22%3A%22de_de%22%2C%22state%22%3A%22YWNjb3VudC1kYXNoYm9hcmQ%3D%22%2C%22queryHash%22%3A%22%22%2C%22existingPath%22%3A%22%22%2C%22forwardUrl%22%3A%22%22%7D&client_id=89f879a5-4474-413f-a090-46649584706d&scope=89f879a5-4474-413f-a090-46649584706d%20openid&code_challenge=x_LFTcurVp6rmskPdcaIIiFLY4nIpYOj_MMNpU92lmY&code_challenge_method=S256&ui_locales=de-DE&template_id=Ford-MFA-Authentication&ford_application_id=260ea066-aa5e-4344-995d-b8a3d7dd0fca&country_code=DEU&language_code=de-DE

If it is neither of these, how can I find out the region ID?

Regions in const.py

REGION_OPTIONS = ["UK&Europe", "Australia", "North America & Canada", "Germany"]

and

REGIONS = {
    "Germany": {
        "region": "????????????",
        "locale": "de-DE",
        "locale_short": "DEU", #Temp fix 
        "locale_url": "https://login.ford.de"
    },

in fordpass_new.py :

region_lookup = {
"Germany": "?????????",

and

elif self.region2 == "Germany":
countryheader = "DEU"

would like to try the German login because it is very slow and does not always respond

creedda commented 4 months ago

Hello! In the US here and tried to follow the instructions but getting a "unknown error occurred" when I enter in my token from the developer tools in my browser.

2024-06-02 11:39:30.512 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
File "/usr/local/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
resp = await request_handler(request)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle
resp = await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/aiohttp/web_middlewares.py", line 114, in impl
return await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 92, in security_filter_middleware
return await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 210, in forwarded_middleware
return await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 26, in request_context_middleware
return await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 88, in ban_middleware
return await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/aiohttp_session/__init__.py", line 199, in factory
response = await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 295, in auth_middleware
return await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/headers.py", line 32, in headers_middleware
response = await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/http.py", line 73, in handle
result = await handler(request, **request.match_info)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/decorators.py", line 71, in with_admin
return await func(self, request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 222, in post
return await super().post(request, flow_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper
return await method(view, request, data, *args, **kwargs)
File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 122, in post
result = await self._flow_mgr.async_configure(flow_id, data)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 368, in async_configure
result = await self._async_configure(flow_id, user_input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 414, in _async_configure
result = await self._async_handle_step(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 518, in _async_handle_step
result: _FlowResultT = await getattr(flow, method)(user_input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/fordpass/config_flow.py", line 171, in async_step_token
info = await validate_token(self.hass, user_input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/fordpass/config_flow.py", line 64, in validate_token
results = await hass.async_add_executor_job(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/fordpass/fordpass_new.py", line 116, in generate_tokens
return self.generate_fulltokens(req.json())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/fordpass/fordpass_new.py", line 119, in generate_fulltokens
data = {"idpToken": token["access_token"]}
~~~~~^^^^^^^^^^^^^^^^
KeyError: 'access_token'

Maybe something in the token not being expected is causing the error? DM me if you want me to share anything more confidential.

Or of course if there is anything I can retry let me know.

itchannel commented 4 months ago

Hello! In the US here and tried to follow the instructions but getting a "unknown error occurred" when I enter in my token from the developer tools in my browser.


2024-06-02 11:39:30.512 ERROR (MainThread) [aiohttp.server] Error handling request

Traceback (most recent call last):

File "/usr/local/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request

resp = await request_handler(request)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/local/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle

resp = await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/local/lib/python3.12/site-packages/aiohttp/web_middlewares.py", line 114, in impl

return await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 92, in security_filter_middleware

return await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 210, in forwarded_middleware

return await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 26, in request_context_middleware

return await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 88, in ban_middleware

return await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/local/lib/python3.12/site-packages/aiohttp_session/__init__.py", line 199, in factory

response = await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 295, in auth_middleware

return await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/headers.py", line 32, in headers_middleware

response = await handler(request)

^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/helpers/http.py", line 73, in handle

result = await handler(request, **request.match_info)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/decorators.py", line 71, in with_admin

return await func(self, request, *args, **kwargs)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 222, in post

return await super().post(request, flow_id)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper

return await method(view, request, data, *args, **kwargs)

File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 122, in post

result = await self._flow_mgr.async_configure(flow_id, data)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 368, in async_configure

result = await self._async_configure(flow_id, user_input)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 414, in _async_configure

result = await self._async_handle_step(

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 518, in _async_handle_step

result: _FlowResultT = await getattr(flow, method)(user_input)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/config/custom_components/fordpass/config_flow.py", line 171, in async_step_token

info = await validate_token(self.hass, user_input)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/config/custom_components/fordpass/config_flow.py", line 64, in validate_token

results = await hass.async_add_executor_job(

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run

result = self.fn(*self.args, **self.kwargs)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/config/custom_components/fordpass/fordpass_new.py", line 116, in generate_tokens

return self.generate_fulltokens(req.json())

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

File "/config/custom_components/fordpass/fordpass_new.py", line 119, in generate_fulltokens

data = {"idpToken": token["access_token"]}

~~~~~^^^^^^^^^^^^^^^^

KeyError: 'access_token'

Maybe something in the token not being expected is causing the error? DM me if you want me to share anything more confidential.

Or of course if there is anything I can retry let me know.

Can I confirm the token you are entering into the box starts with fordpass://

itchannel commented 4 months ago

hi,

which of these two id's is the region id

login.ford.de/4566605f-43a7-400a-946e-89cc9fdb0bd7 or

ford_application_id=260ea066-aa5e-4344-995d-b8a3d7dd0fca

client_id=89f879a5-4474-413f-a090-46649584706d

scope=89f879a5-4474-413f-a090-46649584706d

this is the whole link when I log in normally at ford:

https://login.ford.de/4566605f-43a7-400a-946e-89cc9fdb0bd7/B2C_1A_SignInSignUp_de-DE/oauth2/v2.0/authorize?redirect_uri=https%3A%2F%2Fwww.ford.de%2Fmein-ford-account%2F&response_type=code&state=%7B%22policy%22%3A%22email_susi_policy%22%2C%22lang%22%3A%22de_de%22%2C%22state%22%3A%22YWNjb3VudC1kYXNoYm9hcmQ%3D%22%2C%22queryHash%22%3A%22%22%2C%22existingPath%22%3A%22%22%2C%22forwardUrl%22%3A%22%22%7D&client_id=89f879a5-4474-413f-a090-46649584706d&scope=89f879a5-4474-413f-a090-46649584706d%20openid&code_challenge=x_LFTcurVp6rmskPdcaIIiFLY4nIpYOj_MMNpU92lmY&code_challenge_method=S256&ui_locales=de-DE&template_id=Ford-MFA-Authentication&ford_application_id=260ea066-aa5e-4344-995d-b8a3d7dd0fca&country_code=DEU&language_code=de-DE

If it is neither of these, how can I find out the region ID?

Regions in const.py


REGION_OPTIONS = ["UK&Europe", "Australia", "North America & Canada", "Germany"]

and

REGIONS = {

    "Germany": {

        "region": "????????????",

        "locale": "de-DE",

        "locale_short": "DEU", #Temp fix 

        "locale_url": "https://login.ford.de"

    },

in fordpass_new.py :


region_lookup = {

"Germany": "?????????",

and

elif self.region2 == "Germany":

countryheader = "DEU"

would like to try the German login because it is very slow and does not always respond

Leave the region id as the uk/Europe one, just change the country codes.

Also that login string you showed isn't for the fordpass app so the token won't work. It needs to have a callback_url as fordpass://token

creedda commented 4 months ago

Can I confirm the token you are entering into the box starts with fordpass://

Yes, i can confirm that.

Just for fun I tried entering just the token and not the full URL and I got a validation error. (a different error than I am seeing)

crslen commented 4 months ago

It took me a couple of attempts, but I was successfully able to get the token and add my vehicle to HA for the US region.

DougSisk commented 4 months ago

I had to delete my original vehicle device to get it to work. New region config doesn't line up with the old and I didn't see a way to change that on the existing device.

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 584, in async_setup
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/__init__.py", line 65, in async_setup_entry
    coordinator = FordPassDataUpdateCoordinator(hass, user, password, vin, region, update_interval, 1)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/__init__.py", line 189, in __init__
    self.vehicle = Vehicle(user, password, vin, region, save_token, config_path)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 64, in __init__
    self.region = REGIONS[region]["region"]
                  ~~~~~~~^^^^^^^^
KeyError: 'North America & Canada'
creedda commented 4 months ago

Another error I am seeing:

2024-06-03 18:12:31.681 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 92, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 210, in forwarded_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 26, in request_context_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 88, in ban_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp_session/__init__.py", line 199, in factory
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 295, in auth_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/headers.py", line 32, in headers_middleware
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/http.py", line 73, in handle
    result = await handler(request, **request.match_info)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/decorators.py", line 71, in with_admin
    return await func(self, request, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 222, in post
    return await super().post(request, flow_id)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper
    return await method(view, request, data, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 122, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 368, in async_configure
    result = await self._async_configure(flow_id, user_input)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 414, in _async_configure
    result = await self._async_handle_step(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 518, in _async_handle_step
    result: _FlowResultT = await getattr(flow, method)(user_input)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 171, in async_step_token
    info = await validate_token(self.hass, user_input)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 64, in validate_token
    results = await hass.async_add_executor_job(
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 116, in generate_tokens
    return self.generate_fulltokens(req.json())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 119, in generate_fulltokens
    data = {"idpToken": token["access_token"]}
                        ~~~~~^^^^^^^^^^^^^^^^
KeyError: 'access_token'
tobox commented 4 months ago

I just tested 1.70 in Germany.

The page did not load properly when I selected Europe/UK.

Then, I tried North Ameriaca an everything worked properly, except that all text messages appeared in dutch language!

But the integration seems to be OK now.

mlewanca commented 4 months ago

Tested with North America and Canada.

Link does not load. It seems that it wants to open the App.

https://login.ford.com/4566605f-43a7-400a-946e-89cc9fdb0bd7/B2C_1A_SignInSignUp_EN-AU/oauth2/v2.0/authorize?redirect_uri=fordapp://userauthorized&response_type=code&max_age=3600&code_challenge=dayR7BUtjUozeXFJMsjJppl22FEXal_FVKwRJlz3oFI&code_challenge_method=S256&scope=%2009852200-05fd-41f6-8c21-d36d3497dc64%20openid&client_id=09852200-05fd-41f6-8c21-d36d3497dc64&ui_locales=EN-AU&language_code=EN-AU&country_code=AUS&ford_application_id=71A3AD0A-CF46-4CCF-B473-FC7FE5BC4592

BluThunder2k commented 4 months ago

I've copied the files over and am trying to get the token to work with a US login. I get the developer tool string - but mine is "fordapp://userauthorized/?code=" and the string. I get unknown error occurred as another did above. No where in the network tab on the URL I am given has "fordpass". Anyone have any suggestions?

I as well have the " KeyError: 'access_token' " entry in my logs (with all the other entries matching what's been posted above).

KrickGregory commented 4 months ago

If I try with my European login I get a link for the token that won't load in Chrome if I set it to European. But if in ha I put it to USA I get a link that loads but then I get the error user not known in dev tools.

This is what I get if I set Europe in ha with 1.7 The resource https://prodb2cuicontentdelivery-d0bbevfjaxfmedda.z01.azurefd.net/b2cui/assets/fonts/FordAntenna-Regular.woff2 was preloaded using link preload but not used within a few seconds from the window's load event. Please make sure it has an appropriate as value and it is preloaded intentionally.

This is what I get if I set it to USA in ha. Failed to launch 'fordapp://userauthorized/?error=server_error&error_description=AADB2C90002%3a+The+CORS+resource+%27https%3a%2f%2fprodb2cuicontentdelivery-d0bbevfjaxfmedda.z01.azurefd.net%2fb2cui%2fui%2fford%2fEN-IE%2funified.html%3fver%3d20240111.4%26SessionId%3d7d1c65c0-f71b-4021-bb67-16c59041f857%26InstanceId%3dc990bb7a-51f4-439b-bd36-9c07fb1041c0%27+returned+a+404+not+found.%0d%0aCorrelation+ID%3a+7d1c65c0-f71b-4021-bb67-16c59041f857%0d%0aTimestamp%3a+2024-06-04+17%3a42%3a40Z%0d%0a' because the scheme does not have a registered handler.

I'm not an IT guy so just tried for what I know and wanted to Share so it maybe can help.

Thanks for your efforts. Great work.

ghostbitmeta commented 4 months ago

My sensors don't seem to update unless I manually reload the integration (had not updated in a week)

mlewanca commented 4 months ago

Tested with North America and Canada.

Link does not load. It seems that it wants to open the App.

https://login.ford.com/4566605f-43a7-400a-946e-89cc9fdb0bd7/B2C_1A_SignInSignUp_EN-AU/oauth2/v2.0/authorize?redirect_uri=fordapp://userauthorized&response_type=code&max_age=3600&code_challenge=dayR7BUtjUozeXFJMsjJppl22FEXal_FVKwRJlz3oFI&code_challenge_method=S256&scope=%2009852200-05fd-41f6-8c21-d36d3497dc64%20openid&client_id=09852200-05fd-41f6-8c21-d36d3497dc64&ui_locales=EN-AU&language_code=EN-AU&country_code=AUS&ford_application_id=71A3AD0A-CF46-4CCF-B473-FC7FE5BC4592

This solved my issue:

https://github.com/itchannel/fordpass-ha/issues/488#issuecomment-2142888831

tunisiano187 commented 4 months ago

OK, tryied your solution, but ... i received this error fordapp://userauthorized/?error=server_error&error_description=AADB2C90002%3a+The+CORS+resource+%27https%3a%2f%2fprodb2cuicontentdelivery-d0bbevfjaxfmedda.z01.azurefd.net%2fb2cui%2fui%2fford%2fEN-IE%2funified.html%3fver%3d20240111.4%26SessionId%3d74dec7b6-c56e-44fb-9d64-f1590edd9920%26InstanceId%3dc990bb7a-51f4-439b-bd36-9c07fb1041c0%27+returned+a+404+not+found.%0d%0aCorrelation+ID%3a+74dec7b6-c56e-44fb-9d64-f1590edd9920%0d%0aTimestamp%3a+2024-06-06+19%3a51%3a19Z%0d%0a

mlewanca commented 4 months ago

My sensors don't seem to update unless I manually reload the integration (had not updated in a week)

I seem to have the same issue. Its not updating.

chrestme commented 4 months ago

Another error I am seeing:

2024-06-03 18:12:31.681 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 92, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 210, in forwarded_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 26, in request_context_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 88, in ban_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp_session/__init__.py", line 199, in factory
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 295, in auth_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/headers.py", line 32, in headers_middleware
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/http.py", line 73, in handle
    result = await handler(request, **request.match_info)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/decorators.py", line 71, in with_admin
    return await func(self, request, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 222, in post
    return await super().post(request, flow_id)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper
    return await method(view, request, data, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 122, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 368, in async_configure
    result = await self._async_configure(flow_id, user_input)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 414, in _async_configure
    result = await self._async_handle_step(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 518, in _async_handle_step
    result: _FlowResultT = await getattr(flow, method)(user_input)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 171, in async_step_token
    info = await validate_token(self.hass, user_input)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 64, in validate_token
    results = await hass.async_add_executor_job(
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 116, in generate_tokens
    return self.generate_fulltokens(req.json())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 119, in generate_fulltokens
    data = {"idpToken": token["access_token"]}
                        ~~~~~^^^^^^^^^^^^^^^^
KeyError: 'access_token'

I'm getting this same error. I tried rebuilding the POST request directly in a python interpreter to see what the response code and text were. I got a 400 response, and the following text: >>> req.text '{"error":"invalid_grant","error_description":"AADB2C90090: The provided JWE is not a valid 5 segment token.\\r\\nCorrelation ID: 7a7d936c-84b1-480a-b152-e9ed4eaf4f24\\r\\nTimestamp: 2024-06-07 15:54:23Z\\r\\n"}'

mapero commented 3 months ago

OK, tryied your solution, but ... i received this error fordapp://userauthorized/?error=server_error&error_description=AADB2C90002%3a+The+CORS+resource+%27https%3a%2f%2fprodb2cuicontentdelivery-d0bbevfjaxfmedda.z01.azurefd.net%2fb2cui%2fui%2fford%2fEN-IE%2funified.html%3fver%3d20240111.4%26SessionId%3d74dec7b6-c56e-44fb-9d64-f1590edd9920%26InstanceId%3dc990bb7a-51f4-439b-bd36-9c07fb1041c0%27+returned+a+404+not+found.%0d%0aCorrelation+ID%3a+74dec7b6-c56e-44fb-9d64-f1590edd9920%0d%0aTimestamp%3a+2024-06-06+19%3a51%3a19Z%0d%0a

Same here.

Koosdezwart commented 3 months ago

1.70 works for three days in row. Netherlands.

chrestme commented 3 months ago

Another error I am seeing:

2024-06-03 18:12:31.681 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 92, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 210, in forwarded_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 26, in request_context_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 88, in ban_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp_session/__init__.py", line 199, in factory
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 295, in auth_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/headers.py", line 32, in headers_middleware
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/http.py", line 73, in handle
    result = await handler(request, **request.match_info)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/decorators.py", line 71, in with_admin
    return await func(self, request, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 222, in post
    return await super().post(request, flow_id)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper
    return await method(view, request, data, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 122, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 368, in async_configure
    result = await self._async_configure(flow_id, user_input)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 414, in _async_configure
    result = await self._async_handle_step(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 518, in _async_handle_step
    result: _FlowResultT = await getattr(flow, method)(user_input)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 171, in async_step_token
    info = await validate_token(self.hass, user_input)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 64, in validate_token
    results = await hass.async_add_executor_job(
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 116, in generate_tokens
    return self.generate_fulltokens(req.json())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 119, in generate_fulltokens
    data = {"idpToken": token["access_token"]}
                        ~~~~~^^^^^^^^^^^^^^^^
KeyError: 'access_token'

I'm getting this same error. I tried rebuilding the POST request directly in a python interpreter to see what the response code and text were. I got a 400 response, and the following text: >>> req.text '{"error":"invalid_grant","error_description":"AADB2C90090: The provided JWE is not a valid 5 segment token.\\r\\nCorrelation ID: 7a7d936c-84b1-480a-b152-e9ed4eaf4f24\\r\\nTimestamp: 2024-06-07 15:54:23Z\\r\\n"}'

Another error I am seeing:

2024-06-03 18:12:31.681 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
    resp = await request_handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle
    resp = await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp/web_middlewares.py", line 114, in impl
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 92, in security_filter_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 210, in forwarded_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 26, in request_context_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 88, in ban_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/aiohttp_session/__init__.py", line 199, in factory
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 295, in auth_middleware
    return await handler(request)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/headers.py", line 32, in headers_middleware
    response = await handler(request)
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/http.py", line 73, in handle
    result = await handler(request, **request.match_info)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/decorators.py", line 71, in with_admin
    return await func(self, request, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 222, in post
    return await super().post(request, flow_id)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper
    return await method(view, request, data, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 122, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 368, in async_configure
    result = await self._async_configure(flow_id, user_input)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 414, in _async_configure
    result = await self._async_handle_step(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 518, in _async_handle_step
    result: _FlowResultT = await getattr(flow, method)(user_input)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 171, in async_step_token
    info = await validate_token(self.hass, user_input)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/config_flow.py", line 64, in validate_token
    results = await hass.async_add_executor_job(
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 116, in generate_tokens
    return self.generate_fulltokens(req.json())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/fordpass/fordpass_new.py", line 119, in generate_fulltokens
    data = {"idpToken": token["access_token"]}
                        ~~~~~^^^^^^^^^^^^^^^^
KeyError: 'access_token'

I'm getting this same error. I tried rebuilding the POST request directly in a python interpreter to see what the response code and text were. I got a 400 response, and the following text: >>> req.text '{"error":"invalid_grant","error_description":"AADB2C90090: The provided JWE is not a valid 5 segment token.\\r\\nCorrelation ID: 7a7d936c-84b1-480a-b152-e9ed4eaf4f24\\r\\nTimestamp: 2024-06-07 15:54:23Z\\r\\n"}'

Update: I tried the login process from a different browser (Chrome) and it worked. I had been using Firefox before.

nexusis7 commented 3 months ago

i've followe the instructions and manually updated to 1.70 but after entering the fordapp code, i just get Unknown error occurred repeatedly. i logged out and signed in again with new fordapp code, same error on home assistant

Opera Snapshot_2024-06-11_190358_homeassistant local

Next9999 commented 3 months ago

Working fin on my end "Canada"

Script to reload /refresh Data is also good :-)

tunisiano187 commented 3 months ago

Maybe we need to add also Belgium (be-fr) .be for it to work for me, (i've tryied to just update the login link copied, with .be, but it didn't work

chrestme commented 3 months ago

i've followe the instructions and manually updated to 1.70 but after entering the fordapp code, i just get Unknown error occurred repeatedly. i logged out and signed in again with new fordapp code, same error on home assistant

Opera Snapshot_2024-06-11_190358_homeassistant local

Have you tried using a different browser? Firefox wouldn't work for me, but Chrome did. You can also try using a private browsing/incognito window or clearing cookies/cache.

seebaer1976 commented 3 months ago

I was able to get the token without any problems.

I just noticed that not all sensors are updated for a longer period of time

There are three warnings in the logs:

1: Returning Stale data to prevent unavaliable status 2: Error communicating with FordPass for XXXXXXXXXX and 502 Server Error: Bad Gateway for url: https://api.mps.ford.com/api/expdashboard/v1/details/

navarrolux commented 3 months ago

Hello all. I was finally able to import the 1.70 files and logged in successfully. I have noticed a couple of things:

Nice work with getting it to this point.

Correction: all seems to work as expected.

OwnsJo commented 3 months ago

I uploaded to 1.70 - no issues so far. Appreciate the hard work yall!

totalitarian commented 3 months ago

Is this working for anyone in the united kingdom? the verification URL for me just loads a white page

creedda commented 3 months ago

i've followe the instructions and manually updated to 1.70 but after entering the fordapp code, i just get Unknown error occurred repeatedly. i logged out and signed in again with new fordapp code, same error on home assistant

Opera Snapshot_2024-06-11_190358_homeassistant local

This is the same issue I was having. USA Here.

I had to retry with a edge browser in incognito mode with no extensions.

Got it to work.

Will test things and report back.

Kebo2r commented 3 months ago

First time user here. Just got 1.70 installed. Had no idea this was available so very excited to try it out. Logged in and connected fine. Initially testing shows the remote start working fine but my door status shows open continuously. Also when i hit lock is say "locking" but the result is always unlocked. This is on a 20' F150. Not sure if these are known issues or not.
Also a question while I'm at it. I get a Tire Pressure System status as "Normal operation". The truck breaks those down to individual tire pressures but I'm guessing thats not available in the new API? Thanks for all the work that went into this and if i can help diagnose any kinks let me know!

totalitarian commented 3 months ago

First time user here. Just got 1.70 installed. Had no idea this was available so very excited to try it out. Logged in and connected fine. Initially testing shows the remote start working fine but my door status shows open continuously. Also when i hit lock is say "locking" but the result is always unlocked. This is on a 20' F150. Not sure if these are known issues or not. Also a question while I'm at it. I get a Tire Pressure System status as "Normal operation". The truck breaks those down to individual tire pressures but I'm guessing thats not available in the new API? Thanks for all the work that went into this and if i can help diagnose any kinks let me know!

Same issue, here, vehicle always shows unlocked

totalitarian commented 3 months ago

Is this working for anyone in the united kingdom? the verification URL for me just loads a white page

I managed to get this working but had to login via USA rather than UK

knuser666 commented 3 months ago

i get this error and some others aswell i dont even see the login in page :( any idea

Unchecked runtime.lastError: Could not establish connection. Receiving end does not exist.

ripple7511 commented 3 months ago

Screenshot 2024-06-19 at 11 00 55 AM I get a "No vehicles on account or all are configured already" error. I've removed the HACS ford integration, deleted the folder from the customer_components folder... any other suggestions?

EDIT: Looks like I disabled the 6.8* version without removing the vehicle, and then removed the integration somehow without deleting the vehicle. Had to go into the .storage/core.config_entries and manually enable, and then remove the vehicle. Integration worked like a charm immediately after going through the setup process once more.

zinkscott commented 3 months ago

First time user here. Just got 1.70 installed. Had no idea this was available so very excited to try it out. Logged in and connected fine. Initially testing shows the remote start working fine but my door status shows open continuously. Also when i hit lock is say "locking" but the result is always unlocked. This is on a 20' F150. Not sure if these are known issues or not. Also a question while I'm at it. I get a Tire Pressure System status as "Normal operation". The truck breaks those down to individual tire pressures but I'm guessing thats not available in the new API? Thanks for all the work that went into this and if i can help diagnose any kinks let me know!

Do you see each tire as an attribute, perhaps?

image
harfordhawk commented 3 months ago

I have tried numerous times US version, only get a 'loading' on webpage but it never does anything else.. no way to get token, tried numerous browsers

WantedLange commented 3 months ago

I have tried numerous times US version, only get a 'loading' on webpage but it never does anything else.. no way to get token, tried numerous browsers

It should get stuck at loading. You find tokens in the network tab as descriped in the documentation

SquidBytes commented 3 months ago

I have tried numerous times US version, only get a 'loading' on webpage but it never does anything else.. no way to get token, tried numerous browsers

Wiki Page

❗NOTE: The website will not fully load. The login page will just continue to spin. It is at this point you are able to obtain the code by using the browser tools.

chkr1011 commented 3 months ago

I use latest 1.70 code and it works perfectly. I am located in Germany but selected US as the location because Europe does not work at all (a not working URL is generated in the login screen).

tunisiano187 commented 3 months ago

Maybe you could replace fordapp://userauthorized by the https://my.home-assistant.io/redirect/config_flow_start?domain=fordpass ?

Sarke commented 3 months ago

Maybe you could replace fordapp://userauthorized by the https://my.home-assistant.io/redirect/config_flow_start?domain=fordpass ?

That's probably not a good idea, because that would be sent to Ford and they would know we're not using the app like we're supposed to.

WantedLange commented 3 months ago

Seems like I have a problem with odometer not updating

LuckyTitan commented 3 months ago

I use latest 1.70 code and it works perfectly. I am located in Germany but selected US as the location because Europe does not work at all (a not working URL is generated in the login screen).

i can fully confirm this. does indeed work in germany using the US as the location. there are no issues with any values, everything keeps updating regularly. unfortunately however my mach E shows me a battery state of health of only 89% after just one year of driving it. bad battery i guess, will have it checked at my dealer.

jvhoof commented 3 months ago

I use latest 1.70 code and it works perfectly. I am located in Germany but selected US as the location because Europe does not work at all (a not working URL is generated in the login screen).

1.70 working fine using Chrome (tried several times with Firefox to copy the location value and received 'Unknown error occured', selected US as location with a car located in Sweden.

YBonline commented 3 months ago

Figured I'd post my experience as well:

I updated to 1.70 branch, hit add vehicle, did the credentials as described and it worked, but said that all vehicles were already added. Tried refreshing and restarting HA but the previous 2, already configured vehicles still did not connect. Decided to delete them and readd it, and first one added no issue. Had to do login flow again, and the Ford page refused to load. Did it in incognito and it worked prefect. Decided to just try hitting to add one more vehicle, and again the page refused to load unless I closed my incognito and reopened it (presumably flushing cookies/cache). Obviously, especially given the more complicated login flow, it'd be nice if we could add all vehicles with one login flow. (Or could I have copied the URL from the first go around along with the token and not really went through that twice? Probably should have tried that in hindsight, and if that works it should be added to the docs)

Zerobyte1 commented 3 months ago

I finally got around to doing the 1.70 update.

I could not get the token if i was to say "UK/Europe" but worked first time when i changed it to "America"

Been working for 4 days now.

tunisiano187 commented 3 months ago

I finally got around to doing the 1.70 update.

I could not get the token if i was to say "UK/Europe" but worked first time when i changed it to "America"

Been working for 4 days now.

Worked for me too. Thank you

Game2Freak commented 3 months ago

Just managed to update to 1.70. Thought I would come on here to say that all I did was update and everything seems to be working normally even though I havent logged in and added the new fordapp:// token.