{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/chatinbox-net/json-schema/chatinbox-net-customer-vm-schema.json",
  "title": "CustomerVM",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/chatinbox-net-chart-api-openapi.yml#/components/schemas/CustomerVM",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "format": "int32"
    },
    "name": {
      "type": [
        "string",
        "null"
      ]
    },
    "surName": {
      "type": [
        "string",
        "null"
      ]
    },
    "pushName": {
      "type": [
        "string",
        "null"
      ]
    },
    "fullName": {
      "type": [
        "string",
        "null"
      ]
    },
    "note": {
      "type": [
        "string",
        "null"
      ]
    },
    "lastMessageID": {
      "type": [
        "integer",
        "null"
      ],
      "format": "int32"
    },
    "email": {
      "type": [
        "string",
        "null"
      ]
    },
    "chatId": {
      "type": "integer",
      "format": "int32"
    },
    "customerPhones": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/CustomerPhoneVM"
      }
    },
    "customerFeatures": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/FeatureVM"
      }
    },
    "callMeLaters": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/CallMeLaterVM"
      }
    },
    "cf1": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf2": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf3": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf4": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf5": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf6": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf7": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf8": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf9": {
      "type": [
        "string",
        "null"
      ]
    },
    "cf10": {
      "type": [
        "string",
        "null"
      ]
    },
    "dataListID": {
      "type": "integer",
      "format": "int32"
    }
  },
  "additionalProperties": false,
  "$defs": {
    "CallMeLaterVM": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "format": "int32"
        },
        "customerID": {
          "type": "integer",
          "format": "int32"
        },
        "chatID": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int32"
        },
        "callReasonID": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int32"
        },
        "callReasonName": {
          "type": [
            "string",
            "null"
          ]
        },
        "note": {
          "type": [
            "string",
            "null"
          ]
        },
        "relatedUserID": {
          "type": "integer",
          "format": "int32"
        },
        "relatedUserName": {
          "type": [
            "string",
            "null"
          ]
        },
        "relatedUserFullName": {
          "type": [
            "string",
            "null"
          ]
        },
        "relatedTime": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "workGroupID": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int32"
        },
        "isCompleted": {
          "type": "boolean"
        },
        "completedUserID": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int32"
        },
        "completedUserName": {
          "type": [
            "string",
            "null"
          ]
        },
        "completedUserFullName": {
          "type": [
            "string",
            "null"
          ]
        },
        "completedTime": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "createDate": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time"
        },
        "customerFullName": {
          "type": [
            "string",
            "null"
          ]
        },
        "callReason": {
          "$ref": "#/$defs/CallReasonVM"
        },
        "allCallReasons": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/$defs/CallReasonVM"
          }
        }
      },
      "additionalProperties": false
    },
    "CallReasonVM": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "format": "int32"
        },
        "name": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "additionalProperties": false
    },
    "CustomerPhoneVM": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "format": "int32"
        },
        "customerID": {
          "type": "integer",
          "format": "int32"
        },
        "phone": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "additionalProperties": false
    },
    "FeatureVM": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "format": "int32"
        },
        "name": {
          "type": [
            "string",
            "null"
          ]
        },
        "featureType": {
          "type": "integer",
          "format": "int32"
        },
        "rgbCode": {
          "type": [
            "string",
            "null"
          ]
        },
        "featureGroupID": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int32"
        },
        "dataStatus": {
          "type": "integer",
          "format": "int32"
        },
        "activeSelectionCount": {
          "type": "integer",
          "format": "int32"
        },
        "flagMinutes": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int32"
        },
        "sortOrder": {
          "type": "integer",
          "format": "int32"
        }
      },
      "additionalProperties": false
    }
  }
}