Smart Car of America Forum banner

1 - 3 of 3 Posts

·
Registered
Joined
·
142 Posts
Discussion Starter #1
Oddly enough the Chevy Volt and Spark have a website that can track the stats of their vehicles, via VoltStats.net From what I can tell, it's because Chevy provides an open API through their On-Star feature.

I have found a website that speaks to the VH web app that Smart ED owners can use. But I have found nothing that speaks to the existence of an API.

Does anyone know of a site that currently taps into the VH stats? Or if M-B offers an API that we could use to make a site for stats?
 

·
Registered
Joined
·
527 Posts
Using Google Chrome to debug vh.smart.com

Step 1.
Ctrl+Shift+I to open "developer tools" window when you are at the login screen

Step 2.
Login.

Step 3.
Go to "network" tab of the debugger. Find entry labelled "vehicleData?" in the path list. Go to "headers" tab.

Output is something like:
p { margin-bottom: 0.25cm; line-height: 120%; } Remote Address:80.154.131.240:443
Request URL:https://vh-if.dvb.corpinter.net/gateway/vehicle/#######/vehicleData?_dc=##########
Request Method:pOST
Status Code:200 OK
Request Headersview source
Accept:application/json
Accept-Encoding:gzip,deflate,sdch
Accept-Language:en-GB,en-US;q=0.8,en;q=0.6
Connection:keep-alive
Content-Length:32
Content-Type:application/json
Host:vh-if.dvb.corpinter.net
Origin:https://vh.smart.com
Referer:https://vh.smart.com/index.html
Step 4:
Go to "response" tab.

The raw stats are available as JSON.
I take a guess at some of the key items returned below:
{"soc":64,"tsoffset":0} = current state of charge, 64% in my case

{"soc":100,"tsoffset":15300} = in 15300 seconds, car can be fully charged if plugged in now


"odo":{"ts":1405459595,"value":4776} = current odometer reading in km


"chargestatus":{"ts":1405268330,"value":0} = not charging, otherwise value would be 1

"ecoscoreaccel":{"ts":1405458637,"value":0},"ecoscoreconst":{"ts":1405458586,"value":0},"ecoscorefreewhl":{"ts":1405459661,"value":34},"ecoscoretotal":{"ts":1405459641,"value":11} = ECO scores. Yes, I drive without a care in the world, my ECO score total was 11...



"precond":{"ts":1405488853,"value":1} = high voltage battery pre-conditioning - currently enabled




"notification":{"targets":{"email":true,"twitter":false,"rss":false},"triggervalueminsoc":80,"activation":{"notifyfullycharged":true,"notifyminsoc":true,"notifychargeerror":false,"notifyprecondabort":false}}
= settings that are available in the app, namely, how to notify and what for
 

·
Registered
Joined
·
2 Posts
August 2014 - New Smart Electric - Trip logging ?

I see the new data appear in MAC OS X Safari in XHRs but what API calls are used ?

I convert returned ODO Kilometers externally to Miles in USA.
The webpage does that based on settings.

If I try to use the same code locally the HTTPS sees me as another URL site
and I get an error.

Configuration or usage error: 417
Target URL must be within the same domain!

I would like to get the data in a locally written Application.
 
1 - 3 of 3 Posts
Top