Contract / blanket agreement
nutrab2b.sourcing.contract_signed.v2 · Sourcing
- Purpose
- Framework agreement: total quantity, price, period, quality agreement reference; orders are released against it.
- When to send
- Award of a long-term volume.
- Sender → receiver
- Buyer → Supplier
- Expected responses
- ACK
- Equivalent standards
- X12: 850 (BK blanket) · EDIFACT: ORDERS (BGM 105) · SAP: Scheduling agreement / contract (ME31K)
- Scenarios using it
- Release against blanket contract
Fields and mappings
| Field | Type | Req | Description | Code list / format | EDI / GS1 / SAP mapping |
|---|---|---|---|---|---|
| contract_id | string | yes | Contract id | ||
| type | string | yes | Agreement type | agreement_type | |
| valid_from | date | yes | Start | ||
| valid_to | date | yes | EndNB-R015 | ||
| incoterm | string | yes | Incoterm | incoterm | |
| payment_terms | string | yes | Payment terms | payment_terms | |
| quality_agreement_ref | string | Quality agreement id | |||
| lines | array<object> | yes | Contracted items | ||
| line_no | integer | yes | Line | ||
| item_id | string | yes | Item | ||
| hs_code | string | yes | HS | ^\d{4}(\.\d{2}){1,2}$|^\d{6,10}$ | |
| total_quantity | object | yes | Contract quantity | ||
| value | number | yes | Quantity | ||
| uom | string | yes | Unit of measure | uom | |
| unit_price | object | yes | Price | ||
| amount | number | yes | Amount in major units, decimals ≤ currency minor unitsNB-R011 | ||
| currency | string | yes | Currency | currency |
Business rules
- NB-R011 Currency precision, amount has more decimals than the currency's ISO 4217 minor units.
- NB-R015 Date order, dates are in the wrong order (e.g. delivery before order).
Example
{
"specversion": "2.0",
"id": "evt-contract-CONTRACT-1",
"type": "nutrab2b.sourcing.contract_signed.v2",
"source": "urn:gln:0614141000012:erp",
"subject": "CONTRACT",
"time": "2026-11-02T09:00:00Z",
"datacontenttype": "application/json",
"dataschema": "https://nutrab2b.org/schemas/2.0/CONTRACT.json",
"sender": {
"gln": "0614141000012"
},
"receiver": {
"gln": "4012345000009"
},
"correlationid": "CONV-RFQ-1001",
"idempotencykey": "CONTRACT:CONTRACT:1",
"sequence": 1,
"env": "test",
"data": {
"contract_id": "BA-2027-01",
"type": "BLANKET",
"valid_from": "2027-01-01",
"valid_to": "2027-12-31",
"incoterm": "FCA",
"payment_terms": "NET60",
"quality_agreement_ref": "QA-HB-2026",
"lines": [
{
"line_no": 1,
"item_id": "ASH-KSM-5",
"hs_code": "1302.19",
"total_quantity": {
"value": 6000,
"uom": "KGM"
},
"unit_price": {
"amount": 56,
"currency": "USD"
}
}
]
}
}Mapping checklist
- Every required field populated from your system of record
- Coded fields mapped to the Bodylia OpenB2B code lists
- GLN, GTIN and SSCC check digits validated
- Rules above pass in the validator
- Idempotency key and per-subject sequence generated
- Expected responses, including rejections, handled
