{"openapi":"3.1.0","info":{"title":"Cable Tray Fill API","version":"1.0.0","description":"Cable-tray fill engineering maths as an API, computed locally and deterministically from NEC Article 392 — the allowable-fill, single-layer and tray-width numbers an electrician, estimator or designer runs for a tray run. The fill endpoint applies NEC 392.22(A)(1) Column 1 for multiconductor power and lighting cables no larger than 4/0 in a ladder or ventilated-bottom tray: the total cable cross-sectional area is capped at the tray width × 7/6, so a 12-inch tray allows 14 in² — sum every cable's csa, get the percentage fill and whether it is within code, with the spare area left. The large-cable endpoint covers cables 4/0 and larger, which must lie in a single layer with the sum of their diameters not exceeding the tray width — no stacking — so it returns the spare width and the code check. The min-width endpoint inverts the rule to size the tray: minimum width = cable area × 6/7, rounded up to a standard 6/9/12/18/24/30/36-inch width, leaving room for spare capacity and future cables. Everything is computed locally and deterministically, so it is instant and private. Ideal for electrical-design and estimating tools, industrial and OSP utilities, and code-check calculators. Pure local computation — no key, no third-party service, instant. Ladder/ventilated trays; solid-bottom and mixed fills use the other NEC columns, and ampacity must be derated for fill. 3 compute endpoints. For conduit and box fill use a conduit API.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/cabletray-api","description":"oanor gateway"}],"tags":[{"name":"Tray"},{"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/fill":{"get":{"operationId":"get_v1_fill","tags":["Tray"],"summary":"Allowable fill for ≤4/0 cables","description":"","parameters":[{"name":"tray_width_in","in":"query","required":true,"description":"Tray inside width (in)","schema":{"type":"string"},"example":"12"},{"name":"cable_area_in2","in":"query","required":true,"description":"Total cable cross-sectional area (in²)","schema":{"type":"string"},"example":"10"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK"},"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/large-cable":{"get":{"operationId":"get_v1_large_cable","tags":["Tray"],"summary":"Single-layer check for ≥4/0 cables","description":"","parameters":[{"name":"tray_width_in","in":"query","required":true,"description":"Tray inside width (in)","schema":{"type":"string"},"example":"12"},{"name":"sum_of_diameters_in","in":"query","required":true,"description":"Sum of cable diameters (in)","schema":{"type":"string"},"example":"10"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK"},"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/min-width":{"get":{"operationId":"get_v1_min_width","tags":["Tray"],"summary":"Minimum tray width for a bundle","description":"","parameters":[{"name":"cable_area_in2","in":"query","required":true,"description":"Total cable cross-sectional area (in²)","schema":{"type":"string"},"example":"10"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK"},"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"},"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":5500,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":1140,"monthly_call_quota":56000,"rps_limit":6,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":3620,"monthly_call_quota":237000,"rps_limit":15,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":11150,"monthly_call_quota":1180000,"rps_limit":40,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/cabletray-api"}