# Optimize a plan Start a task to optimize all assignments in a planning. Endpoint: POST /v1/plannings/{id}/optimize/ Version: 1.0.0 Security: tokenAuth ## Path parameters: - `id` (string, required) ## Request fields (application/json): - `experimental_tools_enabled` (boolean) Whether experimental tools are enabled - `display_window_start` (integer, required) - `display_window_end` (integer, required) - `selected_time` (integer, required) - `forward_window` (integer, required) - `current_time` (integer, required) - `controls` (object, required) - `controls.attach_callback` (boolean) Whether to attach a callback to the solver for live updates - `controls.resolution_balance` (number, required) 0 strives for minimal conflicts whereas 1 strives for minimal overlap - `controls.rule_adherence` (number, required) 0 strives for the goal of the strategy, while 1 strives for optimal rule value - `controls.max_runtime` (integer) Maximum runtime in seconds for the solver, default is 90 seconds - `controls.optimality_gap` (number) The acceptable optimality gap for the solver, default is 0 - `controls.strategy` (string, required) Enum: "standard" - `controls.ignore_freeze_and_past` (boolean) Ignore freeze window and allow edits in the past - `controls.lock_left_edge` (boolean) Lock assignments that cross the left edge of the display window - `controls.lock_right_edge` (boolean) Lock assignments that cross the right edge of the display window - `freeze_window` (integer) Duration in seconds after the current_time during which no changes are allowed. - `workspace_id` (any) Workspace ID for workspace-aware queries. None = mainline only. ## Response 200 fields (application/json): - `task_id` (string, required) ## Response 400 fields (application/json): - `detail` (string, required) ## Response 500 fields (application/json): - `detail` (string, required)