POST v1/ProductOptions

BETA

Create a list of ProductOptions **This endpoint is in BETA.**

Request Information

URI Parameters

None.

Body Parameters

Collection of CreateProductOptionsRequest
NameDescriptionTypeAdditional information

Status

ProductOptionStatus

Required

ProductId

The id of the Product this product option belongs to.

integer

Required

Range: inclusive between 1 and 2147483647

ProductOptionCode

A unique Code for this product option.

string

Required

Max length: 20

ProductOptionBarcode

A unique barcode

string

Max length: 20

SupplierCode

string

Max length: 20

Option1

string

Max length: 50

Option2

string

Max length: 50

Option3

string

Max length: 50

SpecialPrice

The special price

decimal number

None.

SpecialsStartDate

Start date for the speical price to apply

date

None.

SpecialDays

How many days the special will run starting from the SpecialsStartDate

integer

None.

OptionWeight

The option weight

decimal number

None.

UomOptions

An array of unit of measures.

Collection of UomRequest

Max length: 20

PriceColumns

Dictionary of string [key] and decimal number [value]

None.

Sizes

Product option sizes. A size range id needs to be assigned to the product before creating sizes.

Collection of SizeRequest

Max length: 20

Request Formats

application/json, text/json

Sample:
[
  {
    "status": "Disabled",
    "productId": 1,
    "productOptionCode": "sample string 2",
    "productOptionBarcode": "sample string 3",
    "supplierCode": "sample string 4",
    "option1": "sample string 5",
    "option2": "sample string 6",
    "option3": "sample string 7",
    "specialPrice": 8.0,
    "specialsStartDate": "2025-03-27T15:29:39.6616334+13:00",
    "specialDays": 9,
    "optionWeight": 10.0,
    "uomOptions": [
      {
        "id": 1,
        "code": "sample string 1",
        "option1": "sample string 2",
        "option2": "sample string 3",
        "option3": "sample string 4",
        "quantity": 1.0,
        "barcode": "sample string 5",
        "supplierCode": "sample string 6",
        "priceColumns": {
          "sample string 1": 1.0,
          "sample string 2": 1.0
        }
      },
      {
        "id": 1,
        "code": "sample string 1",
        "option1": "sample string 2",
        "option2": "sample string 3",
        "option3": "sample string 4",
        "quantity": 1.0,
        "barcode": "sample string 5",
        "supplierCode": "sample string 6",
        "priceColumns": {
          "sample string 1": 1.0,
          "sample string 2": 1.0
        }
      }
    ],
    "priceColumns": {
      "sample string 1": 1.0,
      "sample string 2": 1.0
    },
    "sizes": [
      {
        "sizeId": 1,
        "size": "sample string 1",
        "sizeCode": "sample string 2",
        "sizeBarcode": "sample string 3"
      },
      {
        "sizeId": 1,
        "size": "sample string 1",
        "sizeCode": "sample string 2",
        "sizeBarcode": "sample string 3"
      }
    ]
  },
  {
    "status": "Disabled",
    "productId": 1,
    "productOptionCode": "sample string 2",
    "productOptionBarcode": "sample string 3",
    "supplierCode": "sample string 4",
    "option1": "sample string 5",
    "option2": "sample string 6",
    "option3": "sample string 7",
    "specialPrice": 8.0,
    "specialsStartDate": "2025-03-27T15:29:39.6616334+13:00",
    "specialDays": 9,
    "optionWeight": 10.0,
    "uomOptions": [
      {
        "id": 1,
        "code": "sample string 1",
        "option1": "sample string 2",
        "option2": "sample string 3",
        "option3": "sample string 4",
        "quantity": 1.0,
        "barcode": "sample string 5",
        "supplierCode": "sample string 6",
        "priceColumns": {
          "sample string 1": 1.0,
          "sample string 2": 1.0
        }
      },
      {
        "id": 1,
        "code": "sample string 1",
        "option1": "sample string 2",
        "option2": "sample string 3",
        "option3": "sample string 4",
        "quantity": 1.0,
        "barcode": "sample string 5",
        "supplierCode": "sample string 6",
        "priceColumns": {
          "sample string 1": 1.0,
          "sample string 2": 1.0
        }
      }
    ],
    "priceColumns": {
      "sample string 1": 1.0,
      "sample string 2": 1.0
    },
    "sizes": [
      {
        "sizeId": 1,
        "size": "sample string 1",
        "sizeCode": "sample string 2",
        "sizeBarcode": "sample string 3"
      },
      {
        "sizeId": 1,
        "size": "sample string 1",
        "sizeCode": "sample string 2",
        "sizeBarcode": "sample string 3"
      }
    ]
  }
]

Response Information

Resource Description

Collection of BatchResultItem
NameDescriptionTypeAdditional information

Index

​The index at which the record was positioned in an insert or update.

integer

None.

Success

​True if the record was successfully inserted or updated.

boolean

None.

Id

The record Id.

integer

None.

Code

The record code.

string

None.

Errors

A list of errors if the insert or update fails.

Collection of string

None.

Response Formats

application/json, text/json

Sample:
[
  {
    "index": 0,
    "success": true,
    "id": 1,
    "code": "SALE4-28",
    "errors": []
  },
  {
    "index": 1,
    "success": true,
    "id": 2,
    "code": "SALE5-29",
    "errors": []
  }
]