What Run Exposes

Read and work Run from the API, the Threaded CLI and AI tools: work orders, units, as-built records, stock and plant imports.

What the floor records is only useful if it reaches the systems that need it: an ERP, a quality report, a customer’s request for a build record. Everything Run does in the app is also in the Threaded REST API, so a script, the Threaded CLI or an AI tool can read it and act on it.

#What it is

Run’s API lives under /api/v2/run-format/. Each operation has an ID that starts with run_format_. The same operations are behind the app’s own screens, so they return the same numbers you see on the floor.

#Rules

  • Run is turned on per organization. See Feature Access and Billing.
  • The API uses the same permissions as the app. Reading needs access to the organization. Creating, renumbering, archiving and restoring work orders need Owner or Editor. Station actions are open to everyone who can work stations.
  • Organization service tokens and AI tools use the same operations for Run, except a push. Previewing a push, the push list, reading one push, and Push all need a person signed in as an Owner or Editor. API tokens and the AI assistant can’t use them. See Plant Git and Imports.
  • Every action records who did it, as in the app.
  • Station actions follow the same rules as the app. For example, Complete is refused until every step is recorded, and a refused Complete records nothing.

#In the app

Everything here is what the app shows:

#From the CLI or API

#The operations

AreaOperations
Floorrun_format_floor_map_retrieve, run_format_floor_summary_retrieve, run_format_floor_units_list, run_format_floor_unit_facets_retrieve, run_format_floor_highlight_retrieve, run_format_pull_starts_list
Work ordersrun_format_work_orders_list, run_format_active_work_orders_list, run_format_work_orders_retrieve, run_format_work_orders_create, run_format_work_orders_next_number_retrieve, run_format_feeder_plan_retrieve, run_format_work_orders_number_update
A work order’s recordrun_format_work_order_stations_retrieve, run_format_work_order_preps_list, run_format_work_order_closeouts_list, run_format_work_order_deviations_list, run_format_work_order_scrap_list, run_format_work_order_material_changes_list, run_format_work_order_supplied_by_list
Archivingrun_format_work_orders_archive_preview, run_format_work_orders_archive, run_format_work_orders_archive_batch_preview, run_format_work_orders_archive_batch, run_format_work_orders_restore
Recordsrun_format_record_work_orders_list, run_format_record_units_list
A unitrun_format_units_retrieve, run_format_execution_history_retrieve (build history), run_format_station_materials_retrieve (parts at its station)
Working a stationrun_format_units_save_step_values, run_format_units_complete, run_format_units_complete_with_measurements, run_format_units_save_prep_values, run_format_units_complete_prep, run_format_units_help, run_format_units_resolve, run_format_units_scrap, run_format_units_leave, run_format_units_notes_create, run_format_units_delete_note
Parts at a stationrun_format_units_reserve_serials, run_format_addable_parts_list, run_format_units_add_part, run_format_units_swap_part, run_format_units_scrap_part, run_format_units_delete_part_change
Closeoutsrun_format_work_orders_save_closeout_values, run_format_work_orders_complete_closeout
Stockrun_format_units_scrap_stock, run_format_scrap_stock_serials
Plant and instructionsrun_format_plant_parts_list, run_format_map_nodes_retrieve, run_format_instruction_library_retrieve, run_format_instruction_retrieve
Plant importsrun_format_plant_commits_list, run_format_plant_commits_retrieve, run_format_plant_commits_import, run_format_plant_commits_promote, run_format_plant_import_attempts_retrieve, run_format_plant_import_attempts_logs, run_format_plant_import_attempts_retry, run_format_plant_releases_list, run_format_plant_releases_retrieve

#Parts consumed

What went on each unit is in its build history. run_format_execution_history_retrieve returns each station visit with the parts it consumed: the part, the quantity, and the lot or serial it came from. run_format_station_materials_retrieve returns what’s reserved and consumed at the unit’s current station.

There’s no single call yet for consumption across the whole plant, or for a part’s recipe. Read the units’ build histories, or read the recipe from your plant’s files (see Your Plant as Files).

#The Threaded CLI

The CLI has no Run commands of its own. Use its generic API commands:

threaded api list --search run_format
threaded api describe --operation-id run_format_work_orders_create
threaded api call --operation-id run_format_work_orders_retrieve --path uuid=<work-order-id>
threaded api call --operation-id run_format_record_work_orders_list \
  --path organization_uuid=<organization-id> --query search=wo-0042

Send a request body with --body-json '<json>' or --body-file <path>. describe lists an operation’s parameters and body.

#AI tools

Threaded’s hosted MCP server and the in-app assistant use the same API, through threaded_api_list, threaded_api_describe and threaded_api_call. Ask the assistant about the floor, a work order or a unit’s as-built record, and it calls these operations. In Ask mode, the assistant asks you to approve each call that would change data.

#Reports

Run data isn’t in the data sources Insights pages can query yet. To build a report on it, read it from the API.

#Live updates

The floor in the app updates live over a websocket. The API doesn’t push changes; poll it.