Welcome to Tesla Motors Club
Discuss Tesla's Model S, Model 3, Model X, Model Y, Cybertruck, Roadster and More.
Register

Tesla Owner API Tutorial (All you need is your browser)

This site may earn commission on affiliate links.
The "Set Charge Limit" doesn't seem to be working fine. It doesn't matter what percentage I specify, it gets set to 50%. Anyone else had luck with it? I am thinking about creating a simple webpage for my personal use to get/set some basis things the way I like it.

I just tried and was able to confirm that it worked via the Tesla and RegoApp. It def. works.
 
One more data point -- had my X75D uncorked this week and confirmed the perf config to be "P3" since I didn't really feel any difference. Going back to the SC next week to have them do it again. Thanks for the info here!
 
Copy and paste the bellow. Replace the email and password. Should work.

{
"grant_type": "password",
"client_id": "81527cff06843c8634fdc09e8ac0abefb46ac849f38fe1e431c2ef2106796384",
"client_secret": "c7257eb71a564034f9419ee651c7d0e5f7aa6bfbd18bafb5c5c033b093bb2fa3",
"email": "<YOUREMAIL>",
"password": "<YOURPASSWORD>"
}


Im getting the same error when I try to get a token. I tried copying and pasting what you posted and get the same:

BODY

{
"error": "invalid_request",
"error_description": "The request is missing a required parameter, includes an unsupported parameter value, or is otherwise malformed."
}

Does the header have to say something special besides "application/json" ? What about URI parameter?
 
Copy and paste the bellow. Replace the email and password. Should work.

{
"grant_type": "password",
"client_id": "81527cff06843c8634fdc09e8ac0abefb46ac849f38fe1e431c2ef2106796384",
"client_secret": "c7257eb71a564034f9419ee651c7d0e5f7aa6bfbd18bafb5c5c033b093bb2fa3",
"email": "<YOUREMAIL>",
"password": "<YOURPASSWORD>"
}

Thanks for trying to help me. Unfortunately for me, I ended up with the same result, a series of error messages. I’ll just wait until I get my car back to see if I can feel any difference.

Thanks again.
 
Im getting the same error when I try to get a token. I tried copying and pasting what you posted and get the same:

BODY

{
"error": "invalid_request",
"error_description": "The request is missing a required parameter, includes an unsupported parameter value, or is otherwise malformed."
}

Does the header have to say something special besides "application/json" ? What about URI parameter?

Well for the initial Authentication nothing is needed other than the body. It actually in the documentation specifies that it only needs the body and the ContentType thing is part of the Response not the Request. I always add it as a habit really.

So on the Get Token thing as long as you have the body provided as specified above it should work. And it does I just tested it again.
 
It worked for me, verified p3, taking the car to service next week to change to p1, will verify before pick up with this neat tool

Awesome that this help and not so awesome for Tesla Service again. My plan is the same ... the moment someone from the service center even slightly suggests that my car is "uncorcked" I am hitting Tesla API and verifying myself.
 
I can also do a tutorial for PostMan as well but that is way more developer oriented tool and I feel it defeats the purpose of the original tutorial where all you need is a browser.

I do get more solid results with the Postman vs Apiary as it seems Apiary is not 100% reliable with the request portion for some reason.
 
The "Set Charge Limit" doesn't seem to be working fine. It doesn't matter what percentage I specify, it gets set to 50%. Anyone else had luck with it? I am thinking about creating a simple webpage for my personal use to get/set some basis things the way I like it.

I have the same problem. My charge limit was set to 80% in the car. After I also entered 80% in this web program it went to 50%. I also verified that the Tesla IOS app now shows the charge limit set to 50%. All of the other commands that I have tested with this web program have worked fine. I tried changing it to 60% just now and it did not change the setting in the car or on the IOS app. I am getting a "200" response code so the command seems to be accepted by the Tesla server.

By the way, I have a Model S85 2014 and my "perf_config" shows P1.
 
Last edited:
I have the same problem. My charge limit was set to 80% in the car. After I also entered 80% in this web program it went to 50%. I also verified that the Tesla IOS app now shows the charge limit set to 50%. All of the other commands that I have tested with this web program have worked fine. I tried changing it to 60% just now and it did not change the setting in the car or on the IOS app. I am getting a "200" response code so the command seems to be accepted by the Tesla server.

By the way, I have a Model S85 2014 and my "perf_config" shows P1.

Just did it again and can confirm via Postman that it was successful POST request (response -> result: true). However the app does show 50%.