Skip to main content
Omnitracs Knowledge Base

Set Mileage Counter

setMileageCounter

Sets the trailer mileage counter given a SCAC and trailer identifier.

void setMileageCounter(AssetIdentifier trailer, double counter) throws WSException

  • trailer: An AssetIdentifier that uniquely identifies the trailer to which the mileage counter will be set.
  • counter : The value to which the trailer mileage counter will be set. Only values with one or fewer decimal places are accepted. Possible values are: 
    U.S and Imperial: 0 - 2,668,768.9 miles
    Metric: 0 - 4,294,967.2 km

Authorization Requirements

The credentials supplied with this method call (as specified in the accompanying WS-Security header) must be authorized to the following application(s) and their associated role-based permissions.

Required Application Licenses
- Remote Integration

Required User Permissions
- Can use Trailer Tracks
- Can maintain trailers or Can maintain trailer mileage counter

Customer integrators are authorized to their own company's data only. 

Exceptions

002 Required field not specified.
003 Company not authorized for integration.
004 User not authorized.
005 Trailer mileage reporting not enabled.
006 Trailer mileage counter not supported.
007 Trailer SCAC not specified.
008 Trailer ID not specified.
009 Trailer SCAC/Trailer ID invalid.
010 Counter not valid.
011 Cannot set counter of foreign trailer. 

Sample setMileageCounter Request

Only the SOAP body is shown. To see a sample SOAP Envelope and Header, click here.

<soapenv:Body>

  <setMileageCounter>

   <trailer>

     <id>ALIVE595</id>

     <scac>LABU</scac>

   </trailer>

   <counter>0</counter>

  </setMileageCounter>

</soapenv:Body>

 

Sample setMileageCounter Response

An empty response conveys success. If there was an error, an exception would have been thrown. 

<soapenv:Body>

  <setMileageCounterResponse/>

</soapenv:Body>

  • Was this article helpful?