{"joins": [{"type": "left", "first": "sales_receipts.sales_receipt_id", "table": "lineitems_payments", "second": "lineitems_payments.sales_receipt_id", "operator": "="}], "table": "sales_receipts", "columns": ["sales_receipt_id", "org_id", "type", "invoiceNumber", "requestedBy", "sdcDateTime", "invoiceCounter", "invoiceCounterExtension", "taxItems", "verificationUrl", "verificationQRCode", "journal", "messages", "signedBy", "encryptedInternalData", "signature", "totalCounter", "transactionTypeCounter", "totalAmount", "taxGroupRevision", "businessName", "tin", "locationName", "address", "district", "mrc", "transactiontype", "createdAt"], "primary_key": "sales_receipt_id", "field_labels": {"mrc": "MRC", "tin": "TIN", "type": "Type", "org_id": "Organization ID", "address": "Address", "journal": "Journal", "district": "District", "messages": "Messages", "payments": "Payments (JSON)", "signedBy": "Signed By", "taxItems": "Tax Items (JSON)", "createdAt": "Created At", "signature": "Signature", "line_items": "Line Items (JSON)", "requestedBy": "Requested By", "sdcDateTime": "SDC Date/Time", "totalAmount": "Total Amount", "businessName": "Business Name", "locationName": "Location Name", "totalCounter": "Total Counter", "invoiceNumber": "Invoice Number", "invoiceCounter": "Invoice Counter", "transactiontype": "Transaction Type", "verificationUrl": "Verification URL", "sales_receipt_id": "Receipt ID", "taxGroupRevision": "Tax Group Revision", "verificationQRCode": "Verification QR Code", "encryptedInternalData": "Encrypted Internal Data", "transactionTypeCounter": "Transaction Type Counter", "invoiceCounterExtension": "Invoice Counter Extension"}, "unique_fields": ["invoiceNumber", "org_id"], "export_options": {"pretty_print_json": true, "include_json_fields": true, "include_verification_data": true}, "import_options": {"update_existing": true, "parse_json_fields": true, "create_lineitems_record": true, "validate_product_references": true}, "required_columns": ["invoiceNumber", "type", "totalAmount", "org_id"], "validation_rules": {"type": {"type": "string", "required": true}, "line_items": {"type": "json_array", "min_items": 1, "item_validation": {"quantity": {"min": 0, "type": "numeric", "required": true}, "product_id": {"type": "uuid", "required": true}, "unit_price": {"min": 0, "type": "numeric", "required": true}}}, "totalAmount": {"min": 0, "type": "numeric", "required": true}, "invoiceNumber": {"type": "string", "required": true, "max_length": 255}}, "export_transforms": {"payments": {"type": "json_decode", "pretty_print": true}, "taxItems": {"type": "json_decode", "pretty_print": true}, "createdAt": {"type": "date", "format": "Y-m-d H:i:s"}, "line_items": {"type": "json_decode", "pretty_print": true}, "sdcDateTime": {"type": "date", "format": "Y-m-d H:i:s"}}, "import_transforms": {"payments": {"type": "json", "validate_structure": {"array_structure": true, "required_fields": ["method", "amount"]}}, "taxItems": {"type": "json", "allow_null": true}, "createdAt": {"type": "datetime", "format": "Y-m-d H:i:s", "allow_null": true}, "line_items": {"type": "json", "validate_structure": {"array_structure": true, "required_fields": ["product_id", "quantity", "unit_price"]}}, "sdcDateTime": {"type": "datetime", "format": "Y-m-d H:i:s", "allow_null": true}, "totalAmount": {"type": "decimal"}, "totalCounter": {"type": "integer", "allow_null": true}, "taxGroupRevision": {"type": "integer", "allow_null": true}, "transactionTypeCounter": {"type": "integer", "allow_null": true}}, "additional_columns": [{"name": "line_items", "type": "jsonb", "source": "lineitems_payments.line_items"}, {"name": "payments", "type": "jsonb", "source": "lineitems_payments.payments"}]}