[APP][Pro] Mercedes Me App (Release 1.0.3)

OK, so @Kai_Engvik is now up and running. So, there were two things:

  1. Check the Redirect URL in the Mercedes portal is set to https://callback.athom.com/oauth2/callback
  2. Use the repair option in the Homey app to reauthenticate the app.

Hopefully that should get it working again.

3 Likes

Can confirm that it is woking again after running repair. Thank you!

2 Likes

Glad I could be useful :v:t2:

1 Like

I tried to use the “Repair” Button, I’m getting somehow redirected (I do see that the title on top changes) but I never see any content to authenticate/login. Any tipps how to fix this? Redirect URL hast been set to https://callback.athom.com/oauth2/callback and of course I’ve generated a new secret.
EDIT: I’ve just reinstalled the test app, but the same. I don’t see the login webpage. It’s just white
EDIT2: Ok got it, I’ve disabled my WLAN connectivity and used my mobile connection, there I got the mercedes dev login screen. It seems to work now.

Have you entered the new Tokens into the Configure App screen?

Of course yes :-), However it works now, check my “EDIT2” above.

1 Like

Are you using the phone app or the web app?
I have seen issue in the phone app before with display external web pages.

It was exactly such an issue, with the mobile connection on my phone it does work. before I’ve used it always with WLAN.

1 Like

@Adrian_Rockall I’ve a small request, I’m polling the Mercedes REST API on another application every 60s (which should still be below the allowed max polling rate). I do have a car with a pretty small battery, what is the current polling rate? Would it be possible that you either change the default or allow us to set the polling interval withing the app settings?

The polling rate is different for each service so nothing exceeds the limit. Do you know which services your other application is using?

Make sense that every service uses it’s own polling interval.
On mercedes dev it‘s called „Electric Vehicle Status BYOCAR“. I‘m using it to read battery percentage of my car to display it within the application EVCC.

The Homey app polls the electricvehicle container 2 times per hour. This is based on the documentation:

Technical limitations

A minimum time span of 120 seconds between API calls has to be observed per vehicle.

As this is already a low rate it might be a better solution if I have an option to exclude it from the Homey app.

The problem is, if I charge my old hybrid car with full power it is fully loaded after 2h, so there are huge percentage steps in the app if we check the state only twice an hour.
I know the mercedes documentation tells us that the min interval is 120s per REST Calls, but are you sure that this is by car and not by service?
In my other application I’m querying only BYOCAR service, but with 60s interval and I don’t see any warnings or errors…

An other option would probably be to generate separate REST API access keys per service. I don’t think that mercedes really limits the REST API calls per car… either by project or by service. But of course this would have to be tested first…

Unfortunately, I can only go by the documentation as I no longer have a Mercedes to test any changes.
I’m not sure of anything :slight_smile: but the document says per vehicle.
It does however appear that Mercedes have reduce the interval since I wrote that section as it is now 2 minutes instead of 30 minutes, so I would be happy to reduce it to that. However, that could mean the combination of the two apps polling might cause a problem.
When I get a bit of time I will added Advanced Options to allow the polling of each service to be set.

Perfectly fine, if we can set the polling of each service within the advanced settings by ourself we can test shorter intervals - log of your app will tell us what’s going on. Thanks a lot in advance

I’ve a strange issue, everything works except the status of my HV Battery. Please check my screenshot.

Eg. the odometer has been updated 2 hours ago, as well as more or less all the other parameters, but NOT the HV battery. It’s the same values since 12 days, which is not possible. I tried to restart the app as well as to repair the device. It doesn’t update. The issue is only here in the homey app, the mercedes app as well as my other application evcc.io (which polls the same rest api but with other credentials) works as expected. Do you have any clue what’s going on? Of course I can remove the car but that’s only the worst case scenario…

Could you send the log. It’s probably not being sent across for some reasons but I can check that with the log.

Done (1de5bafe-29c1-46bf-90ab-2b9be1a9d90f)

Hmm, OK, that’s not what I expected. For some reason it is showing the EV access is forbidden.
I will have to check to see if Mercedes have changed anything.
Have you ever got the EV data from my app? I’m just wondering if you missed a permission when you setup the connection in the Mercedes poral.