{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/orion-advisor-solutions/json-schema/orion-advisor-solutions-oas-web-api-dto-billing-billing-compare-enhanced-dto-schema.json",
  "title": "OAS.WebApi.DTO.Billing.BillingCompareEnhancedDto",
  "description": "Enhanced billing compare response that includes both Receivables and Payables data",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/orion-advisor-solutions-billing-billingcompare-api-openapi.yml#/components/schemas/OAS.WebApi.DTO.Billing.BillingCompareEnhancedDto",
  "properties": {
    "receivables": {
      "items": {
        "$ref": "#/$defs/OAS.WebApi.DTO.Billing.BillingCompareReceivablesDto"
      },
      "type": "array"
    },
    "payables": {
      "items": {
        "$ref": "#/$defs/OAS.WebApi.DTO.Billing.BillingComparePayablesDto"
      },
      "type": "array"
    },
    "payablesBillEntityColumns": {
      "items": {
        "type": "string"
      },
      "type": "array"
    }
  },
  "type": "object",
  "$defs": {
    "OAS.WebApi.DTO.Billing.BillEntityDetailDto": {
      "properties": {
        "billEntityName": {
          "type": "string"
        },
        "payoutRate": {
          "type": "number",
          "format": "double"
        },
        "payoutRateName": {
          "type": "string"
        },
        "initialAmount": {
          "type": "number",
          "format": "double"
        },
        "adjustmentAmount": {
          "type": "number",
          "format": "double"
        }
      },
      "type": "object"
    },
    "OAS.WebApi.DTO.Billing.BillingComparePayablesDto": {
      "properties": {
        "clientId": {
          "type": "integer",
          "format": "int32"
        },
        "accountId": {
          "type": "integer",
          "format": "int32"
        },
        "regName": {
          "type": "string"
        },
        "acctCode": {
          "type": "string"
        },
        "instance1PayablesTotal": {
          "type": "number",
          "format": "double"
        },
        "instance2PayablesTotal": {
          "type": "number",
          "format": "double"
        },
        "payablesDifference": {
          "type": "number",
          "format": "double"
        },
        "instance1PayoutSchedule": {
          "type": "string"
        },
        "instance2PayoutSchedule": {
          "type": "string"
        },
        "instance1BillEntities": {
          "items": {
            "$ref": "#/$defs/OAS.WebApi.DTO.Billing.BillEntityDetailDto"
          },
          "type": "array"
        },
        "instance2BillEntities": {
          "items": {
            "$ref": "#/$defs/OAS.WebApi.DTO.Billing.BillEntityDetailDto"
          },
          "type": "array"
        },
        "warningMessage": {
          "type": "string"
        },
        "clientName": {
          "type": "string"
        },
        "lName": {
          "type": "string"
        },
        "repName": {
          "type": "string"
        },
        "repNo": {
          "type": "string"
        }
      },
      "type": "object"
    },
    "OAS.WebApi.DTO.Billing.BillingCompareReceivablesDto": {
      "properties": {
        "clientId": {
          "type": "integer",
          "format": "int32"
        },
        "accountId": {
          "type": "integer",
          "format": "int32"
        },
        "acctCode": {
          "type": "string"
        },
        "regName": {
          "type": "string"
        },
        "lName": {
          "type": "string"
        },
        "fundName": {
          "type": "string"
        },
        "isActive": {
          "type": "boolean"
        },
        "instance1MarketValue": {
          "type": "number",
          "format": "double"
        },
        "instance2MarketValue": {
          "type": "number",
          "format": "double"
        },
        "marketValueDifference": {
          "type": "number",
          "format": "double"
        },
        "instance1InitialAmount": {
          "type": "number",
          "format": "double"
        },
        "instance2InitialAmount": {
          "type": "number",
          "format": "double"
        },
        "initialDifference": {
          "type": "number",
          "format": "double"
        },
        "instance1BalanceDue": {
          "type": "number",
          "format": "double"
        },
        "instance2BalanceDue": {
          "type": "number",
          "format": "double"
        },
        "balanceDueDifference": {
          "type": "number",
          "format": "double"
        },
        "instance1FeeSchedule": {
          "type": "string"
        },
        "instance2FeeSchedule": {
          "type": "string"
        },
        "instance1AsOfDate": {
          "type": "string",
          "format": "date-time"
        },
        "instance2AsOfDate": {
          "type": "string",
          "format": "date-time"
        },
        "instance1Aggregate": {
          "type": "number",
          "format": "double"
        },
        "instance2Aggregate": {
          "type": "number",
          "format": "double"
        },
        "instance1FlowValue": {
          "type": "number",
          "format": "double"
        },
        "instance2FlowValue": {
          "type": "number",
          "format": "double"
        },
        "instance1FlowBalance": {
          "type": "number",
          "format": "double"
        },
        "instance2FlowBalance": {
          "type": "number",
          "format": "double"
        },
        "instance1Adjustments": {
          "type": "number",
          "format": "double"
        },
        "instance2Adjustments": {
          "type": "number",
          "format": "double"
        },
        "percentofFeeChange": {
          "type": "number",
          "format": "double"
        },
        "repName": {
          "type": "string"
        },
        "repNo": {
          "type": "string"
        },
        "warningMessage": {
          "type": "string"
        },
        "clientName": {
          "type": "string"
        }
      },
      "type": "object"
    }
  }
}