90 lines
1.7 KiB
JSON
90 lines
1.7 KiB
JSON
{
|
|
"name": "SaleRecord",
|
|
"type": "object",
|
|
"properties": {
|
|
"invoice_id": {
|
|
"type": "string",
|
|
"description": "Linked invoice ID"
|
|
},
|
|
"invoice_number": {
|
|
"type": "string",
|
|
"description": "Invoice number"
|
|
},
|
|
"vendor_id": {
|
|
"type": "string"
|
|
},
|
|
"vendor_name": {
|
|
"type": "string"
|
|
},
|
|
"client_name": {
|
|
"type": "string"
|
|
},
|
|
"event_name": {
|
|
"type": "string"
|
|
},
|
|
"event_date": {
|
|
"type": "string",
|
|
"format": "date"
|
|
},
|
|
"gross_amount": {
|
|
"type": "number",
|
|
"description": "Total invoice amount (revenue)"
|
|
},
|
|
"vendor_fee_percentage": {
|
|
"type": "number",
|
|
"description": "Platform/network fee %"
|
|
},
|
|
"vendor_fee_amount": {
|
|
"type": "number",
|
|
"description": "Calculated fee amount"
|
|
},
|
|
"net_amount": {
|
|
"type": "number",
|
|
"description": "Net after vendor fee"
|
|
},
|
|
"payment_status": {
|
|
"type": "string",
|
|
"enum": [
|
|
"Unpaid",
|
|
"Partial",
|
|
"Paid"
|
|
],
|
|
"default": "Unpaid"
|
|
},
|
|
"amount_paid": {
|
|
"type": "number",
|
|
"default": 0
|
|
},
|
|
"balance_due": {
|
|
"type": "number"
|
|
},
|
|
"payment_history": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "object",
|
|
"properties": {
|
|
"payment_date": {
|
|
"type": "string",
|
|
"format": "date"
|
|
},
|
|
"amount": {
|
|
"type": "number"
|
|
},
|
|
"method": {
|
|
"type": "string"
|
|
},
|
|
"reference": {
|
|
"type": "string"
|
|
},
|
|
"recorded_by": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"required": [
|
|
"invoice_id",
|
|
"gross_amount"
|
|
]
|
|
} |