Skip to main content
GET
/
api
/
sales-lines
List sales lines (sales transactions / sell-through)
curl --request GET \
  --url https://app.solya.app/api/sales-lines \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "brandCode": "maje",
      "brandId": "demo-brand-a57dc5b8",
      "brandImageUrl": "https://solyastagingwedataplatfs.blob.core.windows.net/brand-images/brands/maje/logo.png",
      "brandIsActive": true,
      "brandMainBrandTypeTaxonomyFullPath": null,
      "brandMainBrandTypeTaxonomyId": null,
      "brandName": "Maje",
      "code": null,
      "cost": 82.43,
      "costPurchasePrice": 82.43,
      "costPurchasePriceExclTax": 68.69,
      "costWeightedAverage": 82.43,
      "createdAt": "2026-06-13T03:40:41.912898+00:00",
      "discountArticleAmountExclTax": 0,
      "discountArticleAmountInclTax": 0,
      "discountGlobalAmountExclTax": 0,
      "discountTotalAmountExclTax": 0,
      "discountTotalAmountInclTax": 0,
      "inventoryItemCode": "INV-000096",
      "inventoryItemFullName": "Robe bohème à fleurs - Beige - XS",
      "inventoryItemId": "demo-inv-item-65e30fb4",
      "inventoryItemSku": "SKU-000096",
      "lineType": "sale",
      "margin": 201.5,
      "organizationId": "demo",
      "price": 183.18,
      "productCode": "robe-boheme-a-fleurs",
      "productFamilyMainTaxonomyFullPath": "Vêtements/Robes/Robes/Robes trapèze",
      "productFamilyMainTaxonomyId": "solya_family_fr_1ed879c0",
      "productGenderTaxonomyFullPath": "Femme",
      "productGenderTaxonomyId": "solya_gender_fr_43c65bcc",
      "productId": "demo-product-e95a1ecd",
      "productImageUrl": "https://solyastagingwedataplatfs.blob.core.windows.net/product-images/products/maje/robe_boheme_a_fleurs/image_0.jpeg",
      "productIsActive": true,
      "productName": "Robe bohème à fleurs",
      "quantity": 2,
      "saleCode": "S-00019188",
      "saleDate": "2026-05-08",
      "saleDateKey": 20260508,
      "saleDayName": "friday",
      "saleDayOfMonth": 8,
      "saleDayOfWeek": 5,
      "saleDayOfYear": 128,
      "saleHolidayName": "victory_day_2026",
      "saleId": "280f71de-9910-4064-8c37-3880a21d928f",
      "saleIsHoliday": true,
      "saleIsWeekend": false,
      "saleLineId": "00001750-0ce3-4486-917d-0466cbfbf52b",
      "saleMonthName": "may",
      "saleMonthOfYear": 5,
      "saleQuarter": 2,
      "saleSeason": "spring_summer",
      "saleTrimester": 2,
      "saleWeekOfMonth": 2,
      "saleWeekOfYear": 19,
      "saleYear": 2026,
      "shopCity": "Marseille",
      "shopCode": "boutique-marseille-vieux-port",
      "shopCountry": "66b26b04-1ae1-4c22-8b67-2175b9859797",
      "shopCountryId": "66b26b04-1ae1-4c22-8b67-2175b9859797",
      "shopId": "demo-shop-06490461",
      "shopIsActive": true,
      "shopName": "Boutique Marseille - Vieux Port",
      "shopRegion": "Provence-Alpes-Côte d'Azur",
      "sizeTaxonomyFullPath": "XS",
      "sizeTaxonomyId": "solya_size_fr_6e9ce024",
      "sizeTaxonomyLanguage": "fr",
      "tax": 36.64,
      "updatedAt": "2026-06-13T03:40:41.912898+00:00",
      "variantCode": "robe-boheme-a-fleurs-beige",
      "variantCollectionId": null,
      "variantCollectionName": null,
      "variantColorTaxonomyFullPath": "Couleurs Neutres/Neutre/Beige/Phantom",
      "variantDisplayName": "Beige",
      "variantFullName": "Robe bohème à fleurs - Beige",
      "variantGenderTaxonomyFullPath": null,
      "variantId": "demo-variant-dbb3f455",
      "variantIsActive": true,
      "variantName": "Robe bohème à fleurs - Beige",
      "variantSecondaryColorTaxonomyFullPath": null
    }
  ],
  "page": 1,
  "pageSize": 20,
  "total": 214803
}

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
shopId
string

Filter by shop UUID

brandId
string

Filter by brand UUID

productId
string

Filter by product UUID

variantId
string

Filter by variant UUID

lineType
enum<string>

Filter by line type. Enum (lowercase, matching stored values): 'sale' (regular sale), 'return' (returned item)

Available options:
sale,
return
dateFrom
string

Return lines where saleDate >= this value (inclusive). ISO 8601 date 'YYYY-MM-DD' (e.g. '2026-01-01') or datetime 'YYYY-MM-DDTHH:mm:ssZ' — both accepted. Filters on the saleDate column.

dateTo
string

Return lines where saleDate <= this value (inclusive). ISO 8601 date 'YYYY-MM-DD' (e.g. '2026-12-31') or datetime 'YYYY-MM-DDTHH:mm:ssZ' — both accepted. Filters on the saleDate column.

sortBy
string

Column to sort by. Allowed: 'saleDate', 'quantity', 'price'. Defaults to 'saleDate'.

sortOrder
enum<string>

Sort direction: 'asc' or 'desc'. Default order is saleDate descending (most recent first).

Available options:
asc,
desc

Response

Successful response

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