inventory

get forecast accuracy

What the weekly forecast-accuracy job measured, read back: a trailing window and a latest week, each carrying wmape, wmase and the population they were scored over, and a weeks series behind them. Nothing is recomputed, so the figures are the ones measured at the time.

Every headline figure is measured on the organisation's managed direct-to-consumer book and says so in population and population_label. There is no sell-in forecast to score, so an organisation with wholesale volume is not being told about its whole book.

latest.by_product_type and trailing.by_product_type cut the same measurement by product type and reconcile to the headline. by_channel cuts it per active sales channel, each scored on its own series, and does NOT reconcile: absolute error is not additive across channels. A slice with too few selling lines to be evidence carries a refusal and null scores. unattributed_variants is the rest of the scored population, whose forecast carries no recorded model.

model_wmase[<method>] carries each model's error on both denominators. Only wmase_byhand, over the by-hand four-week moving average the headline divides by, is on the headline's scale, and it is null on a week with no by-hand denominator.

weeks bounds the trailing window, and product_type or sales_channel_id (one, not both) restricts every figure and echoes the cut in scope. A cut no measured week covers answers refusal with trailing and latest null and weeks empty.

Scope: inventory:read.

get/api/v1/inventory/forecast-accuracy

Request

  • Base URL: https://api.app.tightly.io
  • URL: https://api.app.tightly.io/api/v1/inventory/forecast-accuracy
  • Auth: HTTP bearer

Query parameters

weeksinteger

Window and cap, the most recent N measured whole weeks. Read trailing.weeks for how many were actually summed and trailing.window_start_date / window_end_date for the span they cover; a missed weekly run makes the window reach further back than N weeks.

start_datestring date
Example:2026-01-05

Narrow to measured weeks starting on or after this date.

end_datestring date
Example:2026-09-01

Narrow to measured weeks ending on or before this date.

current_stateboolean

Opt out of the two read-time inventories, forecast coverage and model provenance, which are computed against the live catalogue on every request and are most of this endpoint's cost. Their seven fields are then absent, which every client tolerates. Ignored (treated as false) on a sliced request: they are whole-book figures and have no per-slice meaning.

product_typestring
Example:Accessories

Restrict every figure to one category from products.product_type, matched exactly against the stored slice. Not combinable with sales_channel_id, because the record measures each cut on its own axis, so a crossed cut is refused rather than approximated.

sales_channel_idstring
Example:gid://shopify/Channel/12345

Restrict every figure to one sales channel, wholesale and retailer channels included. The channel is scored on its own series, so this never returns the direct-to-consumer figure under a channel's name; a channel with no scored week answers refusal.

Headers

Tightly-Versionstring
Example:2026-11

The date train to answer on. One train exists today, 2026-11, the one this reference describes and the one every key is minted on, so the call answers on it with or without this header. Send it anyway, so a client built now names its train from the start.

Response

The record. trailing and latest are null, not absent, on a book with no measured weeks, and on a refused slice.

messageobject

Response envelope severity, service and description

Changes

No recorded changes to this operation across all 1 revision of this API.