{"inputSchema":{"type":"object","required":["skus","locations"],"additionalProperties":false,"properties":{"skus":{"type":"array","minItems":1,"maxItems":2000,"description":"The SKUs to place.","items":{"type":"object","required":["sku","picks_per_period"],"additionalProperties":false,"properties":{"sku":{"type":"string","minLength":1,"maxLength":64,"description":"Your SKU identifier. Must be unique within the request."},"picks_per_period":{"type":"number","minimum":0,"maximum":1000000,"description":"Number of picks in the period you are planning for. The period itself is yours; it only has to be the same for every SKU."},"weight_kg":{"type":"number","minimum":0,"maximum":100000,"description":"Weight of one storage unit in kilograms. Checked against max_weight_kg of the location."},"volume_l":{"type":"number","minimum":0,"maximum":100000,"description":"Volume of one storage unit in litres. Checked against max_volume_l of the location."},"current_location_id":{"type":"string","maxLength":64,"description":"Where the SKU sits today. Only used for the before-and-after comparison."}}}},"locations":{"type":"array","minItems":1,"maxItems":5000,"description":"The storage locations available for the plan.","items":{"type":"object","required":["location_id","travel_distance_m"],"additionalProperties":false,"properties":{"location_id":{"type":"string","minLength":1,"maxLength":64,"description":"Your location identifier. Must be unique within the request."},"travel_distance_m":{"type":"number","minimum":0,"maximum":100000,"description":"One-way walking distance in metres from the pick-and-drop point to this location."},"zone":{"type":"string","maxLength":64,"description":"Free-text zone label, passed through unchanged."},"max_weight_kg":{"type":"number","minimum":0,"maximum":100000,"description":"Weight limit of this location in kilograms. Omitted means no limit."},"max_volume_l":{"type":"number","minimum":0,"maximum":100000,"description":"Volume limit of this location in litres. Omitted means no limit."}}}},"affinities":{"type":"array","maxItems":5000,"description":"Pairs of SKUs that are picked together. Used to slot them near each other.","items":{"type":"object","required":["sku_a","sku_b","joint_picks_per_period"],"additionalProperties":false,"properties":{"sku_a":{"type":"string","minLength":1,"maxLength":64},"sku_b":{"type":"string","minLength":1,"maxLength":64},"joint_picks_per_period":{"type":"number","minimum":0,"maximum":1000000,"description":"How often the two are picked in the same order, in the same period as picks_per_period."}}}},"abc_share_pct":{"type":"array","minItems":2,"maxItems":2,"default":[80,95],"items":{"type":"number","minimum":0,"maximum":100},"description":"Cumulative pick share in percent that ends class A and class B. First value must be smaller than the second."},"return_trip":{"type":"boolean","default":true,"description":"Whether the picker walks back the same way. True doubles every distance."}}},"outputSchema":{"type":"object","properties":{"assignments":{"type":"array"},"unassigned_skus":{"type":"array"},"unused_locations":{"type":"array"},"abc_summary":{"type":"object"},"affinity_groups":{"type":"array"},"travel":{"type":"object"},"method":{"type":"object"},"unavailable_fields":{"type":"array"}}},"priceModel":null,"requestExample":{"skus":[{"sku":"A-100","picks_per_period":420,"weight_kg":2.5,"volume_l":8,"current_location_id":"L-07"},{"sku":"A-101","picks_per_period":380,"weight_kg":1.2,"volume_l":5,"current_location_id":"L-01"},{"sku":"B-200","picks_per_period":95,"weight_kg":18,"volume_l":40,"current_location_id":"L-03"},{"sku":"C-300","picks_per_period":12,"weight_kg":0.4,"volume_l":2,"current_location_id":"L-02"}],"locations":[{"location_id":"L-01","travel_distance_m":6,"zone":"front","max_weight_kg":25,"max_volume_l":60},{"location_id":"L-02","travel_distance_m":9,"zone":"front","max_weight_kg":25,"max_volume_l":60},{"location_id":"L-03","travel_distance_m":22,"zone":"middle","max_weight_kg":40,"max_volume_l":120},{"location_id":"L-07","travel_distance_m":48,"zone":"back","max_weight_kg":40,"max_volume_l":120}],"affinities":[{"sku_a":"A-100","sku_b":"A-101","joint_picks_per_period":210}],"abc_share_pct":[80,95],"return_trip":true},"price_usdc":"0.005","example_request":{"skus":[{"sku":"A-100","picks_per_period":420,"weight_kg":2.5,"volume_l":8,"current_location_id":"L-07"},{"sku":"A-101","picks_per_period":380,"weight_kg":1.2,"volume_l":5,"current_location_id":"L-01"},{"sku":"B-200","picks_per_period":95,"weight_kg":18,"volume_l":40,"current_location_id":"L-03"},{"sku":"C-300","picks_per_period":12,"weight_kg":0.4,"volume_l":2,"current_location_id":"L-02"}],"locations":[{"location_id":"L-01","travel_distance_m":6,"zone":"front","max_weight_kg":25,"max_volume_l":60},{"location_id":"L-02","travel_distance_m":9,"zone":"front","max_weight_kg":25,"max_volume_l":60},{"location_id":"L-03","travel_distance_m":22,"zone":"middle","max_weight_kg":40,"max_volume_l":120},{"location_id":"L-07","travel_distance_m":48,"zone":"back","max_weight_kg":40,"max_volume_l":120}],"affinities":[{"sku_a":"A-100","sku_b":"A-101","joint_picks_per_period":210}],"abc_share_pct":[80,95],"return_trip":true},"serviceName":"slotting_plan","tags":["warehouse","logistics","slotting","optimization"],"outputExample":{"assignments":[{"sku":"A-100","location_id":"L-01","zone":"front","abc_class":"A","affinity_group":"A-100","picks_per_period":420,"travel_distance_m":6,"planned_distance_m":5040,"current_location_id":"L-07","current_travel_distance_m":48,"current_distance_m":40320,"moved":true,"skipped_locations_on_weight":0,"skipped_locations_on_volume":0},{"sku":"A-101","location_id":"L-02","zone":"front","abc_class":"B","affinity_group":"A-100","picks_per_period":380,"travel_distance_m":9,"planned_distance_m":6840,"current_location_id":"L-01","current_travel_distance_m":6,"current_distance_m":4560,"moved":true,"skipped_locations_on_weight":0,"skipped_locations_on_volume":0},{"sku":"B-200","location_id":"L-03","zone":"middle","abc_class":"C","affinity_group":"B-200","picks_per_period":95,"travel_distance_m":22,"planned_distance_m":4180,"current_location_id":"L-03","current_travel_distance_m":22,"current_distance_m":4180,"moved":false,"skipped_locations_on_weight":0,"skipped_locations_on_volume":0},{"sku":"C-300","location_id":"L-07","zone":"back","abc_class":"C","affinity_group":"C-300","picks_per_period":12,"travel_distance_m":48,"planned_distance_m":1152,"current_location_id":"L-02","current_travel_distance_m":9,"current_distance_m":216,"moved":true,"skipped_locations_on_weight":0,"skipped_locations_on_volume":0}],"unassigned_skus":[],"unused_locations":[],"abc_summary":{"thresholds_pct":[80,95],"counts":{"A":1,"B":1,"C":2},"total_picks_per_period":907,"basis":"cumulative share of picks_per_period, descending"},"affinity_groups":[{"group_id":"A-100","skus":["A-100","A-101"],"picks_per_period":800}],"affinity_merges_rejected":[],"travel":{"unit":"m","return_trip":true,"planned_distance_m":17212,"current_distance_m":49276,"saving_m":32064,"saving_pct":65.07,"skus_without_current_location":[],"formula":"sum over assigned SKUs of picks_per_period * travel_distance_m * (return_trip ? 2 : 1)"},"method":{"assignment":"affinity clusters ordered by total picks, SKUs inside a cluster by picks, then greedy first-fit onto the shortest free location that satisfies max_weight_kg and max_volume_l","abc":"cumulative pick share against abc_share_pct","affinity":"union-find over joint_picks_per_period, descending, merge rejected above max_cluster_size 24","deterministic":true,"optimality":"heuristic, not a proven optimum: full slotting is a quadratic assignment problem. Every tie is broken by identifier so the same request always returns the same plan.","limits":{"max_skus":2000,"max_locations":5000,"max_affinities":5000,"max_cluster_size":24}},"unavailable_fields":[]}}