Loading spaces
Types of loading spaces and splitting them into parts
Goodloading supports several kinds of loading space. Each one is defined through the “type” parameter, which can take any of the following values:
- “vehicle” – a truck (the default value)
- “sea” – a sea container
- air containers (2 types):
– “air x” – a container with two slanted sides
– “air y” – a container with one slanted side - “pallet” – a pallet
Every loading space can be divided into a maximum of 2 parts. This is useful, for example, when loading a combination unit, such as vehicles or sea containers. See Example 2: – Parts within loading spaces.
A detailed description of the parameters that define a loading space can be found in the chapter Loading space data (loadingSpaces)
Vehicles
Arranging cargo inside a “vehicle” space
Request
{
"loads": [
{
"quantity": 18,
"name": "load 1",
"length": 120,
"width": 80,
"height": 100,
"weight": 200
},
{
"quantity": 19,
"name": "load 2",
"length": 100,
"width": 70,
"height": 80,
"weight": 160
},
{
"quantity": 20,
"name": "load 3",
"length": 100,
"width": 50,
"height": 80,
"weight": 50
}
],
"loadingSpaces": [
{
"type": "vehicle",
"quantity": 1,
"name": "Solowka 20 EP",
"parts": [
{
"length": 820,
"width": 245,
"height": 240,
"limit": 8000
}
]
}
],
"options": {
}
}
Result

Pallets
Arranging cargo inside a “pallet” space.
Without accounting for the pallet base “baseHeight”
Request
{
"loads": [
{
"quantity": 12,
"name": "load 1",
"length": 40,
"width": 30,
"height": 40,
"weight": 50
},
{
"quantity": 4,
"name": "load 2",
"length": 35,
"width": 20,
"height": 50,
"weight": 60
}
],
"loadingSpaces": [
{
"type": "pallet",
"quantity": 1,
"name": "Pallet",
"parts": [
{
"length": 120,
"width": 80,
"height": 100,
"limit": 1500
}
]
}
],
"options": {
}
}
Result

Accounting for the pallet base “baseHeight”
Request
{
"loads": [
{
"quantity": 12,
"name": "load 1",
"length": 40,
"width": 30,
"height": 40,
"weight": 50
},
{
"quantity": 4,
"name": "load 2",
"length": 35,
"width": 20,
"height": 50,
"weight": 60
}
],
"loadingSpaces": [
{
"type": "pallet",
"quantity": 1,
"name": "Pallet",
"parts": [
{
"baseHeight": 15,
"length": 120,
"width": 80,
"height": 100,
"limit": 1500
}
]
}
],
"options": {
}
}
Result

Sea containers
Arranging cargo inside a “sea” space.
Request:
{
"loads": [
{
"quantity": 18,
"name": "load 1",
"length": 100,
"width": 80,
"height": 50,
"weight": 200
},
{
"quantity": 19,
"name": "load 2",
"length": 100,
"width": 70,
"height": 80,
"weight": 160
},
{
"quantity": 20,
"name": "load 3",
"length": 100,
"width": 50,
"height": 80,
"weight": 100
}
],
"loadingSpaces": [
{
"type": "sea",
"quantity": 1,
"name": "sea",
"parts": [
{
"length": 600,
"width": 244,
"height": 259,
"limit": 22000
}
]
}
],
"options": {
}
}
Result

Air containers
Single-sided air container “air y”.

Defining a container comes down to setting the parameters below. The sample dimensions shown are for an LD2 container.
"parts": [
{
"length": 155,
"width": 153,
"height": 163,
"base": 119,
"heightD": 112,
"limit": 1150
}
],
where the values above map onto the drawing as follows:
- B – “base”
- A – “length”
- C – “hight
- D – “heightD”
Request:
{
"loads": [
{
"quantity": 2,
"name": "load 1",
"length": 120,
"width": 80,
"height": 100,
"weight": 100,
"stacking": true,
"alongFloor": true
},
{
"quantity": 2,
"name": "load 2",
"length": 50,
"width": 20,
"height": 50,
"weight": 400,
"stacking": true,
"alongFloor": true
},
{
"quantity": 2,
"name": "load 3",
"length": 100,
"width": 50,
"height": 100,
"weight": 500,
"stacking": true,
"alongFloor": true
}
],
"loadingSpaces": [
{
"type": "air y",
"quantity": 1,
"name": "zestaw",
"parts": [
{
"length": 155,
"width": 153,
"height": 163,
"base": 119,
"heightD": 112,
"limit": 1150
}
]
}
],
"options": {
}
}
Result:

Double-sided air container “air x”

Defining a container comes down to setting the parameters below. The sample dimensions shown are for an LD3-45 container.
"parts": [
{
"length": 242,
"width": 153,
"height": 114,
"base": 156,
"heightD": 61,
"limit": 1045
}
],
where the values above map onto the drawing as follows:
- B – “base”
- A – “length”
- C – “hight
- D – “heightD”
Request:
{
"loads": [
{
"quantity": 2,
"name": "load 1",
"length": 120,
"width": 80,
"height": 100,
"weight": 100,
"stacking": true,
"alongFloor": true
},
{
"quantity": 2,
"name": "load 2",
"length": 50,
"width": 20,
"height": 50,
"weight": 400,
"stacking": true,
"alongFloor": true
},
{
"quantity": 2,
"name": "load 3",
"length": 100,
"width": 50,
"height": 100,
"weight": 500,
"stacking": true,
"alongFloor": true
}
],
"loadingSpaces": [
{
"type": "air x",
"quantity": 1,
"name": "zestaw",
"parts": [
{
"length": 242,
"width": 153,
"height": 114,
"base": 156,
"heightD": 61,
"limit": 1045
}
]
}
],
"options": {
}
}
Result:

