mcpField
C
Container Loading Calculator

Container Loading Calculator

Remote
github.com/CindyLiao1106Maps & Travel0Updated 2w ago
Repository

About Container Loading Calculator

Container Loading Calculator is a one-file command-line tool for estimating how many flat-pack units, panels, or crates fit in 20ft and 40HQ containers. It compares volume and payload limits and reports which one constrains the load.

Key features

  1. 01Estimate units per layer and total load
  2. 02Compare volume and payload limits
  3. 03Cap stacking with a maximum layer option
  4. 04Try 90-degree unit rotation

Use cases

  1. 01Estimating flat-pack quantities before booking freight
  2. 02Checking whether a load is limited by volume or weight

Configuration

Remote servers need no local install. Pick your client, then copy the config or install in one click.

Endpointhttps://buildextechnology.com/api/mcp
Copy install command
Claude CodeTerminal
Cursor.cursor/mcp.json
VS Code.vscode/mcp.json
Claude Desktopclaude_desktop_config.json
Windsurf~/.codeium/windsurf/mcp_config.json

Run commands in a terminal; paste JSON into the client’s MCP config and restart. Servers that need sign-in will prompt on first connect.

Tools

1
ParameterTypeRequiredDescription
containerenumYesContainer type: 20gp (20ft general purpose) or 40hq (40ft high cube).20gp | 40hq
maxLayersnumberNoOptional stacking limit: the most layers you are willing to stack. Omit or send 0 for no cap.
unitWidthMmnumberYesPacked width of one unit, in millimetres.
unitHeightMmnumberYesPacked height of one unit, in millimetres.
unitLengthMmnumberYesPacked length of one unit, in millimetres.
unitWeightKgnumberYesWeight of one packed unit, in kilograms.
allowRotationbooleanNoOptional. When true, the tool also tries each unit rotated 90 degrees and keeps the better units-per-layer. Default false, matching the web calculator.

Details

From the project README

Container loading calculator

How many flat-pack units — or panels, or crates — fit in a 20ft or 40HQ container, and what limits the load: volume or payload. No dependencies, one file.

python3 container_loading.py 40hq 2900 2200 600 900
{
  "container": "40ft high cube",
  "units_per_layer": 4,
  "layers": 4,
  "units_by_volume": 16,
  "units_by_payload": 31,
  "units": 16,
  "limited_by": "volume",
  "volume_utilisation_pct": 80.2,
  "payload_utilisation_pct": 50.3
}

The same unit in a 20ft, with a heavier unit, is weight-limited instead:

python3 container_loading.py 20gp 1000 1000 500 5000
# units_by_volume 40 · units_by_payload 5 · units 5 · limited_by "weight"

Options

flagwhat it does
--max-layers Ncaps the number of layers when the packing method limits stacking
--rotatetries rotating each unit 90° and uses whichever fits more per layer

Why it refuses to calculate

If the packed length, width, height or the unit weight is missing, the tool raises an error listing exactly what is missing instead of returning a number. A guessed loading plan is how deposits get lost — the packed height and the unit weight are the two inputs that move the answer most, and both come from the factory packing method.

Container data used

Typical published internal dimensions and payloads. Confirm against the carrier's own data and the actual packing list before booking.

containerinternal L × W × H (mm)payload (kg)
20ft GP5898 × 2352 × 239328,200
40ft HQ12032 × 2352 × 269828,600

Volume utilisation is calculated on the packed envelope (length × width × height of one unit), not on the net product volume.

Web version

Same logic, in the browser, no install: container loading calculator — the tool we use ourselves when quoting flat-pack buildings and aluminium ceiling systems.

Tests

python3 tests/test_loading.py

License

MIT

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.