Preview PO import with SKU matching

POST /api/v1/inventory/po-import/preview

After reviewing AI column mappings, returns line items with SKU match status against the product catalog.

Operation ID: preview_po_import_api_v1_inventory_po_import_preview_post · View as markdown · OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Request body

file_id string required
selected_sheets array · string required
sheet_mappings array · POSheetMappingConfirmation requiredPOSheetMappingConfirmation
4 fields
sheet_name string required
mapping object required

Map of standard field name → 0-based column index.

data_start_row integer
exclude_rows array · integer

Responses

201 Successful Response

file_id string required
line_items array · POPreviewLineItem POPreviewLineItem
11 fields
row_number integer required
sku string required
item_name string
quantity integer required
unit_price_cents integer
match_status string

One of: matched, unmatched, ambiguous

matched_variant_id string
matched_variant_name string
matched_sku string
match_confidence number
candidates array · object
summary POPreviewSummary POPreviewSummary
7 fields
total_lines integer
matched_lines integer
unmatched_lines integer
ambiguous_lines integer
total_quantity integer
total_cents integer
skipped_rows integer
metadata POMetadata POMetadata
3 fields
suggested_po_name string
suggested_vendor_name string
suggested_po_number string

400 Bad Request - Invalid input

401 Unauthorized - Authentication required

403 Forbidden - Insufficient permissions

422 Validation Error - Invalid data format