Table of contents


1.Summary

This documentation is about the open API for the platform Vehicle Tracking System. Any qualified third party applications or websites may utilize this API to empower the business.

This API is based on REST standards, and is compatible with all kinds of programming languages. Many of the fields are self-explanatory

Security

For server side programming API key is not mandatory. IP Listing can be done from GPS provider side. For client side programming API Key is mandatory.

Open API Usage scenarios:

   1. The API is used to extend GPS functionalities of the underlying dealers' own systems.

   2. Accounts of dealers' own systems should be mapped to the assets (IMEIs) of our vehicle-tracking platform.

   3. Dealers' application servers issue API requests to get GPS data.

Usage Workflow

Dealer provides account and password on the vehicle-tracking platform to acquire API Key. Dealer then uses the token on their server to access Open API for needed data.

2. API Summary
Common Parameters:
Name Type Mandatory Desc
apiKey String Yes An apiKey, used to indicate whether the invoker is authorized. Reference to 4.1 for acquiring the token.The apiKey should only be used within your server side code, otherwise it will not work.
userId String Yes The userId which is the one you used to acquire api key
Time number Yes UNIX timestamp, in seconds. Generally the time when the request is invoked.

Parameter Encoding

    The encoding of request and response is utf-8, all parameters in url should be URIEncoded

HTTP MIME Type: JSON

Content-type: text/html; charset=utf-8

API Listing
Acquire apiKey:

   Note: For testing phase this is not required.

   Description: Acquire apiKey

   URL: http://<domainname>/apiMobile/getApiKey

   HTTP Method: GET

Input Parameters:
Name Type Desc
userId String Account of user
Time Long Current Unix time stamp from EpochConverter
Signature String Encrypted signature; Md5 algorithm: md5(userId+Password)
validDays String As a number like 4, and it would be valid for 4 days
URL Example:

http://<domainname>/apiMobile/getApiKey?

userId=DEMO&time=EpochTime &signature=83accefcd58239d8283da1b0bca78abc&validDays=4

    Note: To convert epochTime -> http://www.epochconverter.com/

Response:
Name Type Desc
Status String The status parameter written for success or failure
Reason String If status is zero, here the reason
apiKey String For authorization
expires_in Number Expiration of apiKey, in seconds

Note:

  1. apiKey should be used within server side code only, otherwise it will not work.

  2.If a return code is NULL, it means the apiKey has been expired and should be reacquired.

3. Get Live Locations

Goal: Get the newest GPS data of all vehicles of a specified account.

URL: http://<domainname>/getVehicleLocations OR getVehicleDetails4TVS

NOTE: getVehicleLocations will return JSON data while getVehicleDetails4TVS will give XML data only with the same process as on vehicle location.

HTTP Method: GET

Input Parameters: userId, userLocation, group, apiKey, macid, appid , imei, apiKey, language

Common Parameters
Name Type Required Default value Desc
userId String Yes - Group Id of the user for which vehicles are allotted.
URL Example:

  http://<domainname>/apiMobile/getVehicleLocations?apiKey=ndwlraqfxujojrmktvzg& userId=DEMO&groupId=DEMO


