Skip to main content
POST
/
events
/
products
/
update
Update Product
curl --request POST \
  --url https://api.nuwebgroup.com/v1/events/products/update \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "saleItemData": {
    "id": 1,
    "pricing": [],
    "totalStock": 500,
    "parentSaleItemId": null,
    "onSaleFrom": "2021-11-22 11:59:00",
    "onSaleUntil": "2021-11-22 11:59:00",
    "validFrom": "2021-11-22 11:59:00",
    "validUntil": "2021-11-22 11:59:00",
    "scanningGracePeriod": 12,
    "minOrderQuantity": 10,
    "maxOrderQuantity": 30,
    "multiplesOf": 10,
    "additionalInformation": "Lorem ipsum dolor sit amet",
    "attractsDiscount": false,
    "canBeDownloaded": false,
    "canAccessStream": true,
    "hideWhenOffSale": true,
    "hideWhenOutOfStock": true
  },
  "itemData": {
    "name": "Lorem ipsum",
    "description": "Lorem ipsum dolor sit amet",
    "totalStock": 123,
    "hasUnlimitedStock": false,
    "requiresApproval": true
  }
}
'
{
  "data": {
    "type": "saleItems",
    "id": 1,
    "attributes": {
      "totalStock": 500,
      "currentStock": 500,
      "onSaleFrom": "2021-11-22T11:59:00.000000Z",
      "onSaleUntil": "2021-11-22T11:59:00.000000Z",
      "validFrom": "2021-11-22T11:59:00.000000Z",
      "validUntil": "2021-11-22T11:59:00.000000Z",
      "scanningGracePeriod": 12,
      "minOrderQuantity": 10,
      "maxOrderQuantity": 30,
      "multiplesOf": 10,
      "orderColumn": null,
      "additionalInformation": "Lorem ipsum dolor sit amet",
      "attractsDiscount": false,
      "canBeDownloaded": false,
      "canAccessStream": true,
      "hideWhenOffSale": true,
      "hideWhenOutOfStock": true,
      "hideFromBoxOffice": false,
      "hideFromShop": false,
      "createdAt": "2021-11-22T11:59:00.000000Z",
      "updatedAt": "2021-11-22T11:59:00.000000Z"
    },
    "relationships": {
      "items": {
        "data": {
          "type": "items",
          "id": 1
        }
      }
    }
  },
  "included": [
    {
      "type": "items",
      "id": 1,
      "attributes": {
        "type": "product",
        "name": "Lorem ipsum",
        "description": "Lorem ipsum dolor sit amet",
        "totalStock": 500,
        "currentStock": 500,
        "hasUnlimitedStock": false,
        "requiresApproval": true,
        "createdAt": "2021-11-22T11:59:00.000000Z",
        "updatedAt": "2021-11-22T11:59:00.000000Z"
      }
    }
  ]
}

Authorizations

Authorization
string
header
required

The 'Bearer' token can be obtained from the token management interface or via the login endpoint using your admin user credentials.

Body

application/json

Request body for updating a product sale item.

saleItemData
object
itemData
object

Response

Successfully updated the product sale item.

data
object
included
object[]