Follow

Webhook PVT data

Updated

When Frotcom receives new tracking data* from your vehicles, a message is sent to your system.

 

* The lowest time interval is 1 minute; all events received in the 1 minute are grouped and sent in the next message.

You can read more information about webhooks here

 

Authentication

Frotcom will send webhook requests with an authentication token in the request headers. Your application must validate this token before processing the request.


Request Headers

Header Description Format Mandatory Example
Authorization Token generated during configuration. GUID Yes 1234-5678-9097-8466
Content-Type Specifies the format of the request
payload.
Text Yes application/json

Your system should reject any request that does not contain a valid Authorization token.


Webhook Request Format

HTTPS Method and Endpoint

  • Method: POST
  • Content-Type: application/json
  • Example Endpoint: https://yourdomain.com/webhooks/frotcom

JSON Payload Structure
Frotcom will send a JSON object containing vehicle position data:

Data Fields

Root Object

Field Description Format Mandatory Example
PvtMessages Array of vehicle messages  Array Yes See below

 

Vehicle Data

Field Description Format Mandatory Example
VehicleID Vehicle id Text Yes 9876543
LicensePlate Frotcom License plate Text Yes AA-001-AAA
Positions Array of position records   Yes See below

 

Tracking Data

Field Description Format Mandatory Example
Timestamp Day and time in which the information refers. The timezone used must be UTC. Yes  "Timestamp": "2023-10-25T16:29:31.087Z",
Latitude Latitude of the vehicle  Decimal degrees (DD) Yes "Latitude": 41.40338
Longitude Longitude of the vehicle  Decimal degrees (DD) Yes "Longitude": 2.17803
Speed
The speed of the vehicle. Double 1 decimal Yes "Speed":45.0
Direction Vehicle direction between 0 and 360º. Double 1 decimal No "Direction": 20.0,
Ignition The ignition of the vehicle (if the value received is true, it means ignition on; otherwise, it is off). Boolean Yes "Ignition": true

 

Response Requirements

Your endpoint must respond promptly with the appropriate HTTP status code:

Status code When to use Example Response Body
200 OK Successful processing  {"status": "success"}
500 Server error Processing error {"error": "Internal server error"}

 

Important Implementation Notes

  • Regular Operation: Frotcom delivers data batches once per minute.
  • Data is delivered in batches to minimize connection overhead.
Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request
Powered by Zendesk