You can install our site as a web app on your iOS device by utilizing the Add to Home Screen feature in Safari. Please see this thread for more details on this.
Note: This feature may not be available in some browsers.
My C# logger previously had custom code for authentication. When it stopped working due to the Tesla-side changes, I started updating and got annoyed (and bored) so I switched to TeslaAuth.I’d love some power shell examples....
I'm getting a timeout on the first step. The GET at https://auth.tesla.com/oauth2/v3/authorize doesn't work. I'm setting the header with:I had developed my own and it stopped working after a few weeks. Turned out Set-Cookie was now set-cookie. Making that pattern match case insensitive in the code solved the issue.
I'm getting a timeout on the first step. The GET at https://auth.tesla.com/oauth2/v3/authorize doesn't work. I'm setting the header with:
{"User-Agent": "Mozilla/5.0 (Linux; Android 10; Pixel 3 Build/QQ2A.200305.002; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/85.0.4183.81 Mobile Safari/537.36", "x-tesla-user-agent": "TeslaApp/3.10.9-433/adff2e065/android/10", "X-Requested-With": "com.teslamotors.tesla"}
Sorry for a late reply - I haven't been reading this board very regularly lately.Anyone know how to set the storm watch via API? I see the storm watch endpoint in the cloud api, but not sure what parameters to send in order to enable/disable it.
If you're ok with looking at javascript code, the easiest way that I've found to get started is to unbundle the current Android APK to see what endpoints are supported. The code is a little painful to read because it's clearly machine-generated, but I've been able to decipher what parameters are being passed in most cases.Does anyone know a good path for me to begin to pursue a possible API connection for the Tesla Inverter? The Tesla Inverter does not require a gateway but instead has all the networking capabilities built in to it. I would like to find out if Tesla does or plans to enable API endpoints for the inverters to fetch my solar generation. I would like to use the data + Home Assistant to make a grid of system tied devices and add red/green LEDS to indicate to people in the house if the current solar generation alone is sufficient to power that device.
The inverter does have a web interface, but it is only available when connecting to the Inverter's access point and only right after the inverter has power cycled. Connecting to Tesla Solar Inverter | Tesla Support This only displays configuration information. Other than that the device shows no information when connecting to it on my home's local network.If you're ok with looking at javascript code, the easiest way that I've found to get started is to unbundle the current Android APK to see what endpoints are supported. The code is a little painful to read because it's clearly machine-generated, but I've been able to decipher what parameters are being passed in most cases.
In addition, there probably is a way with a rooted Android device to sniff the network traffic, but it appears like the app does certificate pinning so it was beyond my ability to figure out with my iPhone.
Does the inverter have a local web interface? That would be the other way to get the data if it isn't available from the server.
Is there anywhere where I can find documentation for these APIs - e.g. is there an api to force charging of the power wall from the grid - I assume the storm_mode only enables the storm mode - not starts the chargingSorry for a late reply - I haven't been reading this board very regularly lately.
In case it's still useful, here is what I use to turn storm watch on and off:
endpoint: /energy_sites/<site_id>/storm_mode
payload: {"enabled": true}
(paraphrased from javascript, typos possible)
I'm using this with IFTTT to enable Storm Watch mode for off-peak only.I