Skip to main content

Pre-Start-Date Orders — Search Specific Order

POST 

/api/magento2/integration-instances/:magento2IntegrationInstance/orders/pre-start-date-search

Live single-order lookup against the Magento store for the pre-start-date import dialog's Search specific order tab. Hits Magento directly via the REST API (GET /V1/orders/{id} for entity_id, GET /V1/orders?searchCriteria for email) — local DB lookups would miss orders that have never been imported, which is the whole point of a pre-start-date back-fill.

Body params:

  • search_by (required)entity_id (Magento order entity id) or email (customer email, exact match).
  • search_term (required, max 255 chars) — the value to look up. For entity_id must parse as a positive integer.

Response shape mirrors the Browse-by-date result so the shared dialog can render either path uniformly:

  • data[] — orders found, each with eligible, eligibility_reason, already_imported, line_items[], etc.
  • inventory_start_date — the integration's configured sync_start_date (orders on or after this date are not eligible — covered by regular sync).
  • meta.total_queried / meta.eligible_count / meta.already_imported_count.

An entity_id that doesn't exist in Magento returns data: [] (NOT a 404) so the dialog can show a clean 'no results' state.

Request

Responses

OK

Response Headers
    Content-Type