Use of Nissan API with a domotic solution ?

180 views
Skip to first unread message

nicolas britsch

unread,
Jun 3, 2022, 2:23:47 AM6/3/22
to My Leaf; a third party NissanConnect app
Hello 
MyLeaf is very great and thank you for this app !
I would like to get info from my leaf by using http requests, e.g. battery level, etc....
Do you think it is possible ? Could you give me the requests you use in your app to do this ?
thank you !

Fahed Barakat

unread,
Oct 17, 2022, 5:31:43 PM10/17/22
to My Leaf; a third party NissanConnect app
I too would be interested in this. My main usecase for me would be to initiate API calls to my leaf from widgets like kwgtand through macrodroid / tasker for updates every 1hr, 15 minutes when charging at 7kw and 5 minutes when rapid-charging to keep track of charge status.
Thanks 

Bart Crijns

unread,
Oct 17, 2022, 6:24:33 PM10/17/22
to My Leaf; a third party NissanConnect app
I use leaf2mqtt to connect the Leaf to my home automation and control the charger (limit charge to certain preset percentages).
You may need to test a few different versions, because not all of them necessarily work equally well with the different regional Nissan servers.

Fahed Barakat

unread,
Oct 20, 2022, 2:55:51 PM10/20/22
to My Leaf; a third party NissanConnect app
Thanks but I'm no dev so had no clue how to start looking into leaf2mqtt. Cheers thought 

Tobias Westergaard Kjeldsen

unread,
Oct 22, 2022, 3:52:33 PM10/22/22
to My Leaf; a third party NissanConnect app
leaf2mqtt uses my dartnissanconnect library (which My Leaf also uses). dartnissanconnect is basically just a client library which uses an HTTP client internally. I would suggest you try out dartnissanconnect. You find the all you need in that library. It's not very hard to get started. You just need the dart runtime up and running; https://dart.dev/overview. The most "complicated" parts are authentication and stuff related to that. That would be somewhat tedious to do manually using curl etc..  

I don't have time to iron it all out here sorry!

Reply all
Reply to author
Forward
0 new messages