{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/WorkOrder",
  "title": "WorkOrder",
  "type": "object",
  "properties": {
    "WorkOrderId": {
      "type": "integer",
      "description": "Work order identifier"
    },
    "WorkOrderNumber": {
      "type": "string",
      "description": "Work order number"
    },
    "WorkOrderType": {
      "type": "string",
      "description": "Work order type"
    },
    "OrganizationCode": {
      "type": "string",
      "description": "Manufacturing organization code"
    },
    "ItemNumber": {
      "type": "string",
      "description": "Item being manufactured"
    },
    "ItemDescription": {
      "type": "string",
      "description": "Item description"
    },
    "PlannedQuantity": {
      "type": "number",
      "format": "double",
      "description": "Planned production quantity"
    },
    "CompletedQuantity": {
      "type": "number",
      "format": "double",
      "description": "Completed quantity"
    },
    "UnitOfMeasure": {
      "type": "string",
      "description": "Unit of measure"
    },
    "PlannedStartDate": {
      "type": "string",
      "format": "date",
      "description": "Planned start date"
    },
    "PlannedCompletionDate": {
      "type": "string",
      "format": "date",
      "description": "Planned completion date"
    },
    "ActualStartDate": {
      "type": "string",
      "format": "date",
      "description": "Actual start date"
    },
    "ActualCompletionDate": {
      "type": "string",
      "format": "date",
      "description": "Actual completion date"
    },
    "Status": {
      "type": "string",
      "description": "Work order status",
      "enum": [
        "Unreleased",
        "Released",
        "On Hold",
        "Complete",
        "Closed",
        "Cancelled"
      ]
    }
  }
}