{"openapi":"3.1.0","info":{"title":"Freight & LTL API","version":"1.0.0","description":"Freight and logistics maths as an API, computed locally and deterministically — the LTL freight class and load-planning numbers a shipper, broker or warehouse works to. The freight-class endpoint computes the density (weight ÷ cubic feet) of a shipment and maps it to the NMFC density-based freight class — the 18-band scale from class 50 (densest, cheapest) to 500 (lightest) — so a 200 lb pallet measuring 48×40×48 inches is 3.75 lb/ft³ and lands in class 250. The pallet endpoint palletizes a carton: it takes the better of the two footprint orientations for cartons per layer, fills the usable stack height in layers, and returns the cartons per pallet limited by the smaller of the cube and the weight cap, with the cargo weight and stack height (defaulting to a 48×40 GMA pallet). The container endpoint loads a 40-foot high-cube container (or any dimensions you give): how many units fit by axis-aligned stacking and by payload, which one is the limiting factor, the total weight and the cube utilisation. Everything is computed locally and deterministically, so it is instant and private. Ideal for logistics, freight-brokerage, 3PL, warehouse-management and supply-chain app developers, LTL rating and load-planning tools, and shipping calculators. Pure local computation — no key, no third-party service, instant. Imperial units (inches, pounds, cubic feet) as the NMFC scale is US-based. Live, nothing stored. 3 compute endpoints. This is freight-class and load-planning maths; for single-parcel courier billing weight use a dimensional-weight API.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/freight-api","description":"oanor gateway"}],"tags":[{"name":"Freight"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/container":{"get":{"operationId":"get_v1_container","tags":["Freight"],"summary":"Units per container","description":"","parameters":[{"name":"item_length","in":"query","required":true,"description":"Item length (in)","schema":{"type":"string"},"example":"48"},{"name":"item_width","in":"query","required":true,"description":"Item width (in)","schema":{"type":"string"},"example":"40"},{"name":"item_height","in":"query","required":true,"description":"Item height (in)","schema":{"type":"string"},"example":"48"},{"name":"item_weight","in":"query","required":true,"description":"Item weight (lb)","schema":{"type":"string"},"example":"960"},{"name":"container_length","in":"query","required":false,"description":"Container length (default 472)","schema":{"type":"string"}},{"name":"container_width","in":"query","required":false,"description":"Container width (default 92.5)","schema":{"type":"string"}},{"name":"container_height","in":"query","required":false,"description":"Container height (default 102)","schema":{"type":"string"}},{"name":"max_payload","in":"query","required":false,"description":"Max payload (default 58000)","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"Axis-aligned stacking (no rotation): units fit along each axis, capped by the payload. Volume utilisation shows the unused cube — palletised or rotated loads may fit more.","inputs":{"item_width":40,"item_height":48,"item_length":48,"item_weight":960,"max_payload":58000,"container_width":92.5,"container_height":102,"container_length":472},"total_weight":34560,"units_loadable":36,"limiting_factor":"volume","units_by_volume":36,"units_by_weight":60,"volume_utilization_percent":74.5008},"meta":{"timestamp":"2026-06-05T21:48:47.382Z","request_id":"bfc5d266-3a2c-4359-85fb-0ae911a069ae"},"status":"ok","message":"Container loading","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/freight-class":{"get":{"operationId":"get_v1_freight_class","tags":["Freight"],"summary":"NMFC LTL freight class","description":"","parameters":[{"name":"weight","in":"query","required":true,"description":"Weight (lb)","schema":{"type":"string"},"example":"200"},{"name":"length","in":"query","required":false,"description":"Length (in)","schema":{"type":"string"},"example":"48"},{"name":"width","in":"query","required":false,"description":"Width (in)","schema":{"type":"string"},"example":"40"},{"name":"height","in":"query","required":false,"description":"Height (in)","schema":{"type":"string"},"example":"48"},{"name":"cubic_feet","in":"query","required":false,"description":"Cubic feet (instead of dims)","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"LTL freight class from the NMFC density scale: density = weight / cubic feet. Denser freight is a lower (cheaper) class — 50 is densest, 500 lightest.","inputs":{"width":40,"height":48,"length":48,"weight":200},"cubic_feet":53.3333,"freight_class":250,"density_lb_per_cuft":3.75},"meta":{"timestamp":"2026-06-05T21:48:47.468Z","request_id":"6685750f-0f28-40ac-a2be-a5c6b8cfc00b"},"status":"ok","message":"Freight class","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/pallet":{"get":{"operationId":"get_v1_pallet","tags":["Freight"],"summary":"Cartons per pallet","description":"","parameters":[{"name":"carton_length","in":"query","required":true,"description":"Carton length (in)","schema":{"type":"string"},"example":"12"},{"name":"carton_width","in":"query","required":true,"description":"Carton width (in)","schema":{"type":"string"},"example":"12"},{"name":"carton_height","in":"query","required":true,"description":"Carton height (in)","schema":{"type":"string"},"example":"12"},{"name":"carton_weight","in":"query","required":true,"description":"Carton weight (lb)","schema":{"type":"string"},"example":"20"},{"name":"pallet_length","in":"query","required":false,"description":"Pallet length (default 48)","schema":{"type":"string"}},{"name":"pallet_width","in":"query","required":false,"description":"Pallet width (default 40)","schema":{"type":"string"}},{"name":"max_height","in":"query","required":false,"description":"Max stack height (default 60)","schema":{"type":"string"}},{"name":"max_weight","in":"query","required":false,"description":"Max cargo weight (default 2200)","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"Cartons per layer takes the better of the two footprint orientations; layers fill the usable height. The pallet holds the smaller of the cube and weight limits.","inputs":{"max_height":60,"max_weight":2200,"carton_width":12,"pallet_width":40,"carton_height":12,"carton_length":12,"carton_weight":20,"pallet_length":48},"layers":4,"stack_height":54,"cartons_by_cube":48,"limiting_factor":"cube","cartons_by_weight":110,"cartons_per_layer":12,"cartons_per_pallet":48,"pallet_cargo_weight":960},"meta":{"timestamp":"2026-06-05T21:48:47.557Z","request_id":"1a03e167-98f9-4354-9d2f-799d747e011c"},"status":"ok","message":"Palletization","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Spec","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"notes":"Imperial units: inches, pounds, cubic feet (the NMFC class scale is US-based). Pallet defaults to a 48×40 GMA pallet; container to a 40 ft high-cube. For single-parcel courier billing weight use a dimensional-weight API.","service":"freight-api","endpoints":{"GET /v1/meta":"This document.","GET /v1/pallet":"Cartons per pallet by cube and by weight, with layers and stack height.","GET /v1/container":"Units per container/trailer by stacking and by payload, with cube utilisation.","GET /v1/freight-class":"NMFC LTL freight class from weight and dimensions (or cubic feet)."},"description":"Freight & logistics maths: LTL freight class from density (NMFC scale), palletization and container/trailer loading."},"meta":{"timestamp":"2026-06-05T21:48:47.652Z","request_id":"8e80e95c-99a9-49ae-a618-8ea7b0eeec09"},"status":"ok","message":"Meta","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":4050,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":660,"monthly_call_quota":42000,"rps_limit":6,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":1750,"monthly_call_quota":197000,"rps_limit":15,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":5250,"monthly_call_quota":1145000,"rps_limit":40,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/freight-api"}