{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/buildworkpro-com/json-schema/buildworkpro-com-update-project-schema.json",
  "title": "UpdateProject",
  "x-generated": "2026-11-03",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/buildworkpro-com-openapi.json#/components/schemas/UpdateProject",
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "minLength": 1
    },
    "projectNumber": {
      "type": "string"
    },
    "contactId": {
      "type": [
        "integer",
        "null"
      ]
    },
    "projectType": {
      "type": [
        "string",
        "null"
      ]
    },
    "status": {
      "type": "string",
      "enum": [
        "planning",
        "in_progress",
        "on_hold",
        "closeout",
        "completed",
        "cancelled"
      ]
    },
    "priority": {
      "type": [
        "string",
        "null"
      ]
    },
    "startDate": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expectedEndDate": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "actualEndDate": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "originalContractValue": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "contractValue": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "description": {
      "type": [
        "string",
        "null"
      ]
    },
    "siteAddress": {
      "type": [
        "string",
        "null"
      ]
    },
    "siteCity": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 255
    },
    "siteState": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 100
    },
    "siteZipCode": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 20
    },
    "architectName": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 255,
      "description": "Architect or engineer of record; printed in the pay application's \"Via architect / engineer\" cell."
    },
    "architectProjectNumber": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 100,
      "description": "The architect's own project number, printed on the pay application and its continuation sheet."
    },
    "contractFor": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 255,
      "description": "Scope line printed in the pay application's \"Contract for\" cell (e.g. \"Structural steel — Phase 2\")."
    },
    "assignedTo": {
      "type": [
        "integer",
        "null"
      ]
    },
    "bidId": {
      "type": [
        "integer",
        "null"
      ],
      "exclusiveMinimum": 0,
      "description": "Link an existing bid to this project (both sides), or `null` to unlink. Requires the `bids:write` scope too. Refused with 409 when the bid already belongs to another live project or this project already has a different bid — unlink first. Linking an accepted bid fills the original contract (pre-tax) and site address only if the project has none."
    }
  }
}