cbm_calculator
Work out the volume of a shipment in cubic metres (CBM) and cubic feet, how much of a 20 ft, 40 ft, 40 ft high cube and 45 ft high cube dry container it fills, how many pieces of one size go into each container by size, and, when weights are given, the chargeable weight for air freight (divisor 6000), courier (5000) and sea freight LCL (1 m3 = 1000 kg). Each line is one piece size: length x width x height, optionally x quantity, optionally x weight of one piece. Up to 20 lines. A malformed line, unit or divisor gets an error, not a volume.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"lines": "<lines>"
},
"name": "cbm_calculator"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lines | Yes | One line per piece size, as LxWxH, LxWxHxQUANTITY or LxWxHxQUANTITYxWEIGHT (3 to 5 values), for example 60x40x50x10x12 for ten cartons of 60 by 40 by 50 at 12 each. The separator inside a line is x, X, × or *. Separate lines with a new line or a semicolon (a comma followed by a space and the next line works too). A comma between digits inside a value is a decimal comma (47,5 is 47.5), with two exceptions that get an error, not a volume: a comma followed by exactly three digits (1,250 could be 1250 or 1.25: send one of them without the comma), and a comma that could also be a line break. Write decimals with a point to be safe. WEIGHT is the weight of one piece. At most 20 lines: put pieces of the same size on one line with a quantity. | |
| divisor | No | Optional. The carrier's own volumetric divisor in cubic centimetres per kilogram, for example 4000. Adds one more chargeable weight to the answer. From 100 to 100000. | |
| may_turn | No | Optional. true when a piece may be laid on its side for the count by size. Default false: the third value of each line stays the height, as for a loaded pallet or a this-side-up carton. | |
| size_unit | No | Unit of the sizes: mm, cm, m, in or ft (also the full names; any case). Default cm. | |
| weight_unit | No | Unit of the weights: kg or lb (also kgs, kilogram(s), lbs, pound(s); any case). Default kg. |