Skip to content

Products ​

Part of the Products API. Base URL https://your-domain.com/admin/api/v1 — replace the host with your own installation and the token placeholder with a real Bearer token (see Authentication).

List products ​

GET /admin/api/v1/products/products

Retrieve a paginated list of products with filtering and sorting

🔒 Requires a valid Bearer token.

Query parameters

ParameterTypeRequiredDescriptionExample
includestringNoComma-separated list of relationships to include. Available options: parent, variants, uom, uomPO, category, tags, attributes, attribute_values, company, creatorcategory,tags
filter[id]stringNoComma-separated list of IDs to filter by
filter[type]stringNoFilter by product type
filter[enable_sales]booleanNoFilter by sales enabledtrue
filter[enable_purchase]booleanNoFilter by purchase enabledfalse
filter[category_id]stringNoComma-separated list of category IDs to filter by
filter[trashed]stringNoFilter by trashed status: "with" (include trashed), "only" (only trashed), or any other value for non-trashed onlywith
sortstringYesSort field-created_at
pageintegerYesPage number1
bash
curl -X GET "https://your-domain.com/admin/api/v1/products/products?include=category%2Ctags&filter%5Benable_sales%5D=true&filter%5Benable_purchase%5D=false&filter%5Btrashed%5D=with&sort=-created_at&page=1" \
  -H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json"
javascript
const response = await fetch("https://your-domain.com/admin/api/v1/products/products?include=category%2Ctags&filter%5Benable_sales%5D=true&filter%5Benable_purchase%5D=false&filter%5Btrashed%5D=with&sort=-created_at&page=1", {
  method: "GET",
  headers: {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
  },
});

const data = await response.json();
console.log(data);
php
<?php

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://your-domain.com/admin/api/v1/products/products?include=category%2Ctags&filter%5Benable_sales%5D=true&filter%5Benable_purchase%5D=false&filter%5Btrashed%5D=with&sort=-created_at&page=1', [
    'headers' => [
        'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
]);

$data = json_decode($response->getBody(), true);
python
import requests

url = "https://your-domain.com/admin/api/v1/products/products?include=category%2Ctags&filter%5Benable_sales%5D=true&filter%5Benable_purchase%5D=false&filter%5Btrashed%5D=with&sort=-created_at&page=1"

