# VRP with Multiple Shifts and Breaks

Specifying the time windows for the jobs and shift times and breaks for the fleet can be combined and used in a more precise and advanced way building the VRPs with multiple shifts and breaks. It means that vehicles' shifts and breaks and the jobs’ execution time can be specified separately for the different days in a single problem. For example, we need to execute several deliveries or pickups within one week or some other period of time. We assume that in our fleet we have vehicles that have some specific shift and break time which is different for the different days of the week. One way to solve such problems is to build separate problems each time specifying your constraints for the vehicles for each day separately. The Tour Planning API allows you to specify such constraints in one problem for the whole week or some other time period of your choice.

The simplest case of using the multiple shifts is when you have a long list of jobs to execute with no time restrictions, and limited number of vehicles. That would mean that obviously that amount of jobs can't be executed within one shift. For this case you can set several shifts to your vehicles to make sure the jobs will be executed within several shifts in the most suitable way.

Lets consider such an example when we have 15 jobs with no time constraints, and 1 vehicle with the capacity = 10, and only 3 hours long shift a day. Obviously, the vehicle will not be able to execute all those jobs at once, so we can specify multiple shifts to it to let it executing the jobs within the following several days in the most advantageous way. To do so, we need to add the dates to the vehicle's shift time. In our case we decided to add 4 shifts:

• Shift 1: 2021-10-23T09:00:00Z - 2021-10-23T12:00:00Z
• Shift 2: 2021-10-24T09:00:00Z - 2021-10-24T12:00:00Z
• Shift 3: 2021-10-25T09:00:00Z - 2021-10-25T12:00:00Z
• Shift 4: 2021-10-26T09:00:00Z - 2021-10-26T12:00:00Z

## Problem

