Shipment EDI - JSON Specification

Summary

The EDI-flavored JSON used as the Chain.io destination file type "chainioShipmentEDI", produced by the EDIFACT IFTMIN (Forwarding & Transport Instruction) and IFTMAN (Arrival Notice) adapters. It uses the same "doc_type" as the canonical Shipment ("shipment_json"), with "version" always "1.0", but is a deliberately slim, restructured projection: package groups are nested under each purchase order, purchase orders are fanned out one-per-store, "quantity_requested" is repurposed as the count of package groups, and the shipment id is carried as "source_system_uid". A downstream translation engine serializes the EDIFACT message, so any segment references are logical correspondence. The two shipment file types are distinguished by the producing adapter, not by the envelope.
NameDescription
RootThe top level document. Its "doc_type" matches the canonical Shipment format; its "version" is always "1.0".
ShipmentA single shipment.
PurchaseOrderA purchase order within the shipment. In the EDI form the package groups are nested under the PO (the canonical Shipment carries them at shipment level).
PackageGroupA package (carton/pallet) within a purchase order.
PackItemA single item within a package.
NameData TypeDescriptionRequired
doc_typeStringAlways shipment_json (the same value the canonical Shipment format uses)
shipmentsArray<Shipment>Array of Shipment objects (one per file when "output_one_doc_per_shipment" is set).YES
versionStringAlways 1.0
NameData TypeDescriptionRequired
departure_estimatedDateTimeEstimated departure date.
destination_warehouseStringDestination warehouse identifier (the ship-to party).
must_deliver_by_dateDateTimeThe must-deliver-by date.
number_of_packagesIntegerTotal package count for the shipment.
purchase_ordersArray<PurchaseOrder>Purchase order loop. Each PO is split one-per-store, so the same PO number can appear multiple times with different "store_number" values.
source_system_uidStringThe shipment identifier from the system of record (the same field as canonical Shipment).
transaction_type_codeStringPresent only when the adapter is configured to hardcode a transaction type code (the transaction purpose).
transmission_uidStringA unique id generated per transmission.
volume_cbmsDecimalShipment volume in cubic meters.
NameData TypeDescriptionRequired
customer_order_numberStringThe purchase order number.
latest_delivery_dateDateTimeThe latest delivery date (present only when supplied).
order_dateDateTimeThe order date.
package_groupArray<PackageGroup>The package groups for this PO/store.
quantity_requestedIntegerRepurposed in the EDI form to the count of package groups in this store (NOT the ordered quantity).
store_numberStringThe mark-for store number. EDI-specific: the PO is cloned per distinct store number.
NameData TypeDescriptionRequired
pack_itemsArray<PackItem>The items packed in this package.
package_numberStringThe package / SSCC-18 number.
package_type_codeStringThe package type code (present only when supplied).
NameData TypeDescriptionRequired
ean_codeStringThe EAN / GTIN barcode for the item.
total_item_quantityIntegerThe number of this item in the package.

Example