WeConnect-python icon indicating copy to clipboard operation
WeConnect-python copied to clipboard

Get all home charging sessions

Open waltster3 opened this issue 3 years ago • 20 comments

I would like to export all home charging sessions to evaluate how much energy was taken from which wallbox and authenticated by which charging card.

So far I am working with the iobroker.vw-connect and iobroker.simple-api adapter. I am requesting the data from a python script using the simple-api REST API. This is not very efficient but was working in a first POC. I would like to get rid of the iobroker dependency providing an exporting possibility that is kind of standalone. It would be great to use the weconnect-python module to handle the VW API. However, I think there is no API yet to return the former home charging sessions . Would it be possible to add it?

waltster3 avatar Jan 25 '22 14:01 waltster3

You mean the data from the Elli Chargers?

tillsteinbach avatar Jan 25 '22 14:01 tillsteinbach

yes

waltster3 avatar Jan 25 '22 15:01 waltster3

Ok, that is a good request, I already had that in mind to allow automatically to connect charging sessions in VWsFriend with the data from WeCharge. That would be the same authentication. The problem for home charging is that I do not have such a charger. So once the groundwork is done I would need some data examples. But First of all I would need some refactoring so. To summarise: I can imagine to implement that but it is a bigger part and will need some time.

tillsteinbach avatar Jan 25 '22 15:01 tillsteinbach

Hi,

we have three ID Chargers with 4 different RFID charging cards. We already generated 300+ records and I would share the data. Is there something else I could contribute (question also relates to source code)?

waltster3 avatar Jan 25 '22 15:01 waltster3

I guess it is also json what is coming from the server. The WeCharge items need a different authentication, thus I will first refactor out the current WeConnect auth, (login, token refresh, ...) in a separate class. Then I can add the auth for the charging. The actual retrieval of the data should be a piece of cake, but it would be helpful to have a sample of the data in json format if you can capture that.

tillsteinbach avatar Jan 25 '22 16:01 tillsteinbach

Short update: I was able to login to WeCharge the first time and fetch some data. I still have a lot of cleanup todo before I can think of integrating it into a release, but a first proof of concept is done.

tillsteinbach avatar Jan 27 '22 22:01 tillsteinbach

I just have the json string coming from io-broker. However, I am not sure if this is the same format than returned by WeCharge.

waltster3 avatar Jan 29 '22 08:01 waltster3

We can have a try. You can anonymize it if it contains personal data.

tillsteinbach avatar Jan 29 '22 08:01 tillsteinbach

Sure!

100 records with anonymized serial numbers, IDs and addresses.

wecharge_anonym.zip

waltster3 avatar Jan 29 '22 08:01 waltster3

super danke! Wird noch ein paar tage dauern, ich muss erst die neue Authentifizierung einbauen, aber ich bin dran versprochen!

tillsteinbach avatar Jan 30 '22 13:01 tillsteinbach

Any update on this? Elli Charger now supports EEBUS and VW Passat GTE is here (still waiting for ID.4...)

Peter1984Git avatar May 31 '22 19:05 Peter1984Git

I have a working example, unfortunately I did not find enough time to finish it yet. I would need one or two days. Unfortunately my real job and family keeps me busy right now. But ist is not forgotten.

tillsteinbach avatar Jun 01 '22 06:06 tillsteinbach

Any update on this? Elli Charger now supports EEBUS and VW Passat GTE is here (still waiting for ID.4...)

Is the EEBUS update finally available? I am waiting for the respective Fota update since 1,5 years meanwhile…

waltster3 avatar Jun 01 '22 09:06 waltster3

Any update on this? Elli Charger now supports EEBUS and VW Passat GTE is here (still waiting for ID.4...)

Is the EEBUS update finally available? I am waiting for the respective Fota update since 1,5 years meanwhile…

Yes, it is. You can install it via VW Connect ID App or wait for Autoupdate.

Peter1984Git avatar Jun 01 '22 19:06 Peter1984Git

I have a working example, unfortunately I did not find enough time to finish it yet. I would need one or two days. Unfortunately my real job and family keeps me busy right now. But ist is not forgotten.

Hi @tillsteinbach have you any news about the ID Chargers?

Schnabel80 avatar Jan 06 '24 08:01 Schnabel80

Unfortunately not. Got even worse with spare time. Sorry.

tillsteinbach avatar Jan 06 '24 08:01 tillsteinbach

Unfortunately not. Got even worse with spare time. Sorry.

we all have the same problems... thank you for your great work!

Schnabel80 avatar Jan 06 '24 08:01 Schnabel80

Could you use the API endpoint from the Volkswagen app? The charging processes are already displayed there.

IMG_34D5AA5A6240-1

ksokol avatar Jan 13 '24 22:01 ksokol

Yes, I was able to get the charging sessions.

tillsteinbach avatar Jan 13 '24 22:01 tillsteinbach

Can you tell us the http endpoint? I'm not familiar with the API yet and I'd like to play around with it.

ksokol avatar Jan 13 '24 22:01 ksokol