The OCI basket returns empty or mismapped
The basket posts back and SAP builds a requisition with blank lines, a wrong price, or fewer items than the shopper selected.
OCI returns are HTTP form fields rather than XML, and the index in square brackets is the only thing grouping them into lines. NEW_ITEM-DESCRIPTION[1] and NEW_ITEM-PRICE[1] belong to the same line because they share the index, not because they are adjacent. Indices that start at zero or skip a number are the usual reason lines disappear.
Causes, most likely first
Ordered by how often each one turns out to be the culprit, not by how interesting it is. Work down the list.
-
The index starts at 0, or is not contiguous
How to confirm: The first line is missing, or everything after a gap is missing. SAP expects 1 to n with no holes — a loop counter used directly as the index produces exactly this.
Fix: Number the returned lines from 1 and renumber after any filtering. Do not reuse your internal line ids as indices.
-
Field names use the wrong separator or casing
How to confirm: NEW_ITEM_DESCRIPTION rather than NEW_ITEM-DESCRIPTION. The prefix uses an underscore and the field uses a hyphen, which is easy to get wrong and produces a silently ignored field rather than an error.
Fix: Emit the field names exactly as the buyer’s OCI specification lists them, and test against that list rather than against memory.
-
The price carries a currency symbol or thousands separator
How to confirm: Lines arrive at zero or are rejected on price. NEW_ITEM-PRICE must be a plain decimal, and the decimal separator that SAP expects depends on the buyer’s locale.
Fix: Send an unformatted decimal and confirm the expected separator with the buyer. Never format a number for display and then transmit the formatted string.
-
PRICEUNIT is misunderstood
How to confirm: Prices are out by a consistent factor. NEW_ITEM-PRICEUNIT says how many units the price covers — the same concept as PriceBasisQuantity in cXML, and the same expensive mistake.
Fix: Set PRICEUNIT to the quantity the price actually applies to. Where it is 1, send 1 rather than leaving it empty.
-
A mandatory field is absent for this buyer’s configuration
How to confirm: Lines are dropped rather than rejected. Which fields are mandatory is set in the buyer’s configuration — commonly DESCRIPTION, QUANTITY, UNIT, PRICE, PRICEUNIT and CURRENCY, with VENDORMAT or MATNR depending on how they match materials.
Fix: Ask for their required field list during setup. It is one short document and it removes an entire test cycle.
If it is not on your side
Ask the buyer to trace the fields their system actually received, not the ones it displayed. A field dropped for a format reason and a field never sent look identical in the requisition, and only their trace tells them apart.
Check the document itself
Before chasing “The OCI basket returns empty or mismapped” further, paste the cXML or OCI payload into our free tester. It runs in your browser and reports the structural problems buyers reject on. The interactive demo plays the whole round trip from the buyer's seat.
Open the tester Play the demoRelated questions
Which OCI fields are mandatory?
There is no universal answer — the buyer’s configuration decides, and OCI implementations vary considerably more between buyers than cXML does. Treat the buyer’s field list as the specification and your own defaults as a starting point.
Should the OCI price include tax?
No, unless the buyer has asked for it. SAP applies its own tax treatment, and a price that silently includes tax surfaces later as a goods-receipt or invoice mismatch rather than as an error anyone can see at the time.
Rather not be the one debugging this?
A free PunchOut shop runs the PunchOut round trip for you: upload from Excel, test it, invite your buyer.
Start free Send us the error