headers = {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

response = requests.get(url, headers=headers)

data = response.json()
print(data)

Example response 200

json
{
  "data": [
    {
      "id": 1,
      "type": "goods",
      "name": "T-Shirt",
      "service_tracking": "none",
      "reference": null,
      "barcode": null,
      "price": 250,
      "cost": 220,
      "volume": 2501,
      "weight": 1,
      "description": "<p>Men&#039;s wear tshirt in multiple variant colors like that tell me.</p>",
      "description_purchase": null,
      "description_sale": null,
      "enable_sales": false,
      "enable_purchase": false,
      "is_favorite": false,
      "is_configurable": false,
      "images": [
        "01M4G1WMQZ0T9EBB2F6CERDFTV.jpg"
      ],
      "sort": 1,
      "parent_id": null,
      "uom_id": 1,
      "uom_po_id": 1,
      "category_id": 1,
      "creator_id": 1,
      "company_id": 1,
      "created_at": "2026-10-09T10:03:40.000000Z",
      "updated_at": "2026-10-09T10:41:57.000000Z",
      "deleted_at": null,
      "category": {
        "id": 1,
        "name": "All",
        "full_name": "All",
        "parent_path": "/",
        "parent_id": null,
        "creator_id": 1,
        "created_at": "2025-01-28T10:49:51.000000Z",
        "updated_at": "2025-01-28T10:49:51.000000Z"
      },
      "tags": [
        {
          "id": 1,
          "name": "Fashion Product",
          "color": null,
          "created_at": "2026-10-09T10:02:45.000000Z",
          "updated_at": "2026-10-09T10:02:45.000000Z",
          "deleted_at": null
        }
      ]
    },
    {
      "id": 1,
      "type": "goods",
      "name": "T-Shirt",
      "service_tracking": "none",
      "reference": null,
      "barcode": null,
      "price": 250,
      "cost": 220,
      "volume": 2501,
      "weight": 1,
      "description": "<p>Men&#039;s wear tshirt in multiple variant colors like that tell me.</p>",
      "description_purchase": null,
      "description_sale": null,
      "enable_sales": false,
      "enable_purchase": false,
      "is_favorite": false,
      "is_configurable": false,
      "images": [
        "01M4G1WMQZ0T9EBB2F6CERDFTV.jpg"
      ],
      "sort": 1,
      "parent_id": null,
      "uom_id": 1,
      "uom_po_id": 1,
      "category_id": 1,
      "creator_id": 1,
      "company_id": 1,
      "created_at": "2026-10-09T10:03:40.000000Z",
      "updated_at": "2026-10-09T10:41:57.000000Z",
      "deleted_at": null,
      "category": {
        "id": 1,
        "name": "All",
        "full_name": "All",
        "parent_path": "/",
        "parent_id": null,
        "creator_id": 1,
        "created_at": "2025-01-28T10:49:51.000000Z",
        "updated_at": "2025-01-28T10:49:51.000000Z"
      },
      "tags": [
        {
          "id": 1,
          "name": "Fashion Product",
          "color": null,
          "created_at": "2026-10-09T10:02:45.000000Z",
          "updated_at": "2026-10-09T10:02:45.000000Z",
          "deleted_at": null
        }
      ]
    }
  ],
  "links": {
    "first": "/?page=1",
    "last": "/?page=1",
    "prev": null,
    "next": null
  },
  "meta": {
    "current_page": 1,
    "from": 1,
    "last_page": 1,
    "links": [
      {
        "url": null,
        "label": "&laquo; Previous",
        "page": null,
        "active": false
      },
      {
        "url": "/?page=1",
        "label": "1",
        "page": 1,
        "active": true
      },
      {
        "url": null,
        "label": "Next &raquo;",
        "page": null,
        "active": false
      }
    ],
    "path": "/",
    "per_page": 10,
    "to": 2,
    "total": 2
  }
}
Error response — 401
json
{
  "message": "Unauthenticated."
}

Create product ​

POST /admin/api/v1/products/products

Create a new product

🔒 Requires a valid Bearer token.

Body parameters

ParameterTypeRequiredDescription
typestringYesProduct type: goods, service, consu (consumable).
namestringYesProduct name (max 255 characters). Must not be greater than 255 characters.
service_trackingstringNoMust not be greater than 255 characters.
referencestringNoInternal reference code (max 255 characters). Must not be greater than 255 characters.
barcodestringNoProduct barcode (max 255 characters). Must not be greater than 255 characters.
pricenumberYesSales price (minimum 0). Must be at least 0.
costnumberNoProduct cost (minimum 0). Must be at least 0.
volumenumberNoProduct volume (min 0, max 99999999999). Must be at least 0. Must not be greater than 99999999999.
weightnumberNoProduct weight (min 0, max 99999999999). Must be at least 0. Must not be greater than 99999999999.
descriptionstringNoProduct description.
description_purchasestringNoPurchase description.
description_salestringNoSales description.
enable_salesbooleanNoWhether this product can be sold.
enable_purchasebooleanNoWhether this product can be purchased.
is_favoritebooleanNoMark this product as favorite.
imagesstring[]No
uom_idintegerNoUnit of measure ID.
uom_po_idintegerNoPurchase unit of measure ID.
category_idintegerYesProduct category ID. Must match an existing stored value.
company_idintegerNoCompany ID this product belongs to.
tagsinteger[]NoMust match an existing stored value.
bash
curl -X POST "https://your-domain.com/admin/api/v1/products/products" \
  -H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
  "type": "goods",
  "name": "Laptop Computer",
  "service_tracking": "b",
  "reference": "PROD-001",
  "barcode": "1234567890",
  "price": 999.99,
  "cost": 750,
  "volume": 0.5,
  "weight": 2.5,
  "description": "High-performance laptop with latest specifications.",
  "description_purchase": "Enterprise laptop for business use.",
  "description_sale": "Perfect for professionals and power users.",
  "enable_sales": true,
  "enable_purchase": true,
  "is_favorite": false,
  "images": [
    "architecto"
  ],
  "uom_id": 1,
  "uom_po_id": 1,
  "category_id": 1,
  "company_id": 1,
  "tags": [
    16
  ]
}'
javascript
const response = await fetch("https://your-domain.com/admin/api/v1/products/products", {
  method: "POST",
  headers: {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
  "type": "goods",
  "name": "Laptop Computer",
  "service_tracking": "b",
  "reference": "PROD-001",
  "barcode": "1234567890",
  "price": 999.99,
  "cost": 750,
  "volume": 0.5,
  "weight": 2.5,
  "description": "High-performance laptop with latest specifications.",
  "description_purchase": "Enterprise laptop for business use.",
  "description_sale": "Perfect for professionals and power users.",
  "enable_sales": true,
  "enable_purchase": true,
  "is_favorite": false,
  "images": [
    "architecto"
  ],
  "uom_id": 1,
  "uom_po_id": 1,
  "category_id": 1,
  "company_id": 1,
  "tags": [
    16
  ]
}),
});

