Finance & Payments pack

Purchase orders CSV import API

Map purchase-order exports from any ERP or procurement tool: PO number, supplier, item, quantity, unit price, dates and status.

30-second curl
curl -X POST https://api.adaptivmapr.com/v1/uploads \
  -H "Authorization: Bearer $ADAPTIVMAPR_API_KEY" \
  -F "template=purchase_orders_v1" \
  -F "file=@your_data.csv"
→ 9 canonical fields · 0 validated · low risk

Canonical columns

The whole schema, printed as it ships.

Every canonical column, the type each row carries, whether it is required, the field-level validators that fire on commit, and the multilingual header hints the cascade resolves against. This is the shipped definition, not a summary of it.

purchase_orders_v1
fields
9
required
2
validated
0
hints
53
Canonical columnTypeRequiredValidatorsHeader hints the cascade matches
po_numberstringyes—bestellnummerbestell-nrnuméro de commandenumero ordinepo numberpurchase ordernúmero de pedido
vendor_idstringyes—lieferantkreditorfournisseurfornitoresuppliervendorproveedor
itemstring——artikelpositionarticlearticoloitemartículo
quantitynumber——mengeanzahlquantitéquantitàqtyquantitycantidad
unit_pricenumber——einzelpreisstückpreisprix unitaireprezzo unitariounit priceprecio unitario
currencystring——währungdevisevalutacurrencymoneda
order_datedate——bestelldatumdate de commandedata ordineorder datefecha de pedido
delivery_datedate——lieferterminlieferdatumdate de livraisondata di consegnadelivery datefecha de entrega
statusenumdraftsentpartially_receivedreceivedcancelled——statusstatutstatoestado

Read the same definition as JSON at GET /v1/templates/purchase_orders_v1. A hint match resolves on layer 2 — no LLM call, no token spend, just the flat per-map fee. Hover a validator id to see what it checks.

  • 9 canonical fields
  • 2 required
  • 0 validated
  • 53 header hints, 5 languages

Why it exists

Written for the file you actually receive.

The Purchase orders template is the canonical shape for PO lines — the file a procurement system or an ERP purchasing module exports when someone asks what is on order. Each row carries the po_number, the vendor_id it was placed with, the item, the quantity and unit_price, a currency, the order and delivery dates and a status that runs draft → sent → partially_received → received, or cancelled. Procurement, AP and operations teams reach for it when switching purchasing tools mid-year with open orders still outstanding, when building three-way-match reporting between orders, receipts and invoices, and when analysing supplier lead times across sites. It is `low` risk — order lines name a supplier and an item but carry no bank details and no personal data — so the commit goes straight through with no review step.

po_number and vendor_id are required; everything else is optional so a header-only PO list and a fully priced line export both import. quantity and unit_price are numbers; the template does not compute a line total, so nothing disagrees with the source. status is an enum and an unknown value is reported in the dry-run. vendor_id pairs with the Vendors template, which is where the supplier's bank details live.

Migration scenarios & the foreign headers they ship

Migration scenarios for the Purchase orders template: carrying open orders from SAP or Abacus into a new procurement tool at cut-over, consolidating PO history from Coupa, Sage and spreadsheets for a spend analysis, feeding expected deliveries into a warehouse plan and matching orders to invoices ahead of a payment run. The headers that arrive: "Bestellnummer / Bestell-Nr / Numéro de commande / Numero ordine / PO Number / Lieferant / Kreditor / Fournisseur / Fornitore / Supplier / Artikel / Position / Article / Articolo / Menge / Anzahl / Quantité / Qty / Einzelpreis / Prix unitaire / Prezzo unitario / Bestelldatum / Date de commande / Liefertermin / Date de livraison / Data di consegna / Status / Statut". SAP's "Einkaufsbeleg" and "Nettopreis" are not registered hints and fall to the later layers.

The cascade

Six layers, and the cheapest one wins.

Layers run in order and stop the moment a column resolves. That is the single biggest cost lever in the system: a column caught on layer 2 never reaches the metered layer 5.

  1. L1Statisticsno LLM

    Auto-accepts a header that past confirmations already resolved the same way, at {minN:100, minRatio:0.95} or {minN:20, minRatio:1.00}.

  2. L2Heuristicno LLM

    Normalises accents, punctuation and whitespace, then compares against the column name, the label, and every registered hint (DE / FR / IT / EN / ES).

  3. L3Fuzzyno LLM

    Token-set ratio plus Levenshtein over the normalised strings. Auto-accepts at 0.80 — it absorbs typos and reordered words.

  4. L4Semanticcheap, cached

    Embedding cosine between the header and the field’s label + hints. Catches the long tail of paraphrases.

  5. L5LLMmetered

    Everything still unresolved goes up in ONE batched, collision-aware call, constrained to this template’s column set so it cannot invent a field.

Try it

One template id, two ways in.

REST for your import pipeline, MCP for your editor. Both run the same cascade and both honour the same schema-only clamp.

REST · POST /v1/uploads

Name the template; the cascade picks up the rest. The canonical definition is read-only at GET /v1/templates/purchase_orders_v1.

bash
curl -X POST https://api.adaptivmapr.com/v1/uploads \
  -H "Authorization: Bearer $ADAPTIVMAPR_API_KEY" \
  -F "template=purchase_orders_v1" \
  -F "file=@your_data.csv"
→ upload created · mappings ready · confirm before commit

MCP · Cursor / Claude Desktop

Drop AdaptivMapr into your editor and call the same cascade as a tool. Schema-only calls leave only column names and a few example values.

mcp
// In Cursor or Claude Desktop with the AdaptivMapr MCP server installed:
adaptivmapr.match_headers({
  template_id: "purchase_orders_v1",
  headers: ["po_number", "vendor_id", "item", "quantity"]
})
schema-only · column names and a few examples only
MCP install instructions

Questions

Purchase orders CSV import — FAQ

Can one PO have several lines?
Yes. Each row is a line; repeat the po_number for each item. The template does not require po_number to be unique, because a multi-line order is the normal case.
Does the template calculate totals or tax?
No. It carries quantity and unit_price as they appear in the source. Totals, discounts and tax belong to your purchasing or accounting system.
Our ERP has more PO states. What happens to them?
Values outside the five statuses are reported in the dry-run. Map them in the export, or save an edited copy as a workspace schema with your own status list.

Map purchase orders in production — without shipping raw records.

Minimal data mode sends only column names and a few example values — never the full file. Add full-data when you need row-level AI, routed in-region under a BAA.