vloschiavo/powerwall2

curl problems

OmegaWolfProjects opened this issue · 1 comments

I had trouble with curl. I got things to work by doing the following:

(1)
curl -s -k -c cookies.txt -X POST https://192.168.1.137/api/login/Basic -H "Content-Type: application/json" -d "{"username": "customer","email": "myemail@hotmail.com","password": "mypassword"}"

(2)
curl -k -b cookies.txt https://192.168.1.137/api/meters/aggregates

Nodejs code being used to grab the Tesla Powerwall2 API data via curl:

http://www.miniaturelinux.com/Tesla-Powerwall2-API.php