{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/buildworkpro-com/json-schema/buildworkpro-com-change-order-schema.json",
  "title": "ChangeOrder",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/buildworkpro-com-change-orders-api-openapi.yml#/components/schemas/ChangeOrder",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer"
    },
    "changeOrderNumber": {
      "type": "string"
    },
    "projectId": {
      "type": "integer"
    },
    "title": {
      "type": "string"
    },
    "description": {
      "type": [
        "string",
        "null"
      ]
    },
    "status": {
      "type": "string"
    },
    "reason": {
      "type": [
        "string",
        "null"
      ]
    },
    "totalAmount": {
      "type": [
        "string",
        "null"
      ]
    },
    "approvedAt": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "approvedBy": {
      "type": [
        "string",
        "null"
      ]
    },
    "rejectedAt": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "rejectionReason": {
      "type": [
        "string",
        "null"
      ]
    },
    "createdAt": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "string"
        }
      ]
    },
    "updatedAt": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "string"
        }
      ]
    }
  },
  "required": [
    "id",
    "changeOrderNumber",
    "projectId",
    "title",
    "description",
    "status",
    "reason",
    "totalAmount",
    "approvedAt",
    "approvedBy",
    "rejectedAt",
    "rejectionReason",
    "createdAt",
    "updatedAt"
  ]
}