Skip to main content

How can I get fuel level using MyGeotab SDK?

Carrillo-1105
Original Poster

What function allow me to get fuel level data on a vehicle?

Do you have an example?

Join the conversation

You need to be logged in to reply to this post and participate in the Geotab Community discussions.

Top Answers

Hi @Carrillo-1073​ !

 

Depending on what you are looking for, you can get Fuel Level (Volume) in Liters:

 

api.call("Get", {

  "typeName": "StatusData",

  "search": {

    "fromDate": "2020-11-04T23:00:00.000Z",

    "toDate": "2020-11-05T22:59:59.000Z",

    "diagnosticSearch": {"id": "DiagnosticFuelUnitsId"},

    "deviceSearch": {"id": "b19D"}

  }

});

 

Or Fuel Level (Percentage):

 

api.call("Get", {

  "typeName": "StatusData",

  "search": {

    "fromDate": "2020-11-04T23:00:00.000Z",

    "toDate": "2020-11-05T22:59:59.000Z",

    "diagnosticSearch": {"id": "DiagnosticFuelLevelId"},

    "deviceSearch": {"id": "b19D"}

  }

});

 

Hope that helps!

 

Best,

Ron

1 Reply

Hi @Carrillo-1073​ !

 

Depending on what you are looking for, you can get Fuel Level (Volume) in Liters:

 

api.call("Get", {

  "typeName": "StatusData",

  "search": {

    "fromDate": "2020-11-04T23:00:00.000Z",

    "toDate": "2020-11-05T22:59:59.000Z",

    "diagnosticSearch": {"id": "DiagnosticFuelUnitsId"},

    "deviceSearch": {"id": "b19D"}

  }

});

 

Or Fuel Level (Percentage):

 

api.call("Get", {

  "typeName": "StatusData",

  "search": {

    "fromDate": "2020-11-04T23:00:00.000Z",

    "toDate": "2020-11-05T22:59:59.000Z",

    "diagnosticSearch": {"id": "DiagnosticFuelLevelId"},

    "deviceSearch": {"id": "b19D"}

  }

});

 

Hope that helps!

 

Best,

Ron

Still have questions?