﻿{
	"$schema": "http://json-schema.org/draft-04/schema#",
	"$id": "http://www.paprosinc.com/jschemas/fully_modular_draftver_9_1751B_jschema.json",
	"title": "CommonElementsOfMaterialDeclaration-1751B std",
	"description": "Version- dated 12/18/2025- This document contains the record of common fields for a Material Declaration as pertains the IPC 1751",
	"type": "object",
	"definitions": {
		"MainDeclaration": {
			"type": "object",
			"additionalProperties": true,
			"properties": {
				"type": {
					"version": "string",
					"enum": [
						"2.00"
					]
				}
			}
		},
		"BusinessInfo": {
			"type": "object",
			"properties": {
				"Response": {
					"$ref": "#/definitions/Response"
				},
				"Request": {
					"$ref": "#/definitions/Request"
				},
				"Declaration": {
					"$ref": "#/definitions/Declaration"
				},
				"mode": {
					"type": "string",
					"enum": [
						"Request/Reply",
						"Distribute"
					]
				},
				"Attachment": {
					"$ref": "#/definitions/Attachment"
				}
			}
		},
		"Response": {
			"type": "object",
			"properties": {
				"Authorizer": {
					"$ref": "#/definitions/Contact"
				},
				"authorizerApproval": {
					"type": "string"
				},
				"authorizerApprovalDate": {
					"type": "string"
				},
				"SupplyCompany": {
					"$ref": "#/definitions/Company"
				},
				"Distributor": {
					"$ref": "#/definitions/Company"
				},
				"Responder": {
					"$ref": "#/definitions/Company"
				},
				"Contact": {
					"$ref": "#/definitions/Contact"
				},
				"Manufacturer": {
					"$ref": "#/definitions/Company"
				},
				"date": {
					"type": "string"
				},
				"docID": {
					"type": "string"
				},
				"docClas": {
					"type": "string",
					"enum": [
						"external",
						"internal",
						"open",
						"classified",
						"sensitive",
						"other"
					]
				},
				"docType": {
					"type": "string",
					"enum": [
						"As_Engineered",
						"As_Designed",
						"As_Built",
						"As_Manufactured",
						"other"
					]
				},
				"comment": {
					"type": "string"
				}
			},
			"required": [
				"lastOrderDate",
				"lastShipmentDate",
				"date"
			]
		},
		"Request": {
			"type": "object",
			"properties": {
				"Contact": {
					"$ref": "#/definitions/Contact"
				},
				"RequestCompany": {
					"$ref": "#/definitions/Company"
				},
				"date": {
					"type": "string"
				},
				"docID": {
					"type": "string"
				},
				"docClas": {
					"type": "string",
					"enum": [
						"external",
						"internal",
						"open",
						"classified",
						"other"
					]
				},
				"docType": {
					"type": "string",
					"enum": [
						"As_Engineered",
						"As_Designed",
						"As_Built",
						"As_Manufactured",
						"other"
					]
				},
				"respondByDate": {
					"type": "string"
				},
				"internalSupplierID": {
					"type": "string"
				},
				"comment": {
					"type": "string"
				}
			},
			"required": [
				"Contact",
				"date"
			]
		},
		"Company": {
			"type": "object",
			"properties": {
				"CompanyID": {
					"$ref": "#/definitions/UniqueID"
				},
				"name": {
					"type": "string"
				},
				"Division": {
					"$ref": "#/definitions/Company"
				},
				"informationURL": {
					"type": "string"
				},
				"wsdlURL": {
					"type": "string"
				}
			}
		},
		"UniqueID": {
			"type": "object",
			"additionalProperties": true,
			"properties": {
				"identity": {
					"type": "string"
				},
				"authority": {
					"type": "string"
				}
			}
		},
		"UniqueIDExtended": {
			"type": "object",
			"additionalProperties": true,
			"properties": {
				"revision": {
					"type": [
						"string"
					]
				},
				"date": {
					"type": "string"
				}
			},
			"allOf": [
				{
					"$ref": "#/definitions/UniqueID"
				}
			]
		},
		"Contact": {
			"type": "object",
			"properties": {
				"Email": {
					"$ref": "#/definitions/Email"
				},
				"SurfaceAddress": {
					"$ref": "#/definitions/SurfaceAddress"
				},
				"Phone": {
					"$ref": "#/definitions/Phone"
				},
				"name": {
					"type": "string"
				},
				"title": {
					"type": "string"
				},
				"comment": {
					"type": "string"
				}
			},
			"required": [
				"name"
			]
		},
		"Email": {
			"type": "object",
			"properties": {
				"address": {
					"type": "string"
				},
				"emailType": {
					"type": "string"
				}
			}
		},
		"Phone": {
			"type": "object",
			"properties": {
				"number": {
					"type": "string"
				},
				"phoneType": {
					"type": "string"
				}
			}
		},
		"SurfaceAddress": {
			"type": "object",
			"properties": {
				"internal": {
					"type": "string"
				},
				"street": {
					"type": "string"
				},
				"city": {
					"type": "string"
				},
				"stateProvince": {
					"type": "string"
				},
				"zipCode": {
					"type": "string"
				},
				"country": {
					"type": "string"
				},
				"type": {
					"type": "string"
				}
			}
		},
		"Include": {
			"type": "object",
			"additionalProperties": true,
			"properties": {
				"dataType": {
					"type": "string",
					"enum": [
						"IPC-1752B",
						"IPC-1752C",
						"IPC-1753",
						"IPC-1753A",
						"IPC-1754",
						"IPC-1755A",
						"IPC-1756",
						"IPC-1757"
					]
				}
			}
		},
		"Attachment": {
			"type": "object",
			"properties": {
				"name": {
					"type": "string"
				},
				"fileType": {
					"type": "string"
				},
				"fileDescription": {
					"type": "string",
					"enum": [
						"Test Report",
						"Certificate of Compliance",
						"Picture",
						"Dissassembly Instructions",
						"Safe Use Instructions",
						"Other"
					]
				},
				"fileURL": {
					"type": "string"
				},
				"fileZipLocation": {
					"type": "string"
				},
				"language": {
					"type": "string"
				}
			}
		},
		"Declaration": {
			"type": "object",
			"properties": {
				"legalType": {
					"type": "string",
					"enum": [
						"standard",
						"custom"
					]
				},
				"supplierAcceptance": {
					"type": "boolean"
				},
				"legalDef": {
					"type": "string"
				}
			},
			"required": [
				"legalType",
				"supplierAcceptance",
				"legalDef"
			]
		},
		"Amount": {
			"type": "object",
			"properties": {
				"value": {
					"type": [
						"number",
						"string"
					]
				},
				"minimumValue": {
					"type": "number"
				},
				"maximumValue": {
					"type": "number"
				},
				"positiveVariationPercent": {
					"type": "number"
				},
				"negativeVariationPercent": {
					"type": "number"
				},
				"UOM": {
					"type": "string",
					"enum": [
						"mg",
						"g",
						"kg",
						"oz",
						"lb",
						"massPercent",
						"ppm"
					]
				}
			}
		},
		"Product": {
			"type": "object",
			"additionalProperties": true,
			"properties": {
				"unitType": {
					"type": "string",
					"enum": [
						"Each",
						"Meter",
						"m^2",
						"m^3",
						"cm",
						"cm^2",
						"cm^3",
						"Liter",
						"Feet",
						"ft^2",
						"ft^3",
						"inch",
						"in^2",
						"in^3",
						"Gallon"
						]
				},
				"comment": {
					"type": "string"
				},
				"numberOfInstances": {
					"type": "number"
				},
				"ProductID": {
					"type": "array",
					"items": {
						"$ref": "#/definitions/ProductID"
					}
				},
				"SubProduct": {
					"type": "array",
					"items": {
						"$ref": "#/definitions/Product"
					}
				},
				"Attachment": {
					"type": "array",
					"items": {
						"$ref": "#/definitions/Attachment"
					}
				}
			}
		},
		"ProductID": {
			"type": "object",
			"properties": {
				"Amount": {
					"$ref": "#/definitions/Amount"
				},
				"SummedAmount": {
					"$ref": "#/definitions/Amount"
				},
				"InstanceID": {
					"$ref": "#/definitions/UniqueID"
				},
				"ItemRange": {
					"anyOf": [
						{
							"$ref": "#/definitions/PartNumberRange"
						},
						{
							"type": "array",
							"items": {
								"$ref": "#/definitions/PartNumberRange"
							}
						}
					]
				},
				"SynonymousIDs": {
					"anyOf": [
						{
							"$ref": "#/definitions/SynonymousIDs"
						},
						{
							"type": "array",
							"items": {
								"$ref": "#/definitions/SynonymousIDs"
							}
						}
					]
				},
				"GroupMembers": {
					"anyOf": [
						{
							"$ref": "#/definitions/GroupMembers"
						},
						{
							"type": "array",
							"items": {
								"$ref": "#/definitions/GroupMembers"
							}
						}
					]
				},
				"itemName": {
					"type": "string"
				},
				"itemNumber": {
					"type": "string"
				},
				"manufacturingSite": {
					"type": "string"
				},
				"manufacturingCountry": {
					"type": "string"
				},
				"manufacturingLatLong": {
					"type": "string"
				},
				"effectiveDate": {
					"type": "string"
				},
				"version": {
					"type": "string"
				},
				"requesterItemName": {
					"type": "string"
				},
				"requesterItemNumber": {
					"type": "string"
				},
				"ProductCategoryList": {
					"$ref": "#/definitions/EntryList"
				},
				"GroupID": {
					"$ref": "#/definitions/GroupID"
				},
				"itemDID": {
					"type": "string"
				}
			},
			"required": [
				"itemNumber",
				"itemName"
			]
		},
		"GroupID": {
			"type": "object",
			"properties": {
				"groupName": {
					"type": "string"
				},
				"groupNumber": {
					"type": "string"
				}
			}
		},
		"EntryList": {
			"type": "object",
			"EntryListID": {
				"type": "object",
				"properties": {
					"$ref": "#/definitions/UniqueIDExtended"
				}
			},
			"EntryInList": {
				"type": "array",
				"properties": {
					"$ref": "#/definitions/EntryInList"
				}
			}
		},
		"EntryInList": {
			"type": "object",
			"properties": {
				"entry": {
					"type": "string"
				},
				"entryID": {
					"type": "string"
				},
				"EntryList": {
					"$ref": "#/definitions/EntryList"
				}
			}
		},
		"QueryList": {
			"type": "object",
			"additionalProperties": true,
			"QueryListID": {
				"$ref": "#/definitions/UniqueIDExtended"
			},
			"Query": {
				"type": "array",
				"minItems": 1,
				"items": {
					"$ref": "#/definitions/Query"
				}
			},
			"EntryList": {
				"$ref": "#definitions/EntryList"
			}
		},
		"Query": {
			"type": "object",
			"additionalProperties": true,
			"properties": {
				"statement": {
					"type": "string"
				},
				"CategoricalResponse": {
					"type": "array",
					"minItems": 1,
					"items": {
						"$ref": "#/definitions/CategoricalResponse"
					}
				},
				"response": {
					"type": [
						"boolean",
						"string"
					]
				},
				"responseID": {
					"type": "string"
				},
				"additionalComment": {
					"type": "string"
				},
				"quantity": {
					"type": "number"
				},
				"queryID": {
					"type": "string"
				},
				"ReferenceList": {
					"type": "array",
					"minItems": 1,
					"items": {
						"$ref": "#/definitions/EntryList"
					}
				}
			},
			"required": [
				"statement"
			]
		},
		"CategoricalResponse": {
			"type": "object",
			"additionalProperties": true,
			"properties": {
				"QueryContext": {
					"$ref": "#/definitions/Category"
				},
				"response": {
					"type": [
						"boolean",
						"string"
					]
				},
				"responseID": {
					"type": "string"
				}
			}
		},
		"Category": {
			"type": "array",
			"minItems": 1,
			"CategoryList": {
				"type": "object",
				"items": {
					"$ref": "#/definitions/EntryList"
				}
			},
			"EntryInList": {
				"type": "object",
				"items": {
					"$ref": "#/definitions/EntryInList"
				}
			}
		},
		"PartNumberRange": {
			"type": "object",
			"rangeEntry": {
				"type": "string"
			},
			"logicForRange": {
				"type": "string"
			},
			"required": [
				"rangeEntry",
				"logicForRange"
			]
		},
		"SynonymousIDs": {
			"type": "object",
			"Company": {
				"type": "object",
				"properties": {
					"$ref": "#/definitions/Company"
				},
				"ProductID": {
					"type": "array",
					"properties": {
						"$ref": "#/definitions/ProductID"
					}
				}
			},
			"required": [
				"Company",
				"ProductID"
			]
		},
		"GroupMembers": {
			"type": "string"
		},
        "ExemptionList": {
            "type": "object",
            "properties": {
                "ExemptionListID": {
                    "$ref": "#/definitions/UniqueIDExtended"
                },
                "Exemption": {
                    "anyOf": [
                        {
                            "$ref": "#/definitions/Exemption"
                        },
                        {
                            "type": "array",
                            "minItems": 1,
                            "items": {
                                "$ref": "#/definitions/Exemption"
                            }
                        }
                    ]
                }
            },
            "additionalProperties": true,
            "required": [
                "ExemptionListID"
            ]
        },
        "Exemption": {
            "type": "object",
            "properties": {
                "ExemptionIdentity": {
                            "$ref": "#/definitions/EntryInList"
                },
                "entryID": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                },
        "Expiry": {
            "type": "array",

                "Category": {
                             "$ref": "#/definitions/Category"
                },
                "expiryDate": {
                    "type": "string"
                }
				}
				
            },
            "additionalProperties": true,
            "required": [
                "description"
            ]
        },
        "Threshold": {
            "type": "object",
            "properties": {
                "overThreshold": {
                    "type": "string",
					"enum": [
						"true",
						"false",
						"not applicable"
						]
                },
                "value": {
                    "type": "string"
                },
                "UOM": {
                    "type": "string"
                },
                "description": {
                    "type": "string"
                }
            },
            "additionalProperties": true,
            "required": [
                "value"
            ]
        }
	}
}