Fleet Connectivity Extension API Developer's Guide

Job Request Body

The POST request body contains information about the job sent to the asset with the Fleet Connectivity Extension API ecosystem.

The overall message size must not exceed 3500 characters in UTF-8 encoding.

The table below lists the elements of the post body. For an example of a post body, see Sending a Job to an Asset.

Table 1. Request Body Elements
Element Required Data Type Description
asset_id Yes String Specifies the identifier for the asset receiving the job. The maximum length is 50 characters. For more information on the Fleet Connectivity Extension API ecosystem, see Fleet Connectivity Extension API Ecosystem.
content Yes String Contains the structure expected by the application in the asset, allows for any JSON structure. For example, the asset application expects destination geocoordinates and the asset needs to avoid a bounding box of an area. If the application uses the parameter mode for calculating a route, the content block is as follows:
{
  "destination":"50.162456,8.533236",
  "avoidAreas":
  "50.145743,8.560077;50.139527,8.571493;",
  "mode":"fastest,car,traffic:enabled"
}
dispatcher_id Yes String Specifies the identifier for the dispatcher of the job. The maximum length is 50 characters. For more information on the Fleet Connectivity Extension API ecosystem, see Fleet Connectivity Extension API Ecosystem.
eta_threshold_percent Yes String Specifies a threshold as a percentage of the estimated time of arrival at which the application used by the asset should send an update. For example, when you specify a value of 5, the asset's application sends an update if the estimated time of arrival changes by more than five percent (5%).
job_id Yes String Specifies a unique identifier defined by the dispatcher application. The maximum length is 50 characters. For more information on the Fleet Connectivity Extension API ecosystem, see Fleet Connectivity Extension API Ecosystem.
message No String Optional text message.
type Yes String Specifies the type of job. The allowed values are:
  • NEW_DESTINATION – specifies the job; includes the geographic coordinates of a location.
  • CUSTOM – specifies that the messsage is for custom use in the asset application. When you specifiy this value, the value of thecontent element may be any JSON structure that is understood by the asset application.
version Yes String Indicates the protocol version used in the message. The value must be 1.0.
fcm_server_key No String Firebase Cloud Messaging server key. If set, an empty push notification will be sent to the Android device, so that asset's app knows it should check for updates. Obtain a server key for your application at firebase.google.com. Assets must send their push_token in each update message. Otherwise no push notification will be sent. On error, a warning will be returned. The message will still be delivered, but no push notification will be sent.