[APP][Pro] Tesla Car & Energy - Zero emissions. Zero compromises

@RonnyW Thanks very much, it works now, I have added my car, home, battery and solar panels and they all look good. :grinning_face:

Hi, based on the log I would say the device is still not authorized.
The oAuth token reshesh returns:
401 Unauthorized: {“error”:“login_required”,“error_description”:“The refresh_token is invalid”}

So your device will still show errors if you are using polling and push the refresh button (or use the flow cards) I think.
Can you check polling result?

And: are you using two Tesla accounts (developer/car)? If yes, is the right one used in oAuth popup?

Btw: I also fixed the text issue in device settings.

Hey @RonnyW,

The refresh button didn’t give an error, but it was indeed my login that was the issue. I just assumed that the authentication error was due to the connection to the car and not the login, since I’ve still been able to get sporadic updates of data through the pulling.

Thank you for the quick answer and pointing to the solution!

/Alfred

Based on the rare issues during domain/Homey registration for a Tesla Client-ID I tried to describe some technical details how it works and what should be kept in mind:

If you have further questions, feel free to ask :slight_smile:

Just in case this may be of use to you. PELS Energy Manager | Homey is an app I’ve made for coordinating loads like EV charging, heating and hot water. It can for example reduce charging when the house is approaching a configured power limit, and increase it again when there’s capacity available. It also supports scheduling based on electricity prices and more.

I’ve just added “native” support for Tesla Car & Energy to this app.

Hi, may already have been asked, but have consumed the 5k monthly API allowance in 5 days, not sure where all these requests were used by. Could be the widget? Anyway, is there simple way to stay close to monthly allowances by changing a setting or so?

thanks !

Hi, I rhinl that’s the polling interval set in car device settings.

This setting is a bit outdated and defined for the old API limit. I changed it today that Telemetry is active as default and polling is set to 5min and inactive.

Please activate Telemetry and deactivate polling. Then you are more than safe to keep your limit :smiley:

But… that will take effect from November onwards

Thanks for prompt response Ronny, I have de-activated polling but when I enable Telemetry I get “CONNACK returnCode =5”. Is this because of the limit in the account atm, so I can only do this on 1 November? Or should I do something else?

No, you can’t do anything until November. Only if you want to add a subscription for your Tesla account for some days and pay some €.
At 1st of November, you can activate Telemetry.

Thx Ronny, have increased limit a little and was able to enable Telemetry now. Let’s see whether works again.

Hi Ronny, my link broke when my free credits ran out, I added payment and reduced my polling to 15 mins and tried to repair but it didn’t work, should I reinstall the app? Also I have the test version installed, do I need to install the main version now?

Many Thanks

Kepp the app installed. Testversion is fine.

The API should work again if payment is validated I think (haven’t done this yet). Can you set a limit for payment? Perhaps that’s still at 10€.

And… deactivate polling and activate Telemetry. That’s using less credits and it’s realtime.