List orders from alerts
API v2 is in public beta: endpoints and fields can change before general availability. See the changelog
/back_in_stock/ordersCosts 1 rate-limit point · Rate limits
List orders placed after a back-in-stock alert, paginated. search matches order number/name, customer name, email, a Shopify order id (10+ digits), an order gid (gid://shopify/Order/<id>), or a Shopify admin order URL.
Filters match Reports > Back in stock > Sales recovered and combine with AND. product_match_type same_as_notification keeps orders where the customer bought the exact variant they were alerted about (the dashboard's Order matching: Exact variant match only). shopify_variant_id and shopify_product_id (gids) keep orders containing that variant or product, like a product's Orders tab. A bare from/to date is that whole day in the shop's time zone.
Also searched aslist back in stock ordersrestock alert ordersnotification ordersorders from restock alertssales recovered
Query parameters
pageintegerPage of results to return, starting at 1.
Default1per_pageintegerOrders per page, 1 to 200. Default 50.
Default50searchstringOnly orders matching this order number or name, customer name, email, Shopify order id (10+ digits), order gid or Shopify admin order URL.
product_match_typestringSend same_as_notification to keep only orders where the customer bought the exact variant they were alerted about.
One ofsame_as_notificationshopify_variant_idstringOnly orders containing this Shopify variant, as a gid (gid://shopify/ProductVariant/<id>) or numeric id. One id only.
shopify_product_idstringOnly orders containing this Shopify product, as a gid (gid://shopify/Product/<id>) or numeric id. One id only.
customer_idstringOnly orders placed by this customer, by the customer's STOQ id.
fromstringOnly orders created at or after this ISO 8601 date or time. A bare date starts at midnight in the shop's time zone; a time without an offset is read as UTC.
tostringOnly orders created at or before this ISO 8601 date or time. A bare date runs to the end of that day in the shop's time zone; a time without an offset is read as UTC.
Returns
ordersarray of objectsShow 12 child attributesHide child attributes
idstringExample:stringtypestringExample:stringshopify_order_idstringExample:stringnamestringExample:stringcustomerobjectShow 3 child attributesHide child attributes
idnullemailstringExample:stringnamestringExample:string
total_pricestringExample:stringcurrencystringExample:stringfinancial_statusstringExample:stringfulfillment_statusstringExample:stringnotified_productobject, nullableShow 3 child attributesHide child attributes
shopify_product_idstringExample:stringshopify_variant_idstringExample:stringtitlestringExample:string
notificationobject, nullableShow 2 child attributesHide child attributes
channelstringExample:stringsent_atstring, nullableExample:string
created_atstringExample:2026-01-15T09:30:00Z
metaobjectPagination for the list.
Show 4 child attributesHide child attributes
total_countintegerItems matching the filters, across all pages.
pageintegerPage returned, starting at 1.
per_pageintegerMost items per page.
total_pagesintegerPages available at this per_page; 0 when nothing matches.
Errors
invalid_paramsOne or more fields failed the action's schema.
validation_failedThe request failed validation.
Any request can also fail with auth_invalid (401) or rate_limited (429).
Every error has the same shape: see Errors and the list of error codes.
curl "https://app.stoqapp.com/api/v2/external/back_in_stock/orders" \
-H "X-Auth-Token: $STOQ_API_KEY"const res = await fetch("https://app.stoqapp.com/api/v2/external/back_in_stock/orders", {
headers: {
"X-Auth-Token": process.env.STOQ_API_KEY,
},
});
const data = await res.json();import os
import requests
res = requests.get(
"https://app.stoqapp.com/api/v2/external/back_in_stock/orders",
headers={"X-Auth-Token": os.environ["STOQ_API_KEY"]},
)
data = res.json()require "net/http"
require "json"
uri = URI("https://app.stoqapp.com/api/v2/external/back_in_stock/orders")
req = Net::HTTP::Get.new(uri, "X-Auth-Token" => ENV["STOQ_API_KEY"])
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |http| http.request(req) }
data = JSON.parse(res.body)curl "https://app.stoqapp.com/api/v2/external/back_in_stock/orders?product_match_type=same_as_notification&shopify_variant_id=45000000001&shopify_product_id=78000000001" \
-H "X-Auth-Token: $STOQ_API_KEY"const res = await fetch("https://app.stoqapp.com/api/v2/external/back_in_stock/orders?product_match_type=same_as_notification&shopify_variant_id=45000000001&shopify_product_id=78000000001", {
headers: {
"X-Auth-Token": process.env.STOQ_API_KEY,
},
});
const data = await res.json();import os
import requests
res = requests.get(
"https://app.stoqapp.com/api/v2/external/back_in_stock/orders?product_match_type=same_as_notification&shopify_variant_id=45000000001&shopify_product_id=78000000001",
headers={"X-Auth-Token": os.environ["STOQ_API_KEY"]},
)
data = res.json()require "net/http"
require "json"
uri = URI("https://app.stoqapp.com/api/v2/external/back_in_stock/orders?product_match_type=same_as_notification&shopify_variant_id=45000000001&shopify_product_id=78000000001")
req = Net::HTTP::Get.new(uri, "X-Auth-Token" => ENV["STOQ_API_KEY"])
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |http| http.request(req) }
data = JSON.parse(res.body){
"orders": [
{
"id": "string",
"type": "string",
"shopify_order_id": "string",
"name": "string",
"customer": {
"id": null,
"email": "string",
"name": "string"
},
"total_price": "string",
"currency": "string",
"financial_status": "string",
"fulfillment_status": "string",
"notified_product": {
"shopify_product_id": "string",
"shopify_variant_id": "string",
"title": "string"
},
"notification": {
"channel": "string",
"sent_at": "string"
},
"created_at": "2026-01-15T09:30:00Z"
}
],
"meta": {
"total_count": 1,
"page": 1,
"per_page": 1,
"total_pages": 1
}
}{
"errors": [
"Invalid API key"
],
"code": "auth_invalid",
"details": [
{
"code": "auth_invalid",
"message": "Invalid API key",
"path": null,
"value": null,
"expected": null
}
]
}{
"errors": [
"name is required"
],
"code": "validation_failed",
"details": [
{
"code": "validation_failed",
"message": "name is required",
"path": null,
"value": null,
"expected": null
}
]
}{
"errors": [
"Rate limit exceeded"
],
"code": "rate_limited",
"details": [
{
"code": "rate_limited",
"message": "Rate limit exceeded",
"path": null,
"value": null,
"expected": null
}
]
}