{
    "$schema": "http://json-schema.org/draft-07/schema#",
    "title": "ClientDebtSummary",
    "type": "object",
    "properties": {
        "id": { "type": "string", "format": "uuid" },
        "companyId": { "type": "string", "format": "uuid" },
        "clientId": { "type": "string", "format": "uuid" },
        "totalDebt": { "type": "string" },
        "totalPaid": { "type": "string" },
        "balance": { "type": "string" },
        "currency": { "type": "string", "enum": ["ARS", "USD"] },
        "lastPaymentId": { "type": "string", "format": "uuid" },
        "lastDebtId": { "type": "string", "format": "uuid" },
        "lastPaymentDate": { "type": "string", "format": "date-time" },
        "lastDebtDate": { "type": "string", "format": "date-time" },
        "status": { "type": "string", "enum": ["NORMAL", "OVERDUE", "INACTIVE"] },
        "createdAt": { "type": "string", "format": "date-time" },
        "createdBy": { "type": "string", "format": "uuid" },
        "updatedAt": { "type": "string", "format": "date-time" },
        "updatedBy": { "type": "string", "format": "uuid" },
        "deletedAt": { "type": "string", "format": "date-time" },
        "deletedBy": { "type": "string", "format": "uuid" }
    },
    "required": [
        "id",
        "companyId",
        "clientId",
        "totalDebt",
        "totalPaid",
        "balance",
        "currency",
        "status",
        "createdAt",
        "createdBy"
    ]
}
