{"$schema":"https://json-schema.org/draft/2020-12/schema","title":"Non-conformance report (BE)","description":"Belgian non-conformance report that a buying enterprise sends to a supplier after a defective delivery: the buyer's name, address, enterprise number and payment account, the report number and date, the supplier, the purchase order, delivery, goods received note and inspection references, the item and lot, the quantities received and non-conforming, where the non-conformance was detected, its description and evidence, the buyer's classification and immediate action, the corrective action required, the date the response is due, the supplier's response and the closure. Nothing is computed; no remedy or sanction is asserted.","type":"object","additionalProperties":false,"required":["company","ncr","supplier","references","item","quantities","detected_at","description","classification","immediate_action","corrective_action_required","supplier_response_due_by","status","signatory"],"properties":{"company":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Name or company name of the enterprise."},"legal_form":{"type":"string","description":"Legal form (for example SRL, SA), as the enterprise writes it."},"enterprise_number":{"type":"string","pattern":"^[01][0-9]{3}\\.[0-9]{3}\\.[0-9]{3}$","description":"Belgian enterprise number (KBO/BCE), written 0123.456.789 (Code of economic law art. III.25, al. 1)."},"vat_number":{"type":"string","pattern":"^BE[01][0-9]{9}$","description":"Belgian VAT number, written BE0123456789 (leave out if the enterprise has none)."},"address":{"type":"string","description":"Street and number of the registered seat."},"postal_code":{"type":"string","description":"Postal code."},"commune":{"type":"string","description":"Municipality."},"rpm_court":{"type":"string","description":"Enterprise court of the registered seat (legal persons: CSA art. 2:20, 5°)."},"in_liquidation":{"type":"boolean","description":"Whether the company is in liquidation (CSA art. 2:20, 7°); printed only when true."},"email":{"type":"string","description":"E-mail address."},"website":{"type":"string","description":"Website of the enterprise."},"phone":{"type":"string","description":"Telephone number."},"iban":{"type":"string","description":"IBAN of a payment account the enterprise holds (Code of economic law art. III.25, al. 2)."},"bic":{"type":"string","description":"BIC of that account."},"logo_base64":{"type":"string","description":"Logo of the issuer as a base64-encoded PNG or JPEG (validated by the renderer)."}},"description":"The enterprise that issues the document (outward: Code of economic law art. III.25, Code of companies and associations art. 2:20).","required":["name","enterprise_number","address","postal_code","commune","iban"]},"ncr":{"type":"object","additionalProperties":false,"properties":{"id":{"type":"string","description":"Number of the non-conformance report."},"raised_on":{"type":"string","format":"date","description":"Date the report is raised."},"raised_by":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Name of the person who raises the report."},"role":{"type":"string","description":"Function of that person."}},"description":"Who raises the report.","required":["name"]}},"description":"The report.","required":["id","raised_on","raised_by"]},"supplier":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Name of the supplier."},"enterprise_number":{"type":"string","pattern":"^[01][0-9]{3}\\.[0-9]{3}\\.[0-9]{3}$","description":"Enterprise number of the supplier, written 0123.456.789."},"contact":{"type":"string","description":"Contact person at the supplier."}},"description":"The supplier the report is sent to.","required":["name"]},"references":{"type":"object","additionalProperties":false,"properties":{"po":{"type":"string","description":"Purchase order reference."},"delivery_note":{"type":"string","description":"Delivery note reference."},"grn":{"type":"string","description":"Reference of the goods received note."},"inspection":{"type":"string","description":"Reference of the quality inspection sheet."},"contract":{"type":"string","description":"Reference of the supplier agreement."}},"description":"References of the documents concerned.","required":["po"]},"item":{"type":"object","additionalProperties":false,"properties":{"reference":{"type":"string","description":"Reference of the item."},"description":{"type":"string","description":"Description of the item."},"lot":{"type":"string","description":"Lot or batch number."}},"description":"The item concerned.","required":["reference","description"]},"quantities":{"type":"object","additionalProperties":false,"properties":{"received":{"type":["string","number"],"description":"Quantity received."},"non_conforming":{"type":["string","number"],"description":"Quantity found non-conforming."}},"description":"Quantities, as typed.","required":["non_conforming"]},"detected_at":{"type":"string","enum":["reception","in_process","at_customer"],"description":"Where the non-conformance was detected."},"description":{"type":"string","description":"Description of the non-conformance."},"evidence":{"type":"array","items":{"type":"string"},"description":"Evidence (photos, measurements), as references."},"classification":{"type":"string","enum":["minor","major","critical"],"description":"Classification chosen by the buyer."},"immediate_action":{"type":"string","enum":["accept","reject","return","sort_100pct","concession"],"description":"Immediate action chosen by the buyer."},"root_cause_hypothesis":{"type":"string","description":"Initial hypothesis on the root cause, if any."},"corrective_action_required":{"type":"string","description":"Corrective action the buyer requires from the supplier."},"supplier_response_due_by":{"type":"string","format":"date","description":"Date by which the supplier must respond (the buyer's date)."},"supplier_response":{"type":"object","additionalProperties":false,"properties":{"received_on":{"type":"string","format":"date","description":"Date the supplier's response was received."},"root_cause_stated":{"type":"string","description":"Root cause as stated by the supplier."},"proposed_action":{"type":"string","description":"Action proposed by the supplier."}},"description":"Supplier's response, when received."},"status":{"type":"string","enum":["open","awaiting_supplier","closed"],"description":"Status of the report."},"closure":{"type":"object","additionalProperties":false,"properties":{"date":{"type":"string","format":"date","description":"Date of closure."},"verified_by":{"type":"string","description":"Who verified the closure."}},"description":"Closure of the report.","required":["date"]},"signatory":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Name of the person who signs."},"title":{"type":"string","description":"Function of that person."},"date":{"type":"string","format":"date","description":"Date of signature."}},"description":"Who signs the document.","required":["name","title","date"]}},"allOf":[{"if":{"properties":{"status":{"const":"closed"}},"required":["status"]},"then":{"required":["closure"]}}]}