Warning:
this endpoint is a beta version, input and output contracts might change.
Description
This endpoint computes and assigns the right emissions to each order for a pickup and delivery collection by road (also called milk run).
It uses a road freight CO2 model which is taking into account empty running distances along with load factor between each pickup/delivery location.
This endpoint takes as input : locations and sequencing of the run, origin/destination and weight for each order, and details about the asset (fuel type).
Locations (run)
A run is the itinerary taken, representing the sequence of stops made during the pickup and delivery collection.
It is made of a list of locations which can either be coordinates (longitude, latitude) or UNLOCODES.
The order of the location in the list is important and is used for order definition. The first element in the list is the first stop and has the index 1.
Example : FRMRS has the index 2. The location with index 4 is described as coordinates (longitude, latitude)
"locations": [
"-1.26617431640625,50.79551936692376",
"FRMRS",
"FRQXB",
"8.8330078125,53.88491634606499",
"FRVAF"
]
Orders
Orders define the goods transported. Each order represents a parcel (type = PARCEL
) transported from a location to another during the run. It is mandatory to precise the locations where the parcel is loaded and unloaded.
We use the index (position in the list of locations) for that purpose.
An order must also have a weight (in kilograms).
Example of a parcel of 1500 kg moved from Marseille (FRMRS) to Valence (FRVAF) :
{
"fromIndex": 2,
"toIndex": 5,
"weight": 1500,
"id": "ABC123",
"type": "PARCEL"
}
The endpoint takes a list of orders (1 or more orders). This list must describe all the goods moved during the run.
Details
Details of the truck can be passed. The CO2e calculation currently takes into account the fuel type passed (DIESEL
, PETROL
or LPG
) and the truck size (4 to 60 = GWV 4t to 60t). If not pass, the fuel is by default DIESEL
and the truck size is chosen to be the smallest truck that can contain the orders.
Metadata
You can add any information you want to metadata object and it will be returned to you in the response. Contents of metadata do not influence CO2e calculation.
Response
The response contains co2e emissions (in g) for the entire run (co2e
) and for each individual order (orders
). The emissions are split into WTT and TTW.
The definition of each order is returned back (parameters
) along with the CO2e allocation (percentage of total CO2e).
The response contains an object parameters
which returns back the definition of the run (with indices) and the details of the asset as given.
It also contains an object properties
which details the parameters taken into account during the calculation.
For instance, the distance and the load factor of the truck between each stop are returned as well as the total distance and the allocation method used.
Methodology
The CO2e emissions are computed along the run, for each part of it (leg). We know the weight of the goods transported for each leg and can then compute precise emissions of the truck with a model.
The allocation method we use is described in the norm EN 16258. We use great circle distances between the terminal location (theoretically located at an equidistant point of the first and last location) and the stops of the run.