MOBILITY DEMO

Trip vs Task Comparison

Trip

In Fleet Engine, a trip is a type of journey that models the fulfillment of a food delivery or ride request from your consumers. A trip has a status that you report to Fleet Engine as the journey evolves, such as NEW, ENROUTE_TO_PICKUP, and more. The trip status corresponds to geo-located waypoints assigned to the vehicle, and Fleet Engine modifies these vehicle waypoints with each trip update you make. Once the vehicle reaches the destination waypoint of the trip and your driver indicates a successful trip, your system sets the TripStatus to COMPLETE in Fleet Engine.
FieldDescription
nameTrip name, must be unique
vehicle_idID of the vehicle making this trip.
trip_typeThe type of the trip.
UNKNOWN_TRIP_TYPE Default, used for unspecified or unrecognized trip types.
SHARED The trip may share a vehicle with other trips.
EXCLUSIVE The trip is exclusive to a vehicle.
trip_statusCurrent status of the trip.
UNKNOWN_TRIP_STATUSDefault, used for unspecified or unrecognized trip status.
NEWNewly created trip.
ENROUTE_TO_PICKUPThe driver is on their way to the pickup point.
ARRIVED_AT_PICKUPThe driver has arrived at the pickup point.
ARRIVED_AT_INTERMEDIATE_DESTINATIONThe driver has arrived at an intermediate destination and is waiting for the rider.
ENROUTE_TO_INTERMEDIATE_DESTINATIONThe driver is on their way to an intermediate destination (not the dropoff point).
ENROUTE_TO_DROPOFFThe driver has picked up the rider and is on their way to the next destination.
COMPLETEThe rider has been dropped off and the trip is complete.
CANCELEDThe trip was canceled prior to pickup by the driver, rider, or rideshare provider.
pickup_pointLocation where customer indicates they will be picked up.
actual_pickup_pointThe actual location when and where customer was picked up. This field is for provider to provide feedback on actual pickup information.
actual_pickup_arrival_pointThe actual time and location of the driver arrival at the pickup point. This field is for provider to provide feedback on actual arrival information at the pickup point.
pickup_timeOutput only. Either the estimated future time when the rider(s) will be picked up, or the actual time when they were picked up.
dropoff_pointLocation where customer indicates they will be dropped off.
actual_dropoff_pointThe actual time and location when and where customer was dropped off. This field is for provider to provide feedback on actual dropoff information.
dropoff_timeOutput only. Either the estimated future time when the rider(s) will be dropped off at the final destination, or the actual time when they were dropped off.

Task

In Fleet Engine, a task represents a driver activity that fulfills a scheduled shipment or service for your consumers. You assign tasks to vehicle stop locations where they are to be completed, and the vehicle travels to those stops. A task has two possible states, OPEN or CLOSED. These states indicate whether the task is active or not in the system. As the journey evolves for an active task, you report this to Fleet Engine by updating the vehicle stop associated with the task, which is either ENROUTE or ARRIVED. Once the driver completes tasks and leaves the stop, you remove the stop from the list of stops on the vehicle.
FieldDescription
nameTask name, must be unique
delivery_vehicle_idThe ID of the vehicle that is executing this Task.
typeRequired. Immutable. Defines the type of the Task. For example, a break or shipment.
TYPE_UNSPECIFIED Default, the Task type is unknown.
PICKUP A pickup Task is the action taken for picking up a shipment from a customer. Depot or feeder vehicle pickups should use the SCHEDULED_STOP type.
DELIVERY A delivery Task is the action taken for delivering a shipment to an end customer. Depot or feeder vehicle dropoffs should use the SCHEDULED_STOP type.
SCHEDULED_STOP A scheduled stop Task is used for planning purposes. For example, it could represent picking up or dropping off shipments from feeder vehicles or depots. It shouldn't be used for any shipments that are picked up or dropped off from an end customer.
UNAVAILABLE Newly created trip.A Task that means the Vehicle is not available for service. For example, this can happen when the driver takes a break, or when the vehicle is being refueled.
stateRequired. The current execution state of the Task.
STATE_UNSPECIFIED Default. Used for an unspecified or unrecognized Task state.
OPENEither the Task has not yet been assigned to a delivery vehicle, or the delivery vehicle has not yet passed the Task's assigned vehicle stop.
CLOSEDWhen the vehicle passes the vehicle stop for this Task.
task_outcomeThe outcome of the Task.
TASK_OUTCOME_UNSPECIFIEDThe Task outcome before its value is set.
SUCCEEDEDThe Task completed successfully.
FAILEDEither the Task couldn't be completed, or it was cancelled.
task_outcome_timeThe timestamp that indicates when the Task's outcome was set by the provider.
task_outcome_locationThe location where the Task's outcome was set. This value is updated as part of UpdateTask. If this value isn't explicitly updated by the provider, then Fleet Engine populates it by default with the last known vehicle location (the raw location).
tracking_idImmutable. This field facilitates the storing of an ID so you can avoid using a complicated mapping. You cannot set tracking_id for Tasks of type UNAVAILABLE and SCHEDULED_STOP. These IDs are subject to the following restrictions:
planned_locationThe location where the Task will be completed. Optional for UNAVAILABLE Tasks, but required for all other Tasks.
task_durationRequired. Immutable. The time needed to execute a Task at this location.
target_time_windowThe time window during which the task should be completed.
attributesA list of custom Task attributes. Each attribute must have a unique key.

Documentation

    

Ride Solution Architecture

    

Workflow

    

Delivery Solution Architecture

    

Workflow

    

Driver App