Skip to content
Get started

Creates or updates discount prices for products.

ProductCreateDiscountPricesResponse Products.CreateDiscountPrices(ProductCreateDiscountPricesParams?parameters, CancellationTokencancellationToken = default)
POST/api/v2/public/products/discountprices

Creates or updates discount prices for products.

ParametersExpand Collapse
ProductCreateDiscountPricesParams parameters
IReadOnlyList<Discount>? discounts

Body param: The list of discount price entries.

string? DiscountDescription
string? DiscountGroup
string? DiscountID
Long? DiscountType
formatint64
Boolean IsDelete
Long? LineNumber
formatint64
Float? Price
formatfloat
string? ProductNumber

The product number this discount applies to.

DateTimeOffset? ValidFrom
formatdate-time
DateTimeOffset? ValidTo
formatdate-time
Boolean isFlush

Header param: When true, removes existing discount prices before inserting.

ReturnsExpand Collapse
class ProductCreateDiscountPricesResponse:

Standard success response returned by mutation endpoints.

string? Data

Optional data payload returned by the operation.

string? Message

Human-readable message describing the result.

Boolean Success

Indicates whether the operation completed successfully.

Creates or updates discount prices for products.

ProductCreateDiscountPricesParams parameters = new();

var response = await client.Products.CreateDiscountPrices(parameters);

Console.WriteLine(response);
{
  "data": "12345",
  "message": "Record created successfully.",
  "success": true
}
Returns Examples
{
  "data": "12345",
  "message": "Record created successfully.",
  "success": true
}