List current stock positions (on-hand inventory & coverage) per variant x shop
curl --request GET \
--url https://app.solya.app/api/inventory/stock \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.solya.app/api/inventory/stock"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.solya.app/api/inventory/stock', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.solya.app/api/inventory/stock",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.solya.app/api/inventory/stock"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.solya.app/api/inventory/stock")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.solya.app/api/inventory/stock")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"avgDailySales30d": 1.5,
"currentStockQty": 42,
"daysOfSupply": 28,
"shopId": "shop-uuid-paris-001",
"shopName": "Paris Flagship",
"stockValue": 5040,
"variantId": "variant-uuid-nike-air-max-black",
"variantName": "Nike Air Max - Black"
},
{
"avgDailySales30d": 1.5,
"currentStockQty": 18,
"daysOfSupply": 12,
"shopId": "shop-uuid-marseille-002",
"shopName": "Marseille Vieux-Port",
"stockValue": 2160,
"variantId": "variant-uuid-nike-air-max-black",
"variantName": "Nike Air Max - Black"
},
{
"avgDailySales30d": 1.5,
"currentStockQty": 65,
"daysOfSupply": 43,
"shopId": "shop-uuid-paris-001",
"shopName": "Paris Flagship",
"stockValue": 4550,
"variantId": "variant-uuid-adidas-stan-smith-white",
"variantName": "Adidas Stan Smith - White"
}
],
"meta": {
"page": 1,
"pageSize": 20,
"total": 48
}
}Inventory
List current stock positions (on-hand inventory & coverage) per variant x shop
Returns a paginated list of current stock positions, one per variant x shop, with on-hand quantity, stock value, average daily sales, and days-of-supply (stock coverage / how long inventory will last). Use this to check how much stock is on hand and where, gauge inventory coverage, or spot overstock (high days-of-supply / slow-movers) and low stock. Filter by variant IDs, shop, and brand. For a ranking by stock-out urgency (which variants to restock first) use GET /inventory/risks.
GET
/
api
/
inventory
/
stock
List current stock positions (on-hand inventory & coverage) per variant x shop
curl --request GET \
--url https://app.solya.app/api/inventory/stock \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.solya.app/api/inventory/stock"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.solya.app/api/inventory/stock', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.solya.app/api/inventory/stock",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.solya.app/api/inventory/stock"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.solya.app/api/inventory/stock")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.solya.app/api/inventory/stock")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"avgDailySales30d": 1.5,
"currentStockQty": 42,
"daysOfSupply": 28,
"shopId": "shop-uuid-paris-001",
"shopName": "Paris Flagship",
"stockValue": 5040,
"variantId": "variant-uuid-nike-air-max-black",
"variantName": "Nike Air Max - Black"
},
{
"avgDailySales30d": 1.5,
"currentStockQty": 18,
"daysOfSupply": 12,
"shopId": "shop-uuid-marseille-002",
"shopName": "Marseille Vieux-Port",
"stockValue": 2160,
"variantId": "variant-uuid-nike-air-max-black",
"variantName": "Nike Air Max - Black"
},
{
"avgDailySales30d": 1.5,
"currentStockQty": 65,
"daysOfSupply": 43,
"shopId": "shop-uuid-paris-001",
"shopName": "Paris Flagship",
"stockValue": 4550,
"variantId": "variant-uuid-adidas-stan-smith-white",
"variantName": "Adidas Stan Smith - White"
}
],
"meta": {
"page": 1,
"pageSize": 20,
"total": 48
}
}Authorizations
User session token issued by NextAuth. For human users accessing Solya via the web application.
Query Parameters
Page number, 1-indexed (default: 1)
Required range:
1 <= x <= 9007199254740991Number of items per page, max 100 (default: 20)
Required range:
1 <= x <= 100Comma-separated list of variant IDs to filter by
Filter by shop ID
Filter by brand ID

