Commerce
List stock movements
A product's stock history.
Newest first.
product*stringA product id. Anything that is not one is 404 resource_missing.
Format
uuiddirection?stringValue in
"IN""OUT"period?stringValue in
"today""yesterday""this_week""last_week""last_7_days""last_30_days""last_90_days""this_month""last_month""this_year""all_time"from?stringThe first day, in East Africa Time.
Format
dateto?stringThe last day, in East Africa Time.
Format
datestart_date?stringDeprecatedUse from. An instant; one with no zone is UTC.
end_date?stringDeprecatedUse to. An instant; one with no zone is UTC.
limit?integerRange
1 <= value <= 100Default
25cursor?stringThe next_cursor of the previous page. Opaque; one that does not decode is 400 invalid_cursor.
X-Request-Id?stringYour id for this request; it becomes the request_id of any error. Without it the server makes one.
curl -X GET 'https://v3.ghala.io/v1/commerce/shop/products/497f6eca-6276-4993-bfeb-53cbbbba6f08/stock-movements'{ "items": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "direction": "IN", "quantity": 0, "variant_id": "8a2d415d-59aa-4132-bef3-011f97c4a0f6", "order_id": "93101167-9065-4b9c-b98b-5d789a3ed9fe", "recorded_by_user_id": "string", "recorded_by_name": "string", "note": "string", "created_at": "2019-08-24T14:15:22Z" } ], "next_cursor": "string", "has_more": true}