GET All Products
Prod Env
{{subdomain}}/api2
Prod Env
{{subdomain}}/api2
GET
{{subdomain}}/api2
Last modified:2025-04-20 12:10:30
Maintainer:Not configured
limit
: Number of records per page (1-1000)page
: Page number for paginationsearch
: Optional search term to filter results (name, description, code, etc.)product_type
: Optional filter by product type (1: product, 2: service)category_id
: Optional filter by product category IDbrand
: Optional filter by brand namestore_id
: Optional filter by store/location IDsort
: Optional field to sort by (id, name, unit_price, created, etc.)direction
: Optional sort direction (asc or desc){
"result": "success",
"code": 200,
"data": [
{
"Product": {
"id": 1,
"name": "Premium Widget",
"description": "High-quality premium widget for industrial applications",
"unit_price": 199.99,
"tax1": 1,
"tax2": 0,
"supplier_id": 1,
"brand": "WidgetCo",
"tags": "premium, industrial, widget",
"buy_price": 149.99,
"product_code": "WID-001",
"track_stock": 1,
"stock_balance": 100,
"low_stock_thershold": 20,
"barcode": "1234567890123",
"type": 1,
"availabe_online": 1,
"created": "2023-01-05 10:15:22",
"modified": "2023-03-02 14:30:45"
// Additional product fields...
}
},
// Additional products...
],
"pagination": {
"page": 1,
"page_count": 6,
"total_results": 120,
"prev": null,
"next": "/api2/products.json?page=2"
}
}
Request Request Example
Shell
JavaScript
Java
Swift
curl --location -g --request GET '{{subdomain}}/api2/api2/products.json?limit=20&page=1&search=&product_type=&category_id=&brand=&store_id=&sort=id&direction=desc'
Response Response Example
{
"result": "success",
"code": 200,
"data": [
{
"Product": {
"id": 1,
"name": "Premium Widget",
"description": "High-quality premium widget for industrial applications",
"unit_price": 199.99,
"tax1": 1,
"tax2": 0,
"supplier_id": 1,
"brand": "WidgetCo",
"tags": "premium, industrial, widget",
"buy_price": 149.99,
"product_code": "WID-001",
"track_stock": 1,
"stock_balance": 100,
"low_stock_thershold": 20,
"barcode": "1234567890123",
"type": 1,
"availabe_online": 1,
"created": "2023-01-05 10:15:22",
"modified": "2023-03-02 14:30:45",
"category_id": 3,
"category_name": "Industrial Components"
}
},
{
"Product": {
"id": 2,
"name": "Standard Widget",
"description": "Reliable standard widget for everyday use",
"unit_price": 99.99,
"tax1": 1,
"tax2": 0,
"supplier_id": 1,
"brand": "WidgetCo",
"tags": "standard, widget",
"buy_price": 75,
"product_code": "WID-002",
"track_stock": 1,
"stock_balance": 250,
"low_stock_thershold": 50,
"barcode": "1234567890456",
"type": 1,
"availabe_online": 1,
"created": "2023-01-05 10:20:35",
"modified": "2023-02-28 11:15:20",
"category_id": 3,
"category_name": "Industrial Components"
}
}
],
"pagination": {
"page": 1,
"page_count": 6,
"total_results": 120,
"prev": null,
"next": "/api2/products.json?page=2"
}
}
Request
Query Params
limit
stringÂ
required
Example:
20
page
stringÂ
required
Example:
1
search
stringÂ
required
product_type
stringÂ
required
category_id
stringÂ
required
brand
stringÂ
required
store_id
stringÂ
required
sort
stringÂ
required
Example:
id
direction
stringÂ
required
Example:
desc