Assembling the order

  • HOME
  • Assembling the order
API 06.09.2025

NWMS API - Product Management


This section describes how to manage products (offers) using the NWMS API. It includes retrieving, creating, updating, and deleting products.

Available Endpoints


  • GET /api/products – List products (with filters, sorting, pagination)
  • POST /api/products – Create a product
  • GET /api/products/{id} – Get product by ID
  • PUT /api/products/{id} – Update product
  • DELETE /api/products/{id} – Soft delete product

Example: Get products with filters and sorting


GET /api/products?sku=ABC123&sort_by=of_price&sort_dir=desc&per_page=10
Authorization: Bearer YOUR_ACCESS_TOKEN

Example: Create product

POST /api/products
Authorization: Bearer YOUR_ACCESS_TOKEN
Content-Type: application/json

{
  "of_name": "Test Product",
  "of_status": 1,
  "of_sku": "SKU123",
  "of_price": 199.99
}

Response Format

All responses use the OfferResource to format output:

{
  "id": 1,
  "name": "Test Product",
  "sku": "SKU123",
  "article": null,
  "price": 199.99,
  "status": 1,
  "shop_id": 2,
  "domain_id": 1,
  "dimensions": {
    "x": null,
    "y": null,
    "z": null
  },
  "weight": null,
  "image": null,
  "comment": null,
  "created_at": "2025-04-17T14:00:00.000000Z",
  "updated_at": "2025-04-17T14:00:00.000000Z"
}

Authorization

All endpoints require a valid Bearer token obtained via the login API.