Skip to main content
GET
/
api
/
forecasts
List sales forecasts
curl --request GET \
  --url https://app.solya.app/api/forecasts \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "algorithm": "prophet",
      "confidenceLevel": 0.95,
      "forecastDate": "2026-06-02",
      "granularity": "WEEK",
      "lbQuantity": 8,
      "quantity": 12,
      "shopId": "shop-uuid-paris-001",
      "sizeTaxonomyId": "size-s",
      "ubQuantity": 16,
      "variantId": "variant-uuid-001"
    },
    {
      "algorithm": "prophet",
      "confidenceLevel": 0.95,
      "forecastDate": "2026-06-09",
      "granularity": "WEEK",
      "lbQuantity": 6,
      "quantity": 10,
      "shopId": "shop-uuid-paris-001",
      "sizeTaxonomyId": "size-s",
      "ubQuantity": 14,
      "variantId": "variant-uuid-001"
    }
  ],
  "page": 1,
  "pageSize": 20,
  "total": 8
}

Authorizations

Authorization
string
header
required

User session token issued by NextAuth. For human users accessing Solya via the web application.

Query Parameters

page
integer
default:1

Page number, 1-indexed (default: 1)

Required range: 1 <= x <= 9007199254740991
pageSize
integer
default:20

Number of items per page, max 100 (default: 20)

Required range: 1 <= x <= 100
variantId
string

Filter by variant ID

sizeTaxonomyId
string

Filter by size taxonomy ID

shopId
string

Filter by shop ID

granularity
enum<string>

Forecast granularity

Available options:
DAY,
WEEK,
MONTH,
QUARTER
horizon
integer
default:30

Forecast horizon in days from today (default: 30)

Required range: 1 <= x <= 365

Response

Successful response

data
object
required
success
enum<boolean>
required
Available options:
true