Get the wait time report
API v2 is in public beta: endpoints and fields can change before general availability. See the changelog
/back_in_stock/reports/wait_durationCosts 1 rate-limit point · Rate limits
How long back-in-stock shoppers have been waiting: median wait days, the longest wait, and a binned wait-time histogram (paid plans only).
shopify_market_ids is a comma-separated list, as the waitlist page's Markets filter.
Also searched aswait durationwait timehow long are people waitingwait time histogramhow long have customers waited
Query parameters
shopify_variant_idstringOnly this Shopify variant, as a gid or a numeric id.
shopify_product_idstringOnly this Shopify product, as a gid or a numeric id.
shopify_market_idsstringComma-separated Shopify market gids or numeric ids to keep.
fromstringStart of the window, an ISO 8601 date or date-time; a bare date starts at midnight in the shop's time zone. Default 30 days ago.
tostringEnd of the window, an ISO 8601 date or date-time; a bare date runs to the end of that day in the shop's time zone. Default today.
rangestringSet to all_time for the shop's whole history instead of from/to.
One ofall_time
Returns
windowobjectThe date range the figures cover. Null when range is all_time.
Show 2 child attributesHide child attributes
fromstringStart of the range, ISO 8601.
tostringEnd of the range, ISO 8601.
median_wait_daysnumberExample:1.5max_wait_daysintegerExample:1intervalstringExample:stringdistributionarray of objectsShow 2 child attributesHide child attributes
daysintegerExample:1countintegerExample:1
distribution_included_in_planbooleanExample:trueshopify_market_idsarray of strings
Errors
forbiddenThe credential is valid, but the store's plan or settings do not allow this operation.
plan_requiredThe change uses a feature that is only available on a paid STOQ plan. Connecting a paid-only integration returns 403; a write that sets paid-only fields returns 422 and saves nothing.
conflictThe request is well formed, but the resource's current state does not allow it.
invalid_paramsOne or more fields failed the action's schema.
validation_failedThe action refused the request for a reason that is not a single bad field.
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/reports/wait_duration" \
-H "X-Auth-Token: $STOQ_API_KEY"const res = await fetch("https://app.stoqapp.com/api/v2/external/back_in_stock/reports/wait_duration", {
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/reports/wait_duration",
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/reports/wait_duration")
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/reports/wait_duration?shopify_variant_id=45000000001&shopify_product_id=78000000001&shopify_market_ids=gid%3A%2F%2Fshopify%2FMarket%2F12345" \
-H "X-Auth-Token: $STOQ_API_KEY"const res = await fetch("https://app.stoqapp.com/api/v2/external/back_in_stock/reports/wait_duration?shopify_variant_id=45000000001&shopify_product_id=78000000001&shopify_market_ids=gid%3A%2F%2Fshopify%2FMarket%2F12345", {
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/reports/wait_duration?shopify_variant_id=45000000001&shopify_product_id=78000000001&shopify_market_ids=gid%3A%2F%2Fshopify%2FMarket%2F12345",
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/reports/wait_duration?shopify_variant_id=45000000001&shopify_product_id=78000000001&shopify_market_ids=gid%3A%2F%2Fshopify%2FMarket%2F12345")
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){
"window": {
"from": "2026-01-15T09:30:00Z",
"to": "2026-01-15T09:30:00Z"
},
"median_wait_days": 1.5,
"max_wait_days": 1,
"interval": "string",
"distribution": [
{
"days": 1,
"count": 1
}
],
"distribution_included_in_plan": true,
"shopify_market_ids": [
"string"
]
}{
"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
}
]
}