Ordexs API v1 Get an API key

Inventory

Record counted quantities

POSThttps://api.ordexs.com/v1/stock_counts/{stock_count_id}/lines

Sets what was counted for up to 500 lines of an open sheet. Counting again overwrites; counted: null clears a line. Nothing changes in stock until the count is applied.

Path parameters

  • stock_count_idstringRequired

    starts with cnt_

Body

  • linesarray of objectsRequired

    up to 500 items · at least 1 item

    2 child fields
    • variant_idstringRequired

      starts with var_

    • countedinteger or nullRequired

      0–1000000

Returns

200 OK · The count sheet. StockCount

  • idstring

    starts with cnt_

  • objectstring

    always "stock_count"

  • namestring or null
  • statusstring

    One of open, applied, discarded

  • notestring or null
  • lines_totalinteger
  • lines_countedinteger
  • created_atstring

    ISO 8601 date-time, UTC

  • applied_atstring or null

    ISO 8601 date-time, UTC

  • livemodeboolean
  • linesarray of StockCountLines

    A page of lines (single-count answers only).

    9 child fields
    • variant_idstring
    • product_titlestring
    • variant_titlestring or null
    • skustring or null
    • barcodestring or null
    • expectedinteger

      Stock when the sheet was opened.

    • countedinteger or null

      What was counted. null until someone counts it.

    • currentinteger

      Stock right now (sales keep happening while you count).

    • varianceinteger or null

      counted - current: what applying will change.

  • lines_has_moreboolean
  • adjusted_variantsinteger

    On apply

  • adjusted_unitsinteger

    On apply

Errors

Every error has the same shape. This endpoint can answer with: