List products
List a store's products newest first as lean summaries (name, status, thumbnail, variant count and price range).
List a store's products newest first as lean summaries (name, status, thumbnail, variant count and price range). Prices are integers in the smallest currency unit and live on variants. Filter by status, free text or a set of product ids. Use include=variants to embed each product's variants with prices and inventory, and include=media to embed its media.
API Token authentication
The ID of the store to list products for.
store_01J8Z5F8W9K8M4A7B3C2D1E0FGRestrict to these product ids. Doubles as a single-product lookup. Up to 200 ids.
Free-text search over product title and SKU.
blue shirtPage number
1Success response
Unauthenticated response
Error response
GET /api/ecommerce/v1/stores/{store_id}/products HTTP/1.1
Host: developers.hostinger.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"data": [
{
"id": "prod_01J8Z5F8W9K8M4A7B3C2D1E0FG",
"title": "Blue T-Shirt",
"status": "published",
"thumbnail": "https://cdn.example.com/prod/thumb.jpg",
"type": "physical",
"variant_count": 3,
"price_range": {
"min": 1999,
"max": 2499,
"currency_code": "usd"
},
"variants": [
{
"id": "variant_01J8Z5F8W9K8M4A7B3C2D1E0FG",
"title": "Medium",
"sku": "TSHIRT-BLU-M",
"options": [
{
"name": "Size",
"value": "M"
}
],
"prices": [
{
"amount": 1999,
"sale_amount": null,
"currency_code": "usd"
}
],
"inventory_quantity": 42,
"manage_inventory": true
}
],
"media": [
{
"url": "https://cdn.example.com/prod/1.jpg",
"type": "image",
"is_thumbnail": true
}
]
}
],
"meta": {
"current_page": 1,
"per_page": 15,
"total": 100
}
}Last updated
Was this helpful?