Hoppa till innehållet

Arbetsordrar

Production and service work orders. Read-only. Addressed by workOrderNumber.

2 anrop GET Bas-URL https://api.erp.fluit.cloud/preview

Autentisering, felkoder, rate limits, idempotens och paginering gäller alla anrop och står samlade under Kom igång.

GET /work-orders

List work orders

Returns a paginated list of work orders, newest first. Read-only — production is planned and reported inside the ERP. ?modifiedSince= returns both created and modified work orders, so it can be used for delta sync. Fetch a single work order via its links.self.

Frågeparametrar

Fält Typ Beskrivning
search string Matches work order number and title, case-insensitively and on partial words.
status enum Filters on how far production has got. Draft Planned Waiting Active Paused Completed Closed Cancelled Estimate
type enum Filters on what kind of work the order covers. Manufacturing Project Service Maintenance
outputItemNumber string Returns only the work orders producing this item.
modifiedSince string(date-time) Returns only records created or changed at or after this instant (ISO 8601 UTC datetime). A change anywhere inside the record counts, including on its lines.
page integer Page to return, 1-based. Default 1.
pageSize integer Number of records per page. Default 50, max 200.

Svar

200 PagedResult_PublicWorkOrderResponse

Paginerat svar: raderna nedan ligger i items[], omgivna av totalCount, page, pageSize, totalPages, hasPreviousPage och hasNextPage. Paginerad

Fält Typ Beskrivning
actualEnd string(date-time) · nullable When work actually finished (UTC). Null if not finished.
actualStart string(date-time) · nullable When work actually started (UTC). Null if not started.
createdDate string(date-time) UTC timestamp when the work order was created.
customerNumber string · nullable Customer number, when the work order belongs to a customer. Null otherwise.
description string · nullable Longer description of the work. Null if not set.
links Links Hypermedia links for a public API resource. Exposed as a computed `links` property on the public response DTOs so that create and read responses carry the same self-reference — the canonical URL is derived from the business key already present on the DTO and can never drift from the route it points at.
outputItemNumber string · nullable Item number of the item being produced. Null for service and project orders.
plannedEnd string(date-time) · nullable Planned end (UTC). Null if not planned.
plannedOutputQuantity decimal Quantity planned to be produced. Serialised as a decimal string.
plannedStart string(date-time) · nullable Planned start (UTC). Null if not planned.
priority enum Work order priority values exposed via the Public API. Mirrors `Domain.WorkOrders.WorkOrderPriority`. Low Normal High Urgent
producedQuantity decimal Quantity reported as produced so far. Serialised as a decimal string.
salesOrderNumber string · nullable Sales order number this work order fulfils. Null if not linked to an order.
status enum Work order status values exposed via the Public API. Mirrors `Domain.WorkOrders.WorkOrderStatus` name-for-name and value-for-value so the query projections can cast directly — a cast is translatable to SQL where a switch over a helper method is not. `PublicWorkOrderEnumParityTests` fails the build if the two ever drift apart, which is what stops a new domain value from silently serialising as a bare number. Draft Planned Waiting Active Paused Completed Closed Cancelled Estimate
title string · nullable Short title describing the work.
type enum Work order type values exposed via the Public API. Mirrors `Domain.WorkOrders.WorkOrderType`. Manufacturing Project Service Maintenance
warehouseCode string · nullable Code of the warehouse the output is received into. Null if not set.
workOrderNumber string · nullable Unique work order number, e.g. `WO-2026-00042`.
400 ProblemDetails ?status= or ?type= got a value outside its list.
Fält Typ
detail string · nullable
instance string · nullable
status integer · nullable
title string · nullable
type string · nullable

Standardfel: 401 403 Felhantering

Exempel

curl
curl "https://api.erp.fluit.cloud/preview/work-orders" \
  -H "X-Api-Key: fluit_live_sk_..."
Svar 200
{
  "hasNextPage": true,
  "hasPreviousPage": true,
  "items": [
    {
      "actualEnd": "2026-06-11T09:24:13.418",
      "actualStart": "2026-06-11T09:24:13.418",
      "createdDate": "2026-06-11T09:24:13.418",
      "customerNumber": "CUST-001",
      "description": "string",
      "links": {
        "self": "string"
      },
      "outputItemNumber": "ABC-001",
      "plannedEnd": "2026-06-11T09:24:13.418",
      "plannedOutputQuantity": "10",
      "plannedStart": "2026-06-11T09:24:13.418",
      "priority": "Low",
      "producedQuantity": "10",
      "salesOrderNumber": "ABC-001",
      "status": "Draft",
      "title": "string",
      "type": "Manufacturing",
      "warehouseCode": "MAIN",
      "workOrderNumber": "WO-2026-0620"
    }
  ],
  "page": 1,
  "pageSize": 50,
  "totalCount": 137,
  "totalPages": 3
}

