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)

Wait ... I spoke too soon ... my car version is 2017.42 so you still might be right ... I guess I would know in the next update :|
I was just about to ask that. It appears to be as of "46" and up. The schema changes were significant enough to break the Dashboard for Tesla application. The developer updated it today to accommodate the newer firmwares.
 
gUSuZFl.jpg

Here's a comparison of the output between 42 and 46.8.
 

Akrion

Member
Aug 16, 2017
56
78
CA
Maybe we should now be looking at ''PT_BMS_ISENSORPROTOCOLNUMBER' has to be greater than 3"
as mentioned in thread #215

Any news on 100D uncorking?
OK where is that value coming from? Which API is returning it?

On the slightly different topic ... can anyone provide API responses for Model X? Do we have documentation similar to the one Tim did for Model X? I would imagine it would have some different API points etc?

Asking since I am trying to experiment with an app and would like to know how generic it could be ... having "only" Model S is a limitation :) ... Any help is appreciated!
 

appleguru

Active Member
Mar 15, 2017
1,027
1,855
MA, US
OK where is that value coming from? Which API is returning it?

On the slightly different topic ... can anyone provide API responses for Model X? Do we have documentation similar to the one Tim did for Model X? I would imagine it would have some different API points etc?

Asking since I am trying to experiment with an app and would like to know how generic it could be ... having "only" Model S is a limitation :) ... Any help is appreciated!

It’s not exposed on the owner API. Is a CAN signal.
 
  • Like
Reactions: Akrion

Jonas_man

Member
Sep 1, 2015
278
129
Helsinki
OK where is that value coming from? Which API is returning it?

On the slightly different topic ... can anyone provide API responses for Model X? Do we have documentation similar to the one Tim did for Model X? I would imagine it would have some different API points etc?

Asking since I am trying to experiment with an app and would like to know how generic it could be ... having "only" Model S is a limitation :) ... Any help is appreciated!
should be the same.

But model 3 must have some new commands as the app can now open and close the trunk
 

appleguru

Active Member
Mar 15, 2017
1,027
1,855
MA, US
Alright, so did a little bit of CAN logging to see if I could find the PT_BMS_iSensorProtocolNumber signal on the powertrain bus.

Looks like it is message ID 532, and the values are static:

Byte Number:
0: PT_BMS_iSensorMajorVersion
1: PT_BMS_iSensorMinorVersion
2: PT_BMS_iSensorProtocolNumber
3: PT_BMS_iSensorReleaseVersion
4-6: PT_BMS_iSensorSerialNumber

Should be possible to read this value from your car using TMSpy or similar CAN logging app and appropriate cable/dongle.

If the above referenced support emails are to be believed, this is the magical component that makes some 75D cars eligible/not eligible for uncorking (a PT_BMS_iSensorProtocolNumber greater than 3 is required for uncorking).

Does anyone know what part this actually is on the car? Perhaps a current sensor somewhere?

Do you know the CAN message that is required to get this information and which CAN bus to use?

75 and 75D variants increased performance from July 1st - software and hardware improvements?
 

ccdisce

EBISU like
Sep 10, 2014
234
118
Georgia USA
applguru,

Logged this from the CAN3 bus yesterday for ID 532

Byte Number:
0: PT_BMS_iSensorMajorVersion 0x01
1: PT_BMS_iSensorMinorVersion 0x03
2: PT_BMS_iSensorProtocolNumber 0x05
3: PT_BMS_iSensorReleaseVersion 0x00
4-6: PT_BMS_iSensorSerialNumber 0xe9 0xd7 0x24 0x00

car fw is .42....the answer to everything
 
  • Like
Reactions: Akrion

Yoonoo

Member
Dec 15, 2016
42
44
United States
How do you execute this command from apiary.io since there's no button for that in the Console?
I'm not very familiar with Apiary, but I would imagine that whoever published the API on Apiary has to add the vehicle_config resource.

Another option would be to use Apiary to generate the cURL command line for vehicle_state then manually replace vehicle_state with vehicle_config and run it locally on your computer.
 

jjanov79

Member
Sep 27, 2017
66
53
Austin, TX
I searched through the threads here but all I was able to find was a little bit too technical IMO for the average user and the step by step how to was not really there. I love the fact that Tim did the Apiary.io documentation and wanted with just the browser to walk through an example of how to get your Tesla's vehicle state etc.

I ended up actually doing this step by step for myself and that is how I found out that my "uncorking" was not done although my car was 2 months ago with Tesla of West Palm Beach for that exact purpose. So I have a real life example how this helped me.

Obviously, you can go like 10 different ways to get to the API and work with it but what I really liked with the Apiary.io was that all you need is just the browser so anyone can quickly do it without any other tools like Postman etc.

In any case, hope this is useful to the community and my apologies if it was done already. I did not find much on YT on the subject.



PS. There are few issues in the video like the Content-Type header param etc but overall it should suffice for the average user to follow and get data for their vehicle out IMO.

Because "vehicle_state" no longer displays performance info how do we go about getting "vehicle_config" from Apiary.io? That being said this would need to be for those of us who aren't programmers but can follow directions like in the video.
 

BTCTM3

Member
Jan 1, 2018
14
9
LA
Poking around the REST API, I was able to find the new location for perf_config for cars running version 2017.46 and above. It can be found under "data_request/vehicle_config" instead of "data_request/vehicle_state" for previous versions.

Well would you look at that - calling this on a model 3 shows:

"plg": null,
"rear_seat_heaters": 1,
"rear_seat_type": null,
"rhd": false,

Among some other data... :)
 
Confirmed that this is removed from the latest firmwares. I took my car in for uncorking and literally watched it happen. I kept a PowerShell script queued up on my phone via RDP to query the status of my car as they were working on it. They uncorked it first, which my script confirmed, and then they updated me from 42 to 46.8 at which point my script stopped working. I don't suppose anyone found a new location in the API response for this same info?
 

Products we're discussing on TMC...

About Us

Formed in 2006, Tesla Motors Club (TMC) was the first independent online Tesla community. Today it remains the largest and most dynamic community of Tesla enthusiasts. Learn more.

Do you value your experience at TMC? Consider becoming a Supporting Member of Tesla Motors Club. As a thank you for your contribution, you'll get nearly no ads in the Community and Groups sections. Additional perks are available depending on the level of contribution. Please visit the Account Upgrades page for more details.


SUPPORT TMC
Top