Parts within loading spaces
A loading space can consist of up to 2 parts. For a space of the vehicle type, this corresponds to a combination unit (a tractor with a trailer).
Request
{
"loads": [
{
"quantity": 36,
"name": "load 1",
"length": 120,
"width": 80,
"height": 100,
"weight": 100
},
{
"quantity": 50,
"name": "load 2",
"length": 100,
"width": 70,
"height": 80,
"weight": 80
},
{
"quantity": 30,
"name": "load 3",
"length": 100,
"width": 50,
"height": 80,
"weight": 100
}
],
"loadingSpaces": [
{
"type": "vehicle",
"quantity": 1,
"name": "vehicle",
"parts": [
{
"length": 700,
"width": 240,
"height": 305,
"limit": 6000
},
{ "length": 700,
"width": 240,
"height": 305,
"limit": 6000
}
]
}
],
"options": {
}
}
Result

Loading methods
There are 4 loading methods available, controlled by the “loadingSide” parameter, which can take the following values:
- “back” [default]
- “top”
- “left”
- “right”
The parameter applies to a specific defined part “part” of the loading space, so it can be set differently for each defined part.
In the drawings, the plane through which loading is meant to take place is highlighted in yellow.
Default loading method “back”
Request:
{
"loads": [
{
"quantity": 16,
"name": "load 1",
"color": "#71A34E",
"length": 120,
"width": 80,
"height": 100,
"weight": 50,
"stacking": true
},
{
"quantity": 18,
"name": "load 2",
"color": "#5B9BD5",
"length": 80,
"width": 60,
"height": 100,
"weight": 60,
"stacking": true
},
{
"quantity": 24,
"name": "load 3",
"color": "#FFC000",
"length": 100,
"width": 50,
"height": 100,
"weight": 80,
"stacking": true
}
],
"loadingSpaces": [
{
"quantity": 1,
"name": "Solowka 20 EP",
"parts": [
{
"length": 820,
"width": 245,
"height": 240,
"limit": 8000,
"loadingSide": "back"
}
]
}
],
"options": {
}
}
Result:

Loading from the top “top”
Request:
{
"loads": [
{
"quantity": 16,
"name": "load 1",
"color": "#71A34E",
"length": 120,
"width": 80,
"height": 100,
"weight": 50,
"stacking": true
},
{
"quantity": 18,
"name": "load 2",
"color": "#5B9BD5",
"length": 80,
"width": 60,
"height": 100,
"weight": 60,
"stacking": true
},
{
"quantity": 24,
"name": "load 3",
"color": "#FFC000",
"length": 100,
"width": 50,
"height": 100,
"weight": 80,
"stacking": true
}
],
"loadingSpaces": [
{
"quantity": 1,
"name": "Solowka 20 EP",
"parts": [
{
"length": 820,
"width": 245,
"height": 240,
"limit": 8000,
"loadingSide": "top"
}
]
}
],
"options": {
}
}
Result:

Loading from the left side “left”.
Request:
{
"loads": [
{
"quantity": 16,
"name": "load 1",
"color": "#71A34E",
"length": 120,
"width": 80,
"height": 100,
"weight": 50,
"stacking": true
},
{
"quantity": 18,
"name": "load 2",
"color": "#5B9BD5",
"length": 80,
"width": 60,
"height": 100,
"weight": 60,
"stacking": true
},
{
"quantity": 24,
"name": "load 3",
"color": "#FFC000",
"length": 100,
"width": 50,
"height": 100,
"weight": 80,
"stacking": true
}
],
"loadingSpaces": [
{
"quantity": 1,
"name": "Solowka 20 EP",
"parts": [
{
"length": 820,
"width": 245,
"height": 240,
"limit": 8000,
"loadingSide": "left"
}
]
}
],
"options": {
}
}
Result:

Loading from the right side “right”.
Request:
{
"loads": [
{
"quantity": 16,
"name": "load 1",
"color": "#71A34E",
"length": 120,
"width": 80,
"height": 100,
"weight": 50,
"stacking": true
},
{
"quantity": 18,
"name": "load 2",
"color": "#5B9BD5",
"length": 80,
"width": 60,
"height": 100,
"weight": 60,
"stacking": true
},
{
"quantity": 24,
"name": "load 3",
"color": "#FFC000",
"length": 100,
"width": 50,
"height": 100,
"weight": 80,
"stacking": true
}
],
"loadingSpaces": [
{
"quantity": 1,
"name": "Solowka 20 EP",
"parts": [
{
"length": 820,
"width": 245,
"height": 240,
"limit": 8000,
"loadingSide": "right"
}
]
}
],
"options": {
}
}
Result:

Two parts with different load types – loading a combination unit
Both parts loaded from the rear
Request:
{
"loads": [
{
"quantity": 36,
"name": "load 1",
"color": "#71A34E",
"length": 120,
"width": 80,
"height": 100,
"weight": 100
},
{
"quantity": 50,
"name": "load 2",
"color": "#5B9BD5",
"length": 100,
"width": 70,
"height": 80,
"weight": 80
},
{
"quantity": 30,
"name": "load 3",
"color": "#FFC000",
"length": 100,
"width": 50,
"height": 80,
"weight": 100
}
],
"loadingSpaces": [
{
"type": "vehicle",
"quantity": 1,
"name": "vehicle",
"parts": [
{