const data = await response.json();
console.log(data);
php
<?php

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://your-domain.com/admin/api/v1/products/products', [
    'headers' => [
        'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
    'json' => [
    'type' => 'goods',
    'name' => 'Laptop Computer',
    'service_tracking' => 'b',
    'reference' => 'PROD-001',
    'barcode' => '1234567890',
    'price' => 999.99,
    'cost' => 750,
    'volume' => 0.5,
    'weight' => 2.5,
    'description' => 'High-performance laptop with latest specifications.',
    'description_purchase' => 'Enterprise laptop for business use.',
    'description_sale' => 'Perfect for professionals and power users.',
    'enable_sales' => true,
    'enable_purchase' => true,
    'is_favorite' => false,
    'images' => [
      'architecto',
    ],
    'uom_id' => 1,
    'uom_po_id' => 1,
    'category_id' => 1,
    'company_id' => 1,
    'tags' => [
      16,
    ],
  ],
]);

$data = json_decode($response->getBody(), true);
python
import requests

url = "https://your-domain.com/admin/api/v1/products/products"

headers = {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

payload = {
    "type": "goods",
    "name": "Laptop Computer",
    "service_tracking": "b",
    "reference": "PROD-001",
    "barcode": "1234567890",
    "price": 999.99,
    "cost": 750,
    "volume": 0.5,
    "weight": 2.5,
    "description": "High-performance laptop with latest specifications.",
    "description_purchase": "Enterprise laptop for business use.",
    "description_sale": "Perfect for professionals and power users.",
    "enable_sales": True,
    "enable_purchase": True,
    "is_favorite": False,
    "images": [
        "architecto",
    ],
    "uom_id": 1,
    "uom_po_id": 1,
    "category_id": 1,
    "company_id": 1,
    "tags": [
        16,
    ],
}

response = requests.post(url, headers=headers, json=payload)

data = response.json()
print(data)

Example response 201

json
{
  "data": {
    "id": 1,
    "type": "goods",
    "name": "T-Shirt",
    "service_tracking": "none",
    "reference": null,
    "barcode": null,
    "price": 250,
    "cost": 220,
    "volume": 2501,
    "weight": 1,
    "description": "<p>Men&#039;s wear tshirt in multiple variant colors like that tell me.</p>",
    "description_purchase": null,
    "description_sale": null,
    "enable_sales": false,
    "enable_purchase": false,
    "is_favorite": false,
    "is_configurable": false,
    "images": [
      "01M4G1WMQZ0T9EBB2F6CERDFTV.jpg"
    ],
    "sort": 1,
    "parent_id": null,
    "uom_id": 1,
    "uom_po_id": 1,
    "category_id": 1,
    "creator_id": 1,
    "company_id": 1,
    "created_at": "2026-10-09T10:03:40.000000Z",
    "updated_at": "2026-10-09T10:41:57.000000Z",
    "deleted_at": null,
    "category": {
      "id": 1,
      "name": "All",
      "full_name": "All",
      "parent_path": "/",
      "parent_id": null,
      "creator_id": 1,
      "created_at": "2025-01-28T10:49:51.000000Z",
      "updated_at": "2025-01-28T10:49:51.000000Z"
    },
    "tags": [
      {
        "id": 1,
        "name": "Fashion Product",
        "color": null,
        "created_at": "2026-10-09T10:02:45.000000Z",
        "updated_at": "2026-10-09T10:02:45.000000Z",
        "deleted_at": null
      }
    ]
  },
  "message": "Product created successfully."
}
Error response — 401
json
{
  "message": "Unauthenticated."
}

Show product ​

GET /admin/api/v1/products/products/{id}

Retrieve a specific product by its ID

🔒 Requires a valid Bearer token.

Path parameters

ParameterTypeRequiredDescription
idintegerYesThe product ID

Query parameters

ParameterTypeRequiredDescriptionExample
includestringNoComma-separated list of relationships to include. Available options: parent, variants, uom, uomPO, category, attributes, attribute_values, tags, company, creatorcategory,tags
bash
curl -X GET "https://your-domain.com/admin/api/v1/products/products/{id}?include=category%2Ctags" \
  -H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json"
javascript
const response = await fetch("https://your-domain.com/admin/api/v1/products/products/{id}?include=category%2Ctags", {
  method: "GET",
  headers: {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
  },
});

const data = await response.json();
console.log(data);
php
<?php

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://your-domain.com/admin/api/v1/products/products/{id}?include=category%2Ctags', [
    'headers' => [
        'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
]);

$data = json_decode($response->getBody(), true);
python
import requests

url = "https://your-domain.com/admin/api/v1/products/products/{id}?include=category%2Ctags"

headers = {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

response = requests.get(url, headers=headers)

data = response.json()
print(data)

Example response 200

json
{
  "data": {
    "id": 1,
    "type": "goods",
    "name": "T-Shirt",
    "service_tracking": "none",
    "reference": null,
    "barcode": null,
    "price": 250,
    "cost": 220,
    "volume": 2501,
    "weight": 1,
    "description": "<p>Men&#039;s wear tshirt in multiple variant colors like that tell me.</p>",
    "description_purchase": null,
    "description_sale": null,
    "enable_sales": false,
    "enable_purchase": false,
    "is_favorite": false,
    "is_configurable": false,
    "images": [
      "01M4G1WMQZ0T9EBB2F6CERDFTV.jpg"
    ],
    "sort": 1,
    "parent_id": null,
    "uom_id": 1,
    "uom_po_id": 1,
    "category_id": 1,
    "creator_id": 1,
    "company_id": 1,
    "created_at": "2026-10-09T10:03:40.000000Z",
    "updated_at": "2026-10-09T10:41:57.000000Z",
    "deleted_at": null,
    "category": {
      "id": 1,
      "name": "All",
      "full_name": "All",
      "parent_path": "/",
      "parent_id": null,
      "creator_id": 1,
      "created_at": "2025-01-28T10:49:51.000000Z",
      "updated_at": "2025-01-28T10:49:51.000000Z"
    },
    "tags": [
      {
        "id": 1,
        "name": "Fashion Product",
        "color": null,
        "created_at": "2026-10-09T10:02:45.000000Z",
        "updated_at": "2026-10-09T10:02:45.000000Z",
        "deleted_at": null
      }
    ]
  }
}
Error response — 401
json
{
  "message": "Unauthenticated."
}

Update product ​

PUT /admin/api/v1/products/products/{id}

Update an existing product

🔒 Requires a valid Bearer token.

Path parameters

ParameterTypeRequiredDescription
idintegerYesThe product ID

Body parameters

ParameterTypeRequiredDescription
typestringNoProduct type: goods, service, consu (consumable).
namestringNoProduct name (max 255 characters). Must not be greater than 255 characters.
service_trackingstringNoMust not be greater than 255 characters.
referencestringNoInternal reference code (max 255 characters). Must not be greater than 255 characters.
barcodestringNoProduct barcode (max 255 characters). Must not be greater than 255 characters.
pricenumberNoSales price (minimum 0). Must be at least 0.
costnumberNoProduct cost (minimum 0). Must be at least 0.
volumenumberNoProduct volume (min 0, max 99999999999). Must be at least 0. Must not be greater than 99999999999.
weightnumberNoProduct weight (min 0, max 99999999999). Must be at least 0. Must not be greater than 99999999999.
descriptionstringNoProduct description.
description_purchasestringNoPurchase description.
description_salestringNoSales description.
enable_salesbooleanNoWhether this product can be sold.
enable_purchasebooleanNoWhether this product can be purchased.
is_favoritebooleanNoMark this product as favorite.
imagesstring[]No
uom_idintegerNoUnit of measure ID.
uom_po_idintegerNoPurchase unit of measure ID.
category_idintegerNoProduct category ID. Must match an existing stored value.
company_idintegerNoCompany ID this product belongs to.
tagsinteger[]NoMust match an existing stored value.
bash
curl -X PUT "https://your-domain.com/admin/api/v1/products/products/{id}" \
  -H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
  "type": "goods",
  "name": "Laptop Computer",
  "service_tracking": "b",
  "reference": "PROD-001",
  "barcode": "1234567890",
  "price": 999.99,
  "cost": 750,
  "volume": 0.5,
  "weight": 2.5,
  "description": "High-performance laptop with latest specifications.",
  "description_purchase": "Enterprise laptop for business use.",
  "description_sale": "Perfect for professionals and power users.",
  "enable_sales": true,
  "enable_purchase": true,
  "is_favorite": false,
  "images": [
    "architecto"
  ],
  "uom_id": 1,
  "uom_po_id": 1,
  "category_id": 1,
  "company_id": 1,
  "tags": [
    16
  ]
}'
javascript
const response = await fetch("https://your-domain.com/admin/api/v1/products/products/{id}", {
  method: "PUT",
  headers: {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
  "type": "goods",
  "name": "Laptop Computer",
  "service_tracking": "b",
  "reference": "PROD-001",
  "barcode": "1234567890",
  "price": 999.99,
  "cost": 750,
  "volume": 0.5,
  "weight": 2.5,
  "description": "High-performance laptop with latest specifications.",
  "description_purchase": "Enterprise laptop for business use.",
  "description_sale": "Perfect for professionals and power users.",
  "enable_sales": true,
  "enable_purchase": true,
  "is_favorite": false,
  "images": [
    "architecto"
  ],
  "uom_id": 1,
  "uom_po_id": 1,
  "category_id": 1,
  "company_id": 1,
  "tags": [
    16
  ]
}),
});

const data = await response.json();
console.log(data);
php
<?php

$client = new \GuzzleHttp\Client();

$response = $client->request('PUT', 'https://your-domain.com/admin/api/v1/products/products/{id}', [
    'headers' => [
        'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
    'json' => [
    'type' => 'goods',
    'name' => 'Laptop Computer',
    'service_tracking' => 'b',
    'reference' => 'PROD-001',
    'barcode' => '1234567890',
    'price' => 999.99,
    'cost' => 750,
    'volume' => 0.5,
    'weight' => 2.5,
    'description' => 'High-performance laptop with latest specifications.',
    'description_purchase' => 'Enterprise laptop for business use.',
    'description_sale' => 'Perfect for professionals and power users.',
    'enable_sales' => true,
    'enable_purchase' => true,
    'is_favorite' => false,
    'images' => [
      'architecto',
    ],
    'uom_id' => 1,
    'uom_po_id' => 1,
    'category_id' => 1,
    'company_id' => 1,
    'tags' => [
      16,
    ],
  ],
]);

$data = json_decode($response->getBody(), true);
python
import requests

url = "https://your-domain.com/admin/api/v1/products/products/{id}"

headers = {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

payload = {
    "type": "goods",
    "name": "Laptop Computer",
    "service_tracking": "b",
    "reference": "PROD-001",
    "barcode": "1234567890",
    "price": 999.99,
    "cost": 750,
    "volume": 0.5,
    "weight": 2.5,
    "description": "High-performance laptop with latest specifications.",
    "description_purchase": "Enterprise laptop for business use.",
    "description_sale": "Perfect for professionals and power users.",
    "enable_sales": True,
    "enable_purchase": True,
    "is_favorite": False,
    "images": [
        "architecto",
    ],
    "uom_id": 1,
    "uom_po_id": 1,
    "category_id": 1,
    "company_id": 1,
    "tags": [
        16,
    ],
}

response = requests.put(url, headers=headers, json=payload)

data = response.json()
print(data)

Example response 200

json
{
  "data": {
    "id": 1,
    "type": "goods",
    "name": "T-Shirt",
    "service_tracking": "none",
    "reference": null,
    "barcode": null,
    "price": 250,
    "cost": 220,
    "volume": 2501,
    "weight": 1,
    "description": "<p>Men&#039;s wear tshirt in multiple variant colors like that tell me.</p>",
    "description_purchase": null,
    "description_sale": null,
    "enable_sales": false,
    "enable_purchase": false,
    "is_favorite": false,
    "is_configurable": false,
    "images": [
      "01M4G1WMQZ0T9EBB2F6CERDFTV.jpg"
    ],
    "sort": 1,
    "parent_id": null,
    "uom_id": 1,
    "uom_po_id": 1,
    "category_id": 1,
    "creator_id": 1,
    "company_id": 1,
    "created_at": "2026-10-09T10:03:40.000000Z",
    "updated_at": "2026-10-09T10:41:57.000000Z",
    "deleted_at": null,
    "category": {
      "id": 1,
      "name": "All",
      "full_name": "All",
      "parent_path": "/",
      "parent_id": null,
      "creator_id": 1,
      "created_at": "2025-01-28T10:49:51.000000Z",
      "updated_at": "2025-01-28T10:49:51.000000Z"
    },
    "tags": [
      {
        "id": 1,
        "name": "Fashion Product",
        "color": null,
        "created_at": "2026-10-09T10:02:45.000000Z",
        "updated_at": "2026-10-09T10:02:45.000000Z",
        "deleted_at": null
      }
    ]
  },
  "message": "Product updated successfully."
}
Error response — 401
json
{
  "message": "Unauthenticated."
}

Delete product ​

DELETE /admin/api/v1/products/products/{id}

Soft delete a product

🔒 Requires a valid Bearer token.

Path parameters

ParameterTypeRequiredDescription
idintegerYesThe product ID
bash
curl -X DELETE "https://your-domain.com/admin/api/v1/products/products/{id}" \
  -H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json"
javascript
const response = await fetch("https://your-domain.com/admin/api/v1/products/products/{id}", {
  method: "DELETE",
  headers: {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
  },
});

const data = await response.json();
console.log(data);
php
<?php

$client = new \GuzzleHttp\Client();

$response = $client->request('DELETE', 'https://your-domain.com/admin/api/v1/products/products/{id}', [
    'headers' => [
        'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
]);

$data = json_decode($response->getBody(), true);
python
import requests

url = "https://your-domain.com/admin/api/v1/products/products/{id}"

headers = {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

response = requests.delete(url, headers=headers)

data = response.json()
print(data)

Example response 200

json
{
  "message": "Product deleted successfully."
}
Error response — 401
json
{
  "message": "Unauthenticated."
}

Restore product ​

POST /admin/api/v1/products/products/{id}/restore

Restore a soft-deleted product

🔒 Requires a valid Bearer token.

Path parameters

ParameterTypeRequiredDescription
idintegerYesThe product ID
bash
curl -X POST "https://your-domain.com/admin/api/v1/products/products/{id}/restore" \
  -H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json"
javascript
const response = await fetch("https://your-domain.com/admin/api/v1/products/products/{id}/restore", {
  method: "POST",
  headers: {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
  },
});

const data = await response.json();
console.log(data);
php
<?php

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://your-domain.com/admin/api/v1/products/products/{id}/restore', [
    'headers' => [
        'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
]);

$data = json_decode($response->getBody(), true);
python
import requests

url = "https://your-domain.com/admin/api/v1/products/products/{id}/restore"

headers = {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

response = requests.post(url, headers=headers)

data = response.json()
print(data)

Example response 200

json
{
  "data": {
    "id": 1,
    "type": "goods",
    "name": "T-Shirt",
    "service_tracking": "none",
    "reference": null,
    "barcode": null,
    "price": 250,
    "cost": 220,
    "volume": 2501,
    "weight": 1,
    "description": "<p>Men&#039;s wear tshirt in multiple variant colors like that tell me.</p>",
    "description_purchase": null,
    "description_sale": null,
    "enable_sales": false,
    "enable_purchase": false,
    "is_favorite": false,
    "is_configurable": false,
    "images": [
      "01M4G1WMQZ0T9EBB2F6CERDFTV.jpg"
    ],
    "sort": 1,
    "parent_id": null,
    "uom_id": 1,
    "uom_po_id": 1,
    "category_id": 1,
    "creator_id": 1,
    "company_id": 1,
    "created_at": "2026-10-09T10:03:40.000000Z",
    "updated_at": "2026-10-09T10:41:57.000000Z",
    "deleted_at": null,
    "category": {
      "id": 1,
      "name": "All",
      "full_name": "All",
      "parent_path": "/",
      "parent_id": null,
      "creator_id": 1,
      "created_at": "2025-01-28T10:49:51.000000Z",
      "updated_at": "2025-01-28T10:49:51.000000Z"
    },
    "tags": [
      {
        "id": 1,
        "name": "Fashion Product",
        "color": null,
        "created_at": "2026-10-09T10:02:45.000000Z",
        "updated_at": "2026-10-09T10:02:45.000000Z",
        "deleted_at": null
      }
    ]
  },
  "message": "Product restored successfully."
}
Error response — 401
json
{
  "message": "Unauthenticated."
}

Force delete product ​

DELETE /admin/api/v1/products/products/{id}/force

Permanently delete a product (cannot be restored)

🔒 Requires a valid Bearer token.

Path parameters

ParameterTypeRequiredDescription
idintegerYesThe product ID
bash
curl -X DELETE "https://your-domain.com/admin/api/v1/products/products/{id}/force" \
  -H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json"
javascript
const response = await fetch("https://your-domain.com/admin/api/v1/products/products/{id}/force", {
  method: "DELETE",
  headers: {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
  },
});

const data = await response.json();
console.log(data);
php
<?php

$client = new \GuzzleHttp\Client();

$response = $client->request('DELETE', 'https://your-domain.com/admin/api/v1/products/products/{id}/force', [
    'headers' => [
        'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
        'Accept' => 'application/json',
        'Content-Type' => 'application/json',
    ],
]);

$data = json_decode($response->getBody(), true);
python
import requests

url = "https://your-domain.com/admin/api/v1/products/products/{id}/force"

headers = {
    "Authorization": "Bearer {YOUR_AUTH_TOKEN}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

response = requests.delete(url, headers=headers)

data = response.json()
print(data)

Example response 200

json
{
  "message": "Product permanently deleted."
}
Error response — 401
json
{
  "message": "Unauthenticated."
}

Released under the MIT License.