Tracking API

We are providing additional support to track your vehicle and get easy update on the status of your vehicle. Providing access to our API which provide data and you can use it in your system.

Features

  1. Easy and secure
  2. Fast and reliable.
  3. Customise data are available
  4. Add your URL and get access
  5. Easy and simple JSON format , widely use in majority companies
  6. POST method and REST Service for security

Parts of API

  1. Access code - This is provided inside your profile account. You can find it inside your profile details. Use this Access code to get response from server. This is encrypted end to end encryption. It is reliable and secure.
  2. Method - Provide the name of the valid method what type of data retrieve from the server. Invalid method name can result failed call to server
  3. Input JSON - Few methods required some input which needs to be provide in input. Ex. If you want to get data for specific vehicle then you have to give vehicle_no parameter.
    We are providing an option to customise your output JSON. For that you have to give key called parameters and give the data key which you want in particular output.
  4. Access Time - we are restricting our API for duration between two request otherwise it will give you respecting error.

How to use

1 Use the provided URL to access the API. Your_URL/tracking

                    
                     HttpPost request = new HttpPost(baseUrl + “/tracking);
                    
                

2 Set the Headers for given URL. Here two parameters are mandatory which is required to access the API

  1. auth_code
  2. method

Sample for JAVA

                    
                     request.setHeader("auth_code", “Ey-8dwdhiushduhsdb”);
                    request.setHeader("method", “getLocation”);
                    
                

3 Set INPUT JSON for the given URL.

Sample for JAVA

                    
                     request.setEntity(JSONData);
                    
                

4 Set the content type.

Our API supports content type : application/json

Sample for JAVA

                    
                     request.setHeader("Content-type", "application/json");
                    
                

Sample response

Failed response

                    
                     {
	 “success”:false,
	 “status”:{
 	 	 	 “code”:100,
	 	 	 “message”:”Given Token is invalid”
	 	 }
}
                    
                

Success response

                    
{
    “success”:true,
	“vehicles”:{
 	 	 	 	 “object”:”GJ-15-AD-2959”,
	 	 	 	 “status”:”running”,
	 	 	 	 “fuel”:12 ltrs
    }
}
                    
                

Error codes

Apart from HTTP standard error code we provide our custom error code to make the experience richer than before.

Use those error code to understand your request and correct it easily

Code Name Description

Our Services

In all service there is an option for customisation. If you provide parameters then it returns only that parameters in JSON response. Give single or multiple parameters in key. Set the parameters in given format:

                    
                        “parameters”: “object,duration”
                    
                

Duration

  1. It supports two duration start_date and end_date Keys.
  2. start_date is start time for the period and end_date is the end time for the period.
  3. All the dates support given format. Our API follow dd-MM-yyyy HH:mm pattern. The hours should be in 24 hours format.
  4. Minimum time duration can be 15 minutes.
  5. If there is no parameters of start_date and end_date then it returns data of current day.
  6. Give both start_date and end_date together if one is not available the it returns the default which is current day. Ex. “start_date”:”12-04-2020 09:10” , “end_date”:”12-04-2020 18:50”.