{
"fleet": {
"types": [
{
"id": "Vehicle_1",
"profile": "car",
"costs": {
"fixed": 10.0,
"distance": 0.002,
"time": 0.003
},
"shifts": [
{
"start": {
"time": "2021-10-23T09:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
},
"end": {
"time": "2021-10-23T12:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
}
},
{
"start": {
"time": "2021-10-24T09:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
},
"end": {
"time": "2021-10-24T12:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
}
},
{
"start": {
"time": "2021-10-25T09:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
},
"end": {
"time": "2021-10-25T12:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
}
},
{
"start": {
"time": "2021-10-26T09:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
},
"end": {
"time": "2021-10-26T12:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
}
}
],
"capacity": [
10
],
"amount": 1
}
],
"profiles": [
{
"type": "car",
"name": "car"
}
]
},
"plan": {
"jobs": [
{
"id": "Job_1",
"pickups": [
{
"places": [
{
"location": {
"lat": 51.05238,
"lng": 13.74114
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_2",
"pickups": [
{
"places": [
{
"location": {
"lat": 51.06099,
"lng": 13.75245
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_3",
"pickups": [
{
"places": [
{
"location": {
"lat": 51.08511,
"lng": 13.76875
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_4",
"pickups": [
{
"places": [
{
"location": {
"lat": 51.1323847,
"lng": 13.7779515
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_5",
"pickups": [
{
"places": [
{
"location": {
"lat": 51.11716,
"lng": 13.73054
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_6",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.12308,
"lng": 13.76406
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_7",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_8",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_9",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_10",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.18588,
"lng": 13.52637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_11",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.10588,
"lng": 13.79637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_12",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.01588,
"lng": 13.52637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_13",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.08588,
"lng": 13.62637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_14",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.00088,
"lng": 13.02637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_15",
"deliveries": [
{
"places": [
{
"location": {
"lat": 51.06866,
"lng": 13.77273
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
}
]
}
}


## Solution

As we can see from the solution, the tour was optimized in the way that the jobs will be distributed within the vehicle's 4 shifts and will be executed as follows: 5 jobs on October 23, 5 jobs on October 24, 1 job on October 25, 4 jobs on October 26.

{
"statistic": {
"cost": 673.386,
"distance": 262603,
"duration": 36060,
"times": {
"driving": 15810,
"serving": 20250,
"waiting": 0,
"break": 0
}
},
"tours": [
{
"vehicleId": "Vehicle_1_1",
"typeId": "Vehicle_1",
"stops": [
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-24T09:00:00Z",
"departure": "2021-10-24T09:00:00Z"
},
2
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
],
"distance": 0
},
{
"location": {
"lat": 51.05238,
"lng": 13.74114
},
"time": {
"arrival": "2021-10-24T09:23:14Z",
"departure": "2021-10-24T09:45:44Z"
},
3
],
"activities": [
{
"jobId": "Job_1",
"type": "pickup"
}
],
"distance": 22782
},
{
"location": {
"lat": 51.06099,
"lng": 13.75245
},
"time": {
"arrival": "2021-10-24T09:50:59Z",
"departure": "2021-10-24T10:13:29Z"
},
4
],
"activities": [
{
"jobId": "Job_2",
"type": "pickup"
}
],
"distance": 24694
},
{
"location": {
"lat": 51.06866,
"lng": 13.77273
},
"time": {
"arrival": "2021-10-24T10:16:40Z",
"departure": "2021-10-24T10:39:10Z"
},
3
],
"activities": [
{
"jobId": "Job_15",
"type": "delivery"
}
],
"distance": 27864
},
{
"location": {
"lat": 51.08511,
"lng": 13.76875
},
"time": {
"arrival": "2021-10-24T10:45:22Z",
"departure": "2021-10-24T11:07:52Z"
},
4
],
"activities": [
{
"jobId": "Job_3",
"type": "pickup"
}
],
"distance": 31892
},
{
"location": {
"lat": 51.10588,
"lng": 13.79637
},
"time": {
"arrival": "2021-10-24T11:13:48Z",
"departure": "2021-10-24T11:36:18Z"
},
3
],
"activities": [
{
"jobId": "Job_11",
"type": "delivery"
}
],
"distance": 35237
},
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-24T11:57:06Z",
"departure": "2021-10-24T11:57:06Z"
},
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
],
"distance": 56742
}
],
"statistic": {
"cost": 152.36999999999998,
"distance": 55246,
"duration": 10626,
"times": {
"driving": 3876,
"serving": 6750,
"waiting": 0,
"break": 0
}
},
"shiftIndex": 1
},
{
"vehicleId": "Vehicle_1_1",
"typeId": "Vehicle_1",
"stops": [
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-26T09:00:00Z",
"departure": "2021-10-26T09:00:00Z"
},
2
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
],
"distance": 0
},
{
"location": {
"lat": 51.18588,
"lng": 13.52637
},
"time": {
"arrival": "2021-10-26T09:28:01Z",
"departure": "2021-10-26T09:50:31Z"
},
1
],
"activities": [
{
"jobId": "Job_10",
"type": "delivery"
}
],
"distance": 9299
},
{
"location": {
"lat": 51.1323847,
"lng": 13.7779515
},
"time": {
"arrival": "2021-10-26T10:16:25Z",
"departure": "2021-10-26T10:38:55Z"
},
2
],
"activities": [
{
"jobId": "Job_4",
"type": "pickup"
}
],
"distance": 22650
},
{
"location": {
"lat": 51.12308,
"lng": 13.76406
},
"time": {
"arrival": "2021-10-26T10:43:05Z",
"departure": "2021-10-26T11:05:35Z"
},
1
],
"activities": [
{
"jobId": "Job_6",
"type": "delivery"
}
],
"distance": 27842
},
{
"location": {
"lat": 51.11716,
"lng": 13.73054
},
"time": {
"arrival": "2021-10-26T11:11:20Z",
"departure": "2021-10-26T11:33:50Z"
},
2
],
"activities": [
{
"jobId": "Job_5",
"type": "pickup"
}
],
"distance": 48395
},
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-26T11:49:06Z",
"departure": "2021-10-26T11:49:06Z"
},
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
],
"distance": 68746
}
],
"statistic": {
"cost": 180.524,
"distance": 70043,
"duration": 10146,
"times": {
"driving": 4746,
"serving": 5400,
"waiting": 0,
"break": 0
}
},
"shiftIndex": 3
},
{
"vehicleId": "Vehicle_1_1",
"typeId": "Vehicle_1",
"stops": [
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-23T09:00:00Z",
"departure": "2021-10-23T09:00:00Z"
},
5
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
],
"distance": 0
},
{
"location": {
"lat": 51.08588,
"lng": 13.62637
},
"time": {
"arrival": "2021-10-23T09:13:53Z",
"departure": "2021-10-23T09:36:23Z"
},
4
],
"activities": [
{
"jobId": "Job_13",
"type": "delivery"
}
],
"distance": 18700
},
{
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"arrival": "2021-10-23T09:51:23Z",
"departure": "2021-10-23T10:58:53Z"
},
1
],
"activities": [
{
"jobId": "Job_9",
"type": "delivery",
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"start": "2021-10-23T09:51:23Z",
"end": "2021-10-23T10:13:53Z"
}
},
{
"jobId": "Job_7",
"type": "delivery",
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"start": "2021-10-23T10:13:53Z",
"end": "2021-10-23T10:36:23Z"
}
},
{
"jobId": "Job_8",
"type": "delivery",
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"start": "2021-10-23T10:36:23Z",
"end": "2021-10-23T10:58:53Z"
}
}
],
"distance": 22771
},
{
"location": {
"lat": 51.01588,
"lng": 13.52637
},
"time": {
"arrival": "2021-10-23T11:20:08Z",
"departure": "2021-10-23T11:42:38Z"
},
0
],
"activities": [
{
"jobId": "Job_12",
"type": "delivery"
}
],
"distance": 25067
},
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-23T11:55:00Z",
"departure": "2021-10-23T11:55:00Z"
},
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
],
"distance": 44098
}
],
"statistic": {
"cost": 148.944,
"distance": 53722,
"duration": 10500,
"times": {
"driving": 3750,
"serving": 6750,
"waiting": 0,
"break": 0
}
},
"shiftIndex": 0
},
{
"vehicleId": "Vehicle_1_1",
"typeId": "Vehicle_1",
"stops": [
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-25T09:00:00Z",
"departure": "2021-10-25T09:00:00Z"
},
1
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
],
"distance": 0
},
{
"location": {
"lat": 51.00088,
"lng": 13.02637
},
"time": {
"arrival": "2021-10-25T09:28:45Z",
"departure": "2021-10-25T09:51:15Z"
},
0
],
"activities": [
{
"jobId": "Job_14",
"type": "delivery"
}
],
"distance": 41711
},
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-25T10:19:48Z",
"departure": "2021-10-25T10:19:48Z"
},
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
],
"distance": 83583
}
],
"statistic": {
"cost": 191.548,
"distance": 83592,
"duration": 4788,
"times": {
"driving": 3438,
"serving": 1350,
"waiting": 0,
"break": 0
}
},
"shiftIndex": 2
}
]
}