Bas-URL https://api.erp.fluit.cloud/preview. Svarsexemplet är genererat ur schemat: formen stämmer, värdena är påhittade.

GET /work-orders/{workOrderNumber}

Get a work order by number

Read-only view of a work order: what is being produced, how much is done and when. Reporting output happens inside Fluit or in the mobile app.

work-orders:read

Sökvägsparametrar

Fält Typ Beskrivning
workOrderNumber Krävs string Work order number of the work order to read.

Svar

200 PublicWorkOrderResponse
Fält Typ Beskrivning
actualEnd string(date-time) · nullable When work actually finished (UTC). Null if not finished.
actualStart string(date-time) · nullable When work actually started (UTC). Null if not started.
createdDate string(date-time) UTC timestamp when the work order was created.
customerNumber string · nullable Customer number, when the work order belongs to a customer. Null otherwise.
description string · nullable Longer description of the work. Null if not set.
links Links Hypermedia links for a public API resource. Exposed as a computed `links` property on the public response DTOs so that create and read responses carry the same self-reference — the canonical URL is derived from the business key already present on the DTO and can never drift from the route it points at.
outputItemNumber string · nullable Item number of the item being produced. Null for service and project orders.
plannedEnd string(date-time) · nullable Planned end (UTC). Null if not planned.
plannedOutputQuantity decimal Quantity planned to be produced. Serialised as a decimal string.
plannedStart string(date-time) · nullable Planned start (UTC). Null if not planned.
priority enum Work order priority values exposed via the Public API. Mirrors `Domain.WorkOrders.WorkOrderPriority`. Low Normal High Urgent
producedQuantity decimal Quantity reported as produced so far. Serialised as a decimal string.
salesOrderNumber string · nullable Sales order number this work order fulfils. Null if not linked to an order.
status enum Work order status values exposed via the Public API. Mirrors `Domain.WorkOrders.WorkOrderStatus` name-for-name and value-for-value so the query projections can cast directly — a cast is translatable to SQL where a switch over a helper method is not. `PublicWorkOrderEnumParityTests` fails the build if the two ever drift apart, which is what stops a new domain value from silently serialising as a bare number. Draft Planned Waiting Active Paused Completed Closed Cancelled Estimate
title string · nullable Short title describing the work.
type enum Work order type values exposed via the Public API. Mirrors `Domain.WorkOrders.WorkOrderType`. Manufacturing Project Service Maintenance
warehouseCode string · nullable Code of the warehouse the output is received into. Null if not set.
workOrderNumber string · nullable Unique work order number, e.g. `WO-2026-00042`.
404 ProblemDetails No work order with that number.
Fält Typ
detail string · nullable
instance string · nullable
status integer · nullable
title string · nullable
type string · nullable

Standardfel: 401 403 Felhantering

Exempel

curl
curl "https://api.erp.fluit.cloud/preview/work-orders/{workOrderNumber}" \
  -H "X-Api-Key: fluit_live_sk_..."
Svar 200
{
  "actualEnd": "2026-06-11T09:24:13.418",
  "actualStart": "2026-06-11T09:24:13.418",
  "createdDate": "2026-06-11T09:24:13.418",
  "customerNumber": "CUST-001",
  "description": "string",
  "links": {
    "self": "string"
  },
  "outputItemNumber": "ABC-001",
  "plannedEnd": "2026-06-11T09:24:13.418",
  "plannedOutputQuantity": "10",
  "plannedStart": "2026-06-11T09:24:13.418",
  "priority": "Low",
  "producedQuantity": "10",
  "salesOrderNumber": "ABC-001",
  "status": "Draft",
  "title": "string",
  "type": "Manufacturing",
  "warehouseCode": "MAIN",
  "workOrderNumber": "WO-2026-0620"
}

Bas-URL https://api.erp.fluit.cloud/preview. Svarsexemplet är genererat ur schemat: formen stämmer, värdena är påhittade.

Scheman

Objekten som gruppens anrop refererar till. Fälttabellerna ovan går ett steg djupt och länkar hit i stället för att upprepa samma schema på varje endpoint.