Response:
Field Type Description
Distance String Total Distance covered for all vehicles
rowId String Row Count
Group String Group Name for which vehicles are grouped under
zoomLevel String Map zoom level
Latitude String GPS Latitude
Longtitude String GPS Longitude
topSpeedVehicleId String Top speed vehicle Id
totalMovingVehicles String Total moving vehicles count
totalIdleVehicles String Total Idle vehicles count
totalParkedVehicles String Total parked vehicles count
totalNoDataVehicles String Total no data vehicles count
allow Booking String For future use
allowed Vehicles String For future use
support Details String Support details
row ID Integer Record count
Latitude String GPS latitude
Longitude String GPS Longitude
Speed Integer Current speed of the vehicle
Date String Current date and time (UTC
Alert String Type of alert
Direction String Course of vehicle (North, South, East , West, NE,NW,SE,SW)
Position String Moving, Parked, Static (Idle), NoData
distanceCovered double Distance travelled today
odoDistance double Vehicle odo meter reading
tankSize Integer Fuel Tank Size
Status String GPS Status (ON or oFF)
Color String Internal use
lastSeen String GPS Last Communicated time
ignitionStatus String ACC Status (ON or OFF)
insideGeoFence String Is vehicle inside Geo fence (yes or no)
isOverSpeed String Yes or No
Address String Address for the current lat and lng
parkedTime Integer Parked time (shown when only vehicle is parked)
movingTime Integer Moving time (shown when only vehicle is moving)
idleTime Integer Idle time (shown when only vehicle is idle)
noDataTime Integer No data time (shown when only vehicle is not communicating)
alertDataTime String Alert time (shown when last alert received)
loadTruk String Load of the truck received via load sensor
loadTrailer String Load of the trailer received via load sensor
totalTruck String For future use
totalTrailer String For future use
vehicleBusy String For future use
fuelLitre String Current fuel level in litre
oprName String For future use
regNo String Vehicle Registration Number
vehicleType String Type of vehicle (Truck, Bus, Car)
vehicleId String Asset ID. This is very importat.
mobileNo String Mobile Number configured (typically drivers mobie Number)
customMarker String For future use
deviceModel String Model of the device like GT06N etc
shortName String Vehicle Name
orgId String Organization Name
overSpeedLimit String Over Speed Limit
driverName String Name of the driver
Live String For future use

4. Get History

Get the history of specific vehicle for the given date and time range. This API should be fired after firing getVehicleLocations API. Because the first API has the mapping between vehicleName and vehicleId. For this API vehicleID is the input.

URL:

http://<domainname>/getVehicleHistory?userId=DEMO&vehicleId=SBLT-TN21-AT-0234&fromDate=2016-04-21&fromTime=00:00:00&toDate=2016-04-23&toTime=11:4 7:00


HTTP Method: GET
Input Parameters: userId, interval, fromDate, toDate, fromTime, toTime, vehicleId.

Parameters
Name Type Required Default Value Desc
userId String Yes - For particular User, UserId required
vehicleId String Yes - Vehicle Id (retrieved by getVehicleId API)
fromDate String Yes yyyy-mm-dd Start date
fromTime String Yes HH:mm:ss Start time (24 hours time format)
toDate String Yes - yyyy-mm-dd
toTime String Yes HH:mm:ss End time (24 hours time format)
Url Example:

http://<domainname>/getVehicleHistory?userId=SBLT&groupId=SBLT&vehicleId=S BLT-TN21-AT-0234&fromDate=2016-04-21&fromTime=00:00:00&toDate=2016-04-2 3&toTime=23:47:00

Response:

Field Type Description
deviceId String For future use
vehicleId String Asset ID
shortName String Vehicle Name
altShortName String For future use
altShortTime String For future use
regNo String Vehicle Registration Number
vehicleMake String Make of the vehicle
vehicleType String Type of the vehicle (Bus, Truck, Car)
Opr String For future use
mobileNo String Mobile Number
overSpeedLimit String Over Speed Limit
odoDistance String Odometer reading
deviceModel String Model of the device (GT06N, TK06 etc)
driverName String Name of the driver
sendGeoFenceSMS String For future use
gpsSimNo String Internal use
morningTripStartTime String For future use
eveningTripStartTime String For future use
portNo String For future use
vehicleLocations Array For future use
rowId Integer Record number
Latitude String GPS Latitude
Longitude String GPS Longitude
Speed Integer Current speed of the vehicle
Date String Current date and time (UTC)
Alert String Type of alert received
Direction String Course of Vehicle (North, South, East, West, NE,SE,NW,SW)
Position String Position (Moving, Parked, Static (Idle), No Data Time )
distanceCovered double Today distance travelled
odoDistance double Odo meter reading
tankSize String Full tank level
Status String GPS status (ON or OFF)
Color String For future use
lastSeen double GPS Last communicate date and time (UTC)
ignitionStatus double ACC status (ON or OFF)
insideGeoFence String Is vehicle inside Geo fence site (yes or no)
isOverSpeed String Yes or No
Address String Address for the lat and lng.
parkedTime Integer Parked time (shown when only vehicle is parked)
movingTime Integer Moving time (shown when only vehicle is moving)
idleTime Integer Idle time (shown when only vehicle is idle)
noDataTime Integer No data time (shown when only vehicle is not communicating)
alertDataTime String Alert time (shown when last alert received)
loadTruck String Load of the truck received via load sensor
loadTrailer String Load of the trailer received via load sensor
totalTruck String For future use
totalTrailer String For future use
vehicleBusy String For future use
fuelLitre String Current fuel level in litre
totalParkedTime String Total parked time for entire trip
tripDistance String Total distance for entire trip
tmpDistance String For internal use
ignitionOnTime String Total ignition on time

5. Get History for mobile

Goal: This API tuned for mobile use. History for specific vehicle Id for the given date and time range.

URL: http://<domainname>/apiMobile/getVehicleHistory4MobileV2?

HTTP Method: GET


Input Parameters: user ID, interval, fromDate, toDate, fromTime toTime, vehicleId, apiKey.

Common Parameters
Name Type Required Default Value Desc
vehicleId String Yes - Vehicle Id (retrieved by getVehicleId API)
fromDate String Yes yyyy-mm-dd Start date
fromTime String Yes HH:mm:ss Start time (24 hours time format)
toDate String Yes yyyy-mm-dd End Date
toTime String Yes HH:mm:ss End time (24 hours time format)

URL Example:

http://<domainname>/apiMobile/getVehicleHistory4MobileV2?userId=XYZ&vehicleId=TN1234&interval=5&fromDate=2011-08-21&fromTime=10:56:24.389362&toDate=2011-12-25&toTime=10:56:24.389362&apiKey= hdggbdjageyrevfjdurjer


Response:
Field Type Description
deviceId String For future use
vehicleId String Asset ID
shortName String Vehicle Name
altShortName String For future use
altShortTime String For future use
regNo String Vehicle Registration Number
vehicleMake String Make of the vehicle
vehicleType String Type of the vehicle (Bus, Truck, Car)
Opr String For future use
mobileNo String Mobile Number
overSpeedLimit Number Over Speed Limit
odoDistance String Odometer reading
deviceModel String Model of the device (GT06N, TK06 etc)
driverName String Name of the driver
Fcode String Franchise Name
Email - -
sendGeoFenceSMS String For future use
gpsSimNo String Internal use
morningTripStartTime String For future use
eveningTripStartTime String For future use
portNo String For future use
ipAddress - For future use
routeNo String For future use
orgId String For future use
parkingAlert String For future use
Date String For future use
paymentType - For future use
expiredPeriod - For future use
Fuel - For future use
fuelType - For future use
analog1 - For future use
analog2 - For future use
digital1 - For future use
digital2 - For future use
serial1 - For future use
serial2 - For future use
Digitalout - For future use
isRfid - For future use
rfidType - For future use
Mintemp - For future use
Maxtemp - For future use
vehicleLocations - For future use
history4Mobile Array -
Lt String GPS Latitude
Lg String GPS Longitude
Sp Integer Current speed of the vehicle
Dt String Current date and time (UTC)
Dr String Course of Vehicle (North, South, East, West,NE,SE,NW,SW)
Ps String Position (Moving, Parked, Static (Idle), No DataTime )
Dc String GPS Latitude
Lg String Distance covered
Pt long Parked time
gfTrip - For future use
zoomLevel - -
totalIdleTime Long Idle time
totalRunningTime Number Running Time
totalParkedTime Number Parked time
totalNoDataTime Number data not received
totalRows Number -
tripDistance Float Trip distance in KM
overSpeedInstances Number Number of timeOverspeeed driving
topSpeed Number What was the top speed
parkingCount Number total number of parkingCount
topSpeedGeoLocation - -
topSpeedTimeUTC Number time at top speed IN UTC
fromDateTimeUTC Echo Time date & time for report
toDateTimeUTC Echo Time date & time for report
topSpeedTime - time at top speed
fromDateTime DayDateTime IST time
toDateTime DayDateTime IST time
Error - -
openingOdoReading Long date & time for report
toDateTimeUTC Echo Time daStarting odo reading
totalFuelFill Number total fuel fill
totalFuelConsume Number total fuel consume
closingOdoReading Float last odo reading/after stop
Own Type of user who is owner/franchise

6. Get Selected Vehicle for Tracking (Single Vehicle)

This API is to track single vehicle. This API should be fired after firing getVehicleLocations API. Because the getVehicleLocations API has the mapping between vehicleName and vehicleId. For this (getSelectedVehicleLocation) API vehicle ID is the key input.


URL: http://<domainname>/apiMobile/getSelectedVehicleLocation


HTTP Method: GET


Input Parameters: userId, vehicleId

Common Parameters

Name Type Required DefaultValue Desc
userId String Yes - userId
vehicleId String Yes - Vehicle Ide
group String yes - groupId

URL Example:

  http://<domainname>/apiMobile/getSelectedVehicleLocation?vehicleId=meena1001&userId=prasannak&group=prasannak&apiKey=hagfddvhewjfudkdsk


Response:

Field Type Description
rowId Integer Record count
Latitude String GPS latitude
Longitude String GPS Longitude
Speed String Current speed of the vehicle
Date String For future use
Alert String Type of alert
Direction String Course of vehicle (North, South, East , West,NE,NW,SE,SW)
Position String Moving, Parked, Static (Idle), NoData
distanceCovered double Distance travelled today
odoDistance double Vehicle odo meter reading
tankSize Integer Fuel Tank Size
Status String GPS Status (ON or oFF)
Color String Internal use
lastSeen String GPS Last Communicated time
ignitionStatus String ACC Status (ON or OFF)
insideGeoFence String Is vehicle inside Geo fence (yes or no)
isOverSpeed String Yes or No
Address String Address for the current lat and lng
parkedTime Integer Parked time (shown when only vehicle is parked)
movingTime Integer Moving time (shown when only vehicle is moving)
idleTime Integer Idle time (shown when only vehicle is idle)
noDataTime Integer No data time (shown when only vehicle is notcommunicating)
alertDataTime String Alert time (shown when last alert received)
loadTruk String Load of the truck received via load sensor
loadTrailer String Load of the trailer received via load sensor
totalTruck String For future use
totalTrailer - For future use
vehicleBusy - For future use
Fuel - For future use
fuelLitre - Current fuel level in litre
temperature - Future work
powerStatus - Future work
vehicleMake - Future work
oprName String For future use
regNo String Vehicle Registration Number
vehicleId String Asset ID. This is very important.
customMarker String For future use
deviceModel String Model of the device like GT06N etc
shortName String Vehicle Name
orgId String Organization Name
overSpeedLimit String Over Speed Limit
driverName String Name of the driver
live String For future use
fuel Long -
deviceId Number Device ID

7. KMs Summary - For Group of Vehicles

This API used to get KMs summary for day, yesterday week and month


URL: http://<domainname>/apiMobile/getKmsSummary


HTTP Method: GET


Input Parameters:

Common Parameters
Specific Parameters:

  No Specific parameters


Url Example:

  http://<domainname>/apiMobile/getKmsSummary?userId=XYZ&groupId=XYZ:SMP&apiKey=hjskdfuvsjdsyffbjsjsusska


Response:
Field Type Description
rowId Integer Record count
Date String Current date and time (UTC)
vehicleId String vehicleId
shortName String Vehicle Name
Fcode String Franchise Code
topSpeed Number Maximum Speed vehicle has travelled
overSpeedInstances Number Number of times the vehicle has over sped
distanceMonth Number Total distance travelled in past 30 or 31 days
distanceYest Number Distance travelled yesterday
distanceWeek Number Distance travelled Week
odoClosingReading Number For future use
distanceToday Number Distance travelled today (as of current time)
parkingCount - Number of Parking done
topSpeedGeoLocation String For future use
Address String For future use
topSpeedTime Number For future use
totalParkedTime Number Total time vehicle has parked in milli seconds
totalRunningTime Number Total time vehicle has moved in milli seconds
totalIdleTime Integer Total time vehicle has idled in milli seconds
totalNoDataTime Integer Total time vehicle hasn’t received any data in milliSeconds
totalFuelFill Integer For future use
totalFuelConsume Integer For future use

8. KMs summary For selected Vehicle (multiple dates)

This API used to get KMs summary for day, yesterday week and month for multiple vehicles.


URL : http://<domainname>/apiMobile/getExecutiveReport?


HTTP Method: GET


Input Parameters:


Common Parameters

Name Type Required DefaultValue Desc
UserId string yes - Vehicle Id (retrieved bygetVehicleId API)
groupId string yes - Group Id can be find byS_Groups_Dealer_User_Fcode
fromDate string yes - Date format : yyyy-mm-dd
toDate string yes - Date format : yyyy-mm-dd
Url Example:

http://<domainname>/apiMobile/getExecutiveReport?userId=XYZ&groupId=XYZ&fromDate=2016-08-21&toDate=2016-09-10&apiKey=hkssfdsdlffnjhdyehhjdus


Response:
Field Type Description
rowId Integer Record count
vehicleId string vehicleId
shortName String Vehicle Name
Fcode string Franchise Code
topSpeed Number Maximum Speed vehicle has travelled
overSpeedInstances Number Number of times the vehicle has over speed
distanceMonth Number Total distance travelled in past 30 or 31Days
distanceYest Number Distance travelled yesterday
distanceWeek Number Distance travelled Week
odoOpeningReading Number OdoMeter reading Starting
odoClosingReading Number OdoMeter reading Ending
distanceToday Number Distance travelled today (as of current time)
parkingCount Number total number of parking count
topSpeedGeoLocation String Lat and Lng of the location where thevehicle top speed
Address String For future use
topSpeedTime Number Date and time when the vehicle top speed
totalRunningTime Number Total time vehicle has moved in milliSeconds
totalIdleTime Integer Total time vehicle has idled in milliSeconds
totalNoDataTime Integer Total time vehicle hasn’t received any datain milli seconds
totalFuelFill Integer For future use

9. View Sites

Usage of this API is get the sites (geo fence) configured for each company/org.


Http Method: Get


Input Parameters: userId, fcode.


Common Parameters

Specific Parameters

Name Type Required DefaultValue Desc
Fcode String Yes - FranchiseCode
userId String Yes - User ID
URL Example:

  http://<domainname>/apiMobile/viewSite?fcode=SMP&userId=MSS&apiKey=jdfbdsdsfslfjfsusfdkddkfsh


Response:
Field Type Description
siteParent Array Array of Sites
orgId String Organisation name
Site Array Contains all sites in array
siteName String Name of Site
siteType String Site type(e.g: Client Site OR Restricted Site)
userId String User ID
latLng Double latitude and Longitude of Site
orgId String Organisation Id that User comes under
Location Array Site location
orgIds String Organisation name

10. Event report

Usage of this API is to get report on location, site, over speed, stoppage, parking time, idle time, no data time, speed


URL: http://<domainname>/getActionReport


HTTP Method: GET


Input Parameters: VehicleId, UserID, Interval, fromDate, toDate, Stoppage.


Specific Parameters
Name Type Required DefaultValue Desc
vehicleId String Yes - Vehicle (Asset) ID
userId String Yes - User ID
fromDate String Yes - yyyy-mm-dd
toDate String Yes - yyyy-mm-dd
fromTime String Yes 00:00:00 HH:mm:ss (24 hours format)
toTime String Yes 23:59:59 HH:mm:ss (24 hoursformat)
Stoppage String Yes False true or false
stopMints Number Yes 10 Minutes vehicle stopped.Sample 10 or 20
Idle String No False true or false
idleMints Number No 10 Minutes vehicle idle.Sample 10 or 20
notReachable String No False true or false
notReachableMints Number No 10 Minutes vehicle notReachable. Sample 10 or 20
overSpeed String No False true or false
Speed Number No 60 Minimum speed 60
URL Example:

  http://<domainname>/getActionReport?vehicleId=TN1234&userId=XYZ&interval=5 0&fromDate=2016-08-21&toDate=2016-08-22&stoppage=true


NOTE: Here difference between dates would not be greater than 3.


Response:
Field Type Description
start Time String Date and Time UTC time stamp
Duration String Duration in milli seconds
State Number Vehicle status Parked, Idle, over speed,Location Entry, Location Exit, Site Entry, Site Exit
Latitude String Latitude of the vehicle
Longitude String Longitude of the vehicle
userId String User ID
Address Double Address of the vehicle
fuel Consume Number Total fuel consumed during the journey
tempFuelLitre - Internal use
fuel From - Internal use
fuel To - Internal use

11. Vehicle location for major clients

This API is same as Vehicle Services for getting vehicle info but for major clients like TVS.


URL: http://<domainname>/getVehicleDataForTrustedClients


HTTP Method: GET


Input Parameters: VehicleId, UserID, groupId.


Specific Parameters
Name Type Required DefaultValue
vehicleId String Yes -
userId String Yes demouser1
GroupId String Yes -1

URL example:

  http://<domainname>/getVehicleDataForTrustedClients?userId=XYZ&vehicleId=XY Z1234&group=groupID


Response
Field Type Description
rowId Number Number of row for a vehicle's Result
latitude Double latitude of vehicle
Longitude Double longitude of vehicle
Speed Int Number of times which morethan avg. speed
Date Date Echo date for vehicle
alert String alert subscribed or not(Y/N)
Direction Direction Vehicle direction(N,S,E,W)
Position String Last position of vehicle
distanceCovered Double Total distance covered
odoDistance Double Odo meter of last reading
tankSize Double Fuel tank size
deviceVolt Double voltage capacity in volt
Status String device status(OFF/ON)
color String -
lastSeen String Last seen date & time as String
ignitionStatus String Vehicle ignition status(OFF/ON)
insideGeoFence String For geo view(default=NO)
isOverSpeed String Vehicle crossed over speed limit or not(default=NO)
Address String Last address of vehicle
parkedTime Long Timing of parking
movingTime Long Total time of running
idleTime Long Total time of idle
noDataTime Long No data at particular time
alertDateTime String -
loadTruck String Load info if it would be a Truck
loadTrailer String Load info if it would be a trailer
totalTruck String Total number of truck
totalTrailer String Total number of trailer
vehicleBusy String vehicle busy or not(default=NO)
fuelLitre Double remaining fuel(default=0.0)
temperature Double teperature of fuel(default=0.0)
powerStatus String Vehicle power info
oprName String SIM operator name
regNo String Vehicle reg no
vehicleType String Type of vehicle
vehicleId String Vehicle Id(AssetId)
mobileNo String Mobile number of User
customMarker String -
deviceModel Model type of device SIM operator name
shortName String Short name of vehicle
orgId String -
overSpeedLimit - -
driverName String Vehicle's driver Name
Live String Live vehicle data(YES/NO)
fuel String -
deviceId Double GPS device ID

12. Add a site

This API is used for adding a site by providing latitude and longitude with POI.


URL: http://<domainname>/addSite


HTTP Method: GET


Input Parameters: VehicleId, UserID, groupId.

Specific Parameters

Name Type Required DefaultValue
UserId String Yes demoUser1
OrgId String Yes -
siteName String Yes -
siteAddress String Yes -
URL example:

  http://<domainname>/addSite?userId=XYZ&orgId=ABC&siteName=CbcaHAN&siteAddress=52.94957, 87.52296:72.94957, 97.52296:42.94957, 67.52296.

Response:

 1; "Success" message if site is added successfully, otherwise failure message by saying "please send correct data".


13. Save site

To save a multiple site with multiple lat & long, this Key is used but without POI.


URL: http://<domainname>/saveSite


HTTP Method: GET


Input Parameters: fcode, orgId, latLng

Specific Parameters
Name Type Required DefaultValue Desc
Fcode String Yes - franchise code
orgId String Yes - Org code
latLng String No latLng Latitude&Longitude
siteName String Yes - Name of site
siteType String Yes - Site Type(e.g:home)

URL example:

  http://<domainname>/saveSite?latLng=52.94957,87.52296:72.94957,97.52296:42.949 57, 67.52296&orgId=ABC&fcode=XYZ&siteName=CbcaHAN&siteType=HomeSite.


Response:

  1. Success message if Lat & long and site name are not exist before.

  2. Failure message if lat & long is not on correct format

  3. Site already present if lat & long or site name are already present.


14. Delete Site

This API is used for delete a site, if site is present, otherwise it will give an error message


URL: http://<domainname>/deleteSite

HTTP Method: GET

Input Parameters: fcode, orgId, userId, siteName

Specific Parameters:
Name Type Required DefaultValue
orgId String Yes -
Fcode String Yes -
userId String No -
siteName String Yes -
URL example:

  http://<domainname>/deleteSite?latLng=52.94957,87.52296:72.94957,97.52296:42.9 4957,67.52296 &orgId=ABC&fcode=XYZ&siteName=CbcaHAN&siteType=Home Site.


Response:

  1. Success.

  2. failure.


15. ViewSingleSite

This API is used to view one site by user

NOTE: The difference between view Site and viewSingleSite is in viewSite user can see multiple sites while in viewSingleSite only one site can be see by user.

URL: http://<domainname>/viewSingleSite

HTTP Method: GET

Input Parameters: fcode, userId, siteName

Specific Parameters

Name Type Required DefaultValue
orgId String Yes -
Fcode String Yes -
userId String No -
siteName String Yes -
URL example:

  http://<domainname>/viewSingleSite?orgId=XYZ&fcode=ABC&siteName=CbcaHAN.

Response:
Field Type Description
SiteName String Name of site
SiteType String Type of site(eg: home)
UserId String User ID
latLng String Latitude and Longitude
OrgId String Organization Id

16. SMS subscription for school bus

This API is used for School bus solution to subscribe SMS. Mainly it will be used by children's parent in order to subscribe for a SMS to get the timing of bus route information.


URL: http://<domainname>/getValueFromSmsProvider

HTTP Method: GET

Input Parameters: msisdn, sms, circle, opnm, datetime.

Specific Parameters:
Name Type Required DefaultValue
Msisdn String Yes -
Sms String Yes -
Circle String Yes -
Opnm String Yes -
Datetime String Yes -
URL example:

  http://<domainname>/getValueFromSmsProvider?msisdn=9898978789&sms=VTS START, MSS, PY01D8616, 4&circle=chennai&opnm=airtel&datetime=2011-12-20 10:56:24.389362

17. Store GCM ID

This API is used to store GCM ID while user logging in.


URL: http://<domainname>/storeGcmId

HTTP Method: GET

Input Parameters: gcmId

Specific Parameters
Name Type DefaultValue
gcmId String -
URL example:

  http://localhost:9000/storeGcmId?gcmId=32dsfsf


Response code:

  Success

18. Lock features

This API is used to get and set notification for vehicle's door. If vehicle's door is open during running it will push a notification to the corresponding user.

They are of 2 types:

  1. Lock: To get the notification and perform Lock action on vehicle's door

  2. Unlock: To get the notification and perform Unlock action on vehicle's door.


LOCK:

To lock the vehicle like to stop vehicle under certain circumstances.


URL: http://<domainname>/getLock

HTTP Method: GET

Input Parameters: vehicleId, userId

Specific Parameters
Name Type DefaultValue
vehicleId String -
userId String -
URL example:

http://<domainname>/getLock?vehicleId=XYZ-TN52-W-3938&userId=XYZ.


Response:
Name Type Description
mobileNo String User mobile number
smsText String RELAY,1# ,if it is supportedby both device& vehicle
Error String NULL, if device is compatible,otherwise "Not supported"
Unlock

Reverse of Lock API and response will also be same.


URL: http://<domainname>/getUnLock.

HTTP Method: GET

Input Parameters: vehicleId, userId.


Specific Parameters
Name Type Default
vehicleId String -
userId String -
URL example:

  http://<domainname>/getUnLock?vehicleId=XYZ-TN52-W-3938&userId=XYZ


19. Group vehicle details

This API can be used to get all vehicle with their VehicleId and vehicleName under a group.


URL: http://<domainname>/getvehicleNameMap.

HTTP Method: GET

Input Parameters: groupName, fcode.


Specific Parameters
Name Type Required Default
groupName String Yes -
Fcode String Yes -
URL example:

  http://<domainname>/getvehicleNameMap?groupName=XYZ-BUS&fcode=XYZ.

Response:
Name Type Description
VehicleId Hashmap VehicleId under a group
VehicleName Hashmap VehicleName under a group

20. Fuel Report

This API can be used when any user wants to know what the fuel consumption is, fuel fill and fuel fill report at certain distance and at certain time

Two support types are there:

  1. DistanceTimeFuelReport : Report is used for fuel consumption, distance vs time

  2. FuelDropFillReport : getFuelDropFillReport is used to get information when tank will be filled and when fuel theft.


URL: http://<domainname>/getDistanceTimeFuelReport OR getFuelDropFillReport.

HTTP Method: GET

Input Parameters: vehicleId, userId, interval, fromDate, toDate.

Specific Parameters
Name Type Required Default
VehicleId String Yes -
userId String Yes -
Interval Number No -
fromDate Date Yes -
toDate Date Yes -
URL example:

  1. for DistanceTimeFuelReport:

http://localhost:9000/getDistanceTimeFuelReport?userId=XYZ&vehicleId=XYZ& fromDate =2016-08-21&toDate=2016-08-29.

  2. for FuelDropFillReport:

http://localhost:9000/getDistanceTimeFuelReport?userId=XYZ&vehicleId=XYZ&fromDate=2016-08-21&toDate=2016-08-29.


Response:

To be check again.


21. Load Report

This API can be used to get load history of particular vehicle


URL: http://<domainname>/getLoadReport

HTTP Method: GET

Input Parameters: vehicleId, userId, interval, fromDate, toDate.

Specific Parameters
Name Type Required Default
VehicleId String Yes -
userId String Yes -
Interval Number No -
fromDate Date Yes -
toDate Date Yes -
URL example:

&nsbp; http://localhost:9000/getLoadReport?userId=XYZ&vehicleId=XYZ&fromDate=2016-0 8-21&toDate=2016-08-29

Response

On Failure

Name Date Vehicle Other
Failure Dates are out of range or Invalid Date format Invalid Vehicle Zero records

On Success
Success Parameters Name Parameters Type Parameters Default value
Yes Load Array List -

Here Array List is data structure as a Load.

Where Load is:

Name Type Default value
Date long -
Lat Double -
lng double -
Load String -
Address String -

22. Temperature Report

This API can be used to get temperature history for a vehicle.

URL: http://<domainname>/getTemperatureReport

HTTP Method: GET

Input Parameters: vehicleId, userId, interval, fromDate, toDate

Specific Parameters
Name Type Required Default
vehicleId String yes -
userId String yes -
Interval Number no -
fromDate Date yes -
toDate Date yes -
URL example:

http://localhost:9000/?userId=XYZ&vehicleId=XYZ&fromDate=2016-08-21&toDate=2 016-08-29.

Response

Its same as on Load Report response.