Additionally, let's consider a situation when we need to execute 10 jobs with the specific time constraints by a vehicle that has different time shifts during those days. In this case, we should not only specify the vehicle’s shifts time but also the dates for those shifts.

In our specific case, the vehicle is available:

• from 8:00 to 21:00 on October 23
• from 8:00 to 15:00 on October 24
• from 10:00 to 21:00 on October 25

So the shifts will be specified depending on the exact dates. The same approach will be applied for specifying the jobs' time windows - additionally to the time, we should specify the date if we need those jobs to be executed on the specific dates.

Considering those constraints, this problem will look as follows:

{
"fleet": {
"types": [
{
"id": "Vehicle_1",
"profile": "car",
"costs": {
"fixed": 10.0,
"distance": 0.002,
"time": 0.003
},
"shifts": [
{
"start": {
"time": "2021-10-23T08:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
},
"end": {
"time": "2021-10-23T21:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
}
},
{
"start": {
"time": "2021-10-24T08:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
},
"end": {
"time": "2021-10-24T21:15:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
}
},
{
"start": {
"time": "2021-10-25T10:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
},
"end": {
"time": "2021-10-25T21:00:00Z",
"location": {
"lat": 51.059188,
"lng": 13.540317
}
}
}
],
"capacity": [
10
],
"amount": 1
}
],
"profiles": [
{
"type": "car",
"name": "car"
}
]
},
"plan": {
"jobs": [
{
"id": "Job_1",
"pickups": [
{
"places": [
{
"times": [
[
"2021-10-23T08:30:00Z",
"2021-10-23T09:00:00Z"
]
],
"location": {
"lat": 51.05238,
"lng": 13.74114
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_2",
"pickups": [
{
"places": [
{
"times": [
[
"2021-10-23T09:05:00Z",
"2021-10-23T09:30:00Z"
]
],
"location": {
"lat": 51.06099,
"lng": 13.75245
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_3",
"pickups": [
{
"places": [
{
"times": [
[
"2021-10-23T09:35:00Z",
"2021-10-23T10:00:00Z"
]
],
"location": {
"lat": 51.08511,
"lng": 13.76875
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_4",
"pickups": [
{
"places": [
{
"times": [
[
"2021-10-23T10:05:00Z",
"2021-10-23T10:30:00Z"
]
],
"location": {
"lat": 51.1323847,
"lng": 13.7779515
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_5",
"pickups": [
{
"places": [
{
"times": [
[
"2021-10-23T10:35:00Z",
"2021-10-23T11:00:00Z"
]
],
"location": {
"lat": 51.11716,
"lng": 13.73054
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_6",
"deliveries": [
{
"places": [
{
"times": [
[
"2021-10-24T15:01:00Z",
"2021-10-24T15:30:00Z"
]
],
"location": {
"lat": 51.12308,
"lng": 13.76406
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_7",
"deliveries": [
{
"places": [
{
"times": [
[
"2021-10-24T15:35:00Z",
"2021-10-24T16:05:00Z"
]
],
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_8",
"deliveries": [
{
"places": [
{
"times": [
[
"2021-10-24T16:10:00Z",
"2021-10-24T16:40:00Z"
]
],
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_9",
"deliveries": [
{
"places": [
{
"times": [
[
"2021-10-25T16:45:00Z",
"2021-10-25T17:10:00Z"
]
],
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
},
{
"id": "Job_10",
"deliveries": [
{
"places": [
{
"times": [
[
"2021-10-25T17:15:00Z",
"2021-10-25T17:40:00Z"
]
],
"location": {
"lat": 51.06866,
"lng": 13.77273
},
"duration": 1350
}
],
"demand": [
1
]
}
]
}
}
]
}
}


From this solution, we can see that the tour was optimized for solving the specific jobs considering their dates and time windows, and vehicle's shifts' schedule within those dates.

• jobs_9 and job_10 will be executed on October 25
• job_1, job_2, job_3, job_4, and job_5 - on October 23
• job_6 job_7 job_8 - on October 24

In the same way, you can plan your tours, for up to 7 non-overlapping time periods/shifts.

{
"statistic": {
"cost": 403.375,
"distance": 151859,
"duration": 23219,
"times": {
"driving": 9719,
"serving": 13500,
"waiting": 0,
"break": 0
}
},
"tours": [
{
"vehicleId": "Vehicle_1_1",
"typeId": "Vehicle_1",
"stops": [
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-23T08:00:00Z",
"departure": "2021-10-23T08:14:01Z"
},
0
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
],
"distance": 0
},
{
"location": {
"lat": 51.05238,
"lng": 13.74114
},
"time": {
"arrival": "2021-10-23T08:37:15Z",
"departure": "2021-10-23T08:59:45Z"
},
1
],
"activities": [
{
"jobId": "Job_1",
"type": "pickup"
}
],
"distance": 19039
},
{
"location": {
"lat": 51.06099,
"lng": 13.75245
},
"time": {
"arrival": "2021-10-23T09:05:00Z",
"departure": "2021-10-23T09:27:30Z"
},
2
],
"activities": [
{
"jobId": "Job_2",
"type": "pickup"
}
],
"distance": 21409
},
{
"location": {
"lat": 51.08511,
"lng": 13.76875
},
"time": {
"arrival": "2021-10-23T09:35:15Z",
"departure": "2021-10-23T09:57:45Z"
},
3
],
"activities": [
{
"jobId": "Job_3",
"type": "pickup"
}
],
"distance": 25164
},
{
"location": {
"lat": 51.1323847,
"lng": 13.7779515
},
"time": {
"arrival": "2021-10-23T10:08:35Z",
"departure": "2021-10-23T10:31:05Z"
},
4
],
"activities": [
{
"jobId": "Job_4",
"type": "pickup"
}
],
"distance": 31719
},
{
"location": {
"lat": 51.11716,
"lng": 13.73054
},
"time": {
"arrival": "2021-10-23T10:39:21Z",
"departure": "2021-10-23T11:01:51Z"
},
5
],
"activities": [
{
"jobId": "Job_5",
"type": "pickup"
}
],
"distance": 37289
},
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-23T11:17:07Z",
"departure": "2021-10-23T11:17:07Z"
},
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
],
"distance": 56968
}
],
"statistic": {
"cost": 156.89999999999998,
"distance": 56971,
"duration": 10986,
"times": {
"driving": 4236,
"serving": 6750,
"waiting": 0,
"break": 0
}
},
"shiftIndex": 0
},
{
"vehicleId": "Vehicle_1_1",
"typeId": "Vehicle_1",
"stops": [
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-24T08:00:00Z",
"departure": "2021-10-24T14:56:47Z"
},
3
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
],
"distance": 0
},
{
"location": {
"lat": 51.12308,
"lng": 13.76406
},
"time": {
"arrival": "2021-10-24T15:15:39Z",
"departure": "2021-10-24T15:38:09Z"
},
2
],
"activities": [
{
"jobId": "Job_6",
"type": "delivery"
}
],
"distance": 22782
},
{
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"arrival": "2021-10-24T15:47:30Z",
"departure": "2021-10-24T16:32:30Z"
},
0
],
"activities": [
{
"jobId": "Job_7",
"type": "delivery",
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"start": "2021-10-24T15:47:30Z",
"end": "2021-10-24T16:10:00Z"
}
},
{
"jobId": "Job_8",
"type": "delivery",
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"start": "2021-10-24T16:10:00Z",
"end": "2021-10-24T16:32:30Z"
}
}
],
"distance": 30830
},
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-24T16:48:33Z",
"departure": "2021-10-24T16:48:33Z"
},
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
],
"distance": 50260
}
],
"statistic": {
"cost": 130.63400000000001,
"distance": 50258,
"duration": 6706,
"times": {
"driving": 2656,
"serving": 4050,
"waiting": 0,
"break": 0
}
},
"shiftIndex": 1
},
{
"vehicleId": "Vehicle_1_1",
"typeId": "Vehicle_1",
"stops": [
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-25T10:00:00Z",
"departure": "2021-10-25T16:29:32Z"
},
2
],
"activities": [
{
"jobId": "departure",
"type": "departure"
}
],
"distance": 0
},
{
"location": {
"lat": 51.08588,
"lng": 13.72637
},
"time": {
"arrival": "2021-10-25T16:45:00Z",
"departure": "2021-10-25T17:07:30Z"
},
1
],
"activities": [
{
"jobId": "Job_9",
"type": "delivery"
}
],
"distance": 18700
},
{
"location": {
"lat": 51.06866,
"lng": 13.77273
},
"time": {
"arrival": "2021-10-25T17:16:11Z",
"departure": "2021-10-25T17:38:41Z"
},
0
],
"activities": [
{
"jobId": "Job_10",
"type": "delivery"
}
],
"distance": 23122
},
{
"location": {
"lat": 51.059188,
"lng": 13.540317
},
"time": {
"arrival": "2021-10-25T18:01:39Z",
"departure": "2021-10-25T18:01:39Z"
},
0
],
"activities": [
{
"jobId": "arrival",
"type": "arrival"
}
],
"distance": 44627
}
],
"statistic": {
"cost": 115.84100000000001,
"distance": 44630,
"duration": 5527,
"times": {
"driving": 2827,
"serving": 2700,
"waiting": 0,
"break": 0
}
},
"shiftIndex": 2
}
]
}