REST API

Manufacturing API

Manage bills of materials and production orders.

Generated from the Celerp 2.4.0 OpenAPI schema, 16 September 2026.

GET /manufacturing

List Orders

List production runs, newest first. q matches the run id, description, source document (doc number) and output SKUs; `status` filters by canonical status or the pseudo-status "incomplete" (planned/in_progress/on_hold); dates filter on creation date. Runs are NOT auto-created from documents in the product-centric model; demand lives on the To-Make board (GET /manufacturing/to-make) and a run is created when you choose to produce.

Parameters

NameInRequiredTypeDescription
qquery--string, optional--
statusquery--string, optional--
date_fromquery--string, optional--
date_toquery--string, optional--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X GET http://localhost:8000/manufacturing \
  -H "Authorization: Bearer $TOKEN"

POST /manufacturing

Create Order

Request body

FieldTypeRequiredDescription
descriptionstringyesDescription
order_typestring--Order Type
inputsarray of MfgInput--Inputs
expected_outputsarray of MfgOutput--Expected Outputs
location_idstring, optional--Location Id
assigned_tostring, optional--Assigned To
due_datestring, optional--Due Date
estimated_costnumber, optional--Estimated Cost
notesstring, optional--Notes
idempotency_keystring, optional--Idempotency Key

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/bulk-action

Bulk Run Action

Apply a lifecycle action (start/issue/complete/hold/resume/cancel) to many runs at once. Runs in a state that does not permit the action are skipped (not a hard error).

Request body

FieldTypeRequiredDescription
run_idsarray of string--Run Ids
actionstring--Action

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/bulk-action \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/import/batch

Batch Import Manufacturing

Request body

FieldTypeRequiredDescription
recordsarray of MfgImportRecordyesRecords

Responses

StatusDescriptionBody
200Successful Responsecelerp_manufacturing__routes__BatchImportResult
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/import/batch \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/items/{item_id}/build

Build Item

Create a production run to build N of a manufacturable item - inputs expand from its recipe. With ``complete=true`` this is a one-tap build: the run is created, its components issued, its output received as a discrete lot, and the run completed in a single call.

Parameters

NameInRequiredTypeDescription
item_idpathyesstring--

Request body

FieldTypeRequiredDescription
quantitynumber--Quantity
completeboolean--Complete
idempotency_keystring, optional--Idempotency Key

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/items/:item_id/build \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

GET /manufacturing/items/{item_id}/hub

Item Manufacturing Hub

The product Manufacturing-tab data: open demand for this product (which documents want it) + the production runs that make it. SKUs are resolved for human-readable display.

Parameters

NameInRequiredTypeDescription
item_idpathyesstring--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X GET http://localhost:8000/manufacturing/items/:item_id/hub \
  -H "Authorization: Bearer $TOKEN"

PUT /manufacturing/items/{item_id}/recipe

Set Item Recipe

Set (full-replace) the manufacturing recipe on an inventory item. Validates components, rolls the standard cost up from current component costs, and emits ``item.recipe.set``. Hard errors (422) on self-reference, unknown component SKUs, and recipe cycles - per GDR, validation lives at the function level.

Parameters

NameInRequiredTypeDescription
item_idpathyesstring--

Request body

FieldTypeRequiredDescription
output_qtynumber--Output Qty
componentsarray of ComponentSpec--Components
laborarray of LaborLine--Labor
overheadarray of OverheadLine--Overhead
unit_costnumber, optional--Unit Cost
materials_costnumber, optional--Materials Cost
labor_costnumber, optional--Labor Cost
overhead_costnumber, optional--Overhead Cost

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X PUT http://localhost:8000/manufacturing/items/:item_id/recipe \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/items/{item_id}/recost-dependents

Recost Dependents

Re-cost every item whose recipe uses this one - mark-to-market. Called automatically after a component's cost changes (the inventory pricing page) so manufactured items that depend on it stay current with no manual step.

Parameters

NameInRequiredTypeDescription
item_idpathyesstring--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/items/:item_id/recost-dependents \
  -H "Authorization: Bearer $TOKEN"

PUT /manufacturing/items/{item_id}/workflow

Set Item Workflow

Set (full-replace) the production workflow on an inventory item. The workflow is the shop-floor build sequence - independent of the costing recipe. We validate at the function level (GDR), assign a stable id to any new step, and normalize each step's elapsed time to canonical minutes so the stored data is always single-unit. Emits ``item.workflow.set``; the inventory projection stores it verbatim.

Parameters

NameInRequiredTypeDescription
item_idpathyesstring--

Request body

FieldTypeRequiredDescription
stepsarray of WorkflowStep--Steps

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X PUT http://localhost:8000/manufacturing/items/:item_id/workflow \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

GET /manufacturing/to-make

To Make

The product-centric demand board (see _compute_to_make).

Responses

StatusDescriptionBody
200Successful Responseobject

Example

curl -X GET http://localhost:8000/manufacturing/to-make \
  -H "Authorization: Bearer $TOKEN"

POST /manufacturing/to-make/make

Make Work Orders

Create one work order per selected demand line, linked 1:1 to its source order, for the line's net shortfall (the FIFO-pegged uncovered quantity). With ``complete=true`` each is also issued, received and closed. This is Demand Planning's 'Make selected' / 'Make & complete'.

Request body

FieldTypeRequiredDescription
linesarray of WorkOrderLineRef--Lines
completeboolean--Complete

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/to-make/make \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/to-make/requirements

Bulk Requirements

Aggregated, recursively-exploded raw-material + sub-assembly requirements to make the net shortfall of the selected products - the 'Print component requirements' pick list.

Request body

FieldTypeRequiredDescription
item_idsarray of string--Item Ids

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/to-make/requirements \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

GET /manufacturing/work-centers

List Work Centers

Responses

StatusDescriptionBody
200Successful Responseobject

Example

curl -X GET http://localhost:8000/manufacturing/work-centers \
  -H "Authorization: Bearer $TOKEN"

POST /manufacturing/work-centers

Create Work Center

Request body

FieldTypeRequiredDescription
namestringyesName
wip_location_idstring, optional--Wip Location Id
labor_ratenumber, optional--Labor Rate
capacitynumber, optional--Capacity
hours_per_daynumber, optional--Hours Per Day

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/work-centers \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

PATCH /manufacturing/work-centers/{wc_id}

Patch Work Center

Parameters

NameInRequiredTypeDescription
wc_idpathyesstring--

Request body

FieldTypeRequiredDescription
namestring, optional--Name
wip_location_idstring, optional--Wip Location Id
labor_ratenumber, optional--Labor Rate
capacitynumber, optional--Capacity
hours_per_daynumber, optional--Hours Per Day
is_defaultboolean, optional--Is Default

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X PATCH http://localhost:8000/manufacturing/work-centers/:wc_id \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

DELETE /manufacturing/work-centers/{wc_id}

Delete Work Center

Parameters

NameInRequiredTypeDescription
wc_idpathyesstring--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X DELETE http://localhost:8000/manufacturing/work-centers/:wc_id \
  -H "Authorization: Bearer $TOKEN"

PATCH /manufacturing/work-centers/{wc_id}/is_default

Set Default Work Center

Make this the company's default work center, clearing the previous one.

Parameters

NameInRequiredTypeDescription
wc_idpathyesstring--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X PATCH http://localhost:8000/manufacturing/work-centers/:wc_id/is_default \
  -H "Authorization: Bearer $TOKEN"

GET /manufacturing/{order_id}

Get Order

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X GET http://localhost:8000/manufacturing/:order_id \
  -H "Authorization: Bearer $TOKEN"

POST /manufacturing/{order_id}/cancel

Cancel Order

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Request body

FieldTypeRequiredDescription
reasonstring, optional--Reason
idempotency_keystring, optional--Idempotency Key

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/cancel \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/{order_id}/complete

Complete Order

Finish a run now: issue any outstanding components, receive all outstanding output, and close. This is the one-tap close used by the product hub's Complete action; the output lands as a discrete lot under the product, never a nameless throwaway item.

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Request body

CompleteBody, optional

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/complete \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/{order_id}/hold

Hold Order

Put an active run on hold (paused). Reversible via /resume.

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Request body

CancelBody, optional

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/hold \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/{order_id}/issue

Issue Order

Issue components from stock into a run (decrements them). Partial issues are allowed; omitting `items` issues everything still outstanding. Issuing auto-advances a planned run to In Progress.

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Request body

IssueBody, optional

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/issue \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/{order_id}/receive

Receive Order

Receive finished goods from a run as a discrete lot under the product. Omitting `quantity` receives everything still outstanding; once fully received the run auto-completes.

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Request body

celerp_manufacturing__routes__ReceiveBody, optional

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/receive \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/{order_id}/resume

Resume Order

Resume an on-hold run (back to In Progress).

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/resume \
  -H "Authorization: Bearer $TOKEN"

POST /manufacturing/{order_id}/schedule

Schedule Order

Set scheduling fields (due date / planned start / priority) on a run. Only provided keys are written; a blank value clears that field. A closed run cannot be rescheduled.

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Request body

FieldTypeRequiredDescription
due_datestring, optional--Due Date
planned_startstring, optional--Planned Start
prioritystring, optional--Priority
idempotency_keystring, optional--Idempotency Key

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/schedule \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'

POST /manufacturing/{order_id}/start

Start Order

Parameters

NameInRequiredTypeDescription
order_idpathyesstring--

Responses

StatusDescriptionBody
200Successful Responseobject
422Validation ErrorHTTPValidationError

Example

curl -X POST http://localhost:8000/manufacturing/:order_id/start \
  -H "Authorization: Bearer $TOKEN"