## Creates or updates discount prices for products.

**post** `/api/v2/public/products/discountprices`

Creates or updates discount prices for products.

### Header Parameters

- `is_expire_discounts: optional boolean`

- `is_flush: optional boolean`

### Body Parameters

- `discounts: optional array of object { is_delete, discount_description, discount_group, 7 more }`

  The list of discount price entries.

  - `is_delete: boolean`

    When true, removes the existing discount entry.

  - `discount_description: optional string`

    Human-readable description of the discount.

  - `discount_group: optional string`

    Optional discount group identifier.

  - `discount_id: optional string`

    Unique discount identifier.

  - `discount_type: optional number`

    Numeric discount type.

  - `line_number: optional number`

    Line number on the discount.

  - `price: optional number`

    Discounted price value.

  - `product_number: optional string`

    The product number this discount applies to.

  - `valid_from: optional string`

    Start of the discount's validity period.

  - `valid_to: optional string`

    End of the discount's validity period.

### Returns

- `success: boolean`

  Indicates whether the operation completed successfully.

- `data: optional string`

  Optional data payload returned by the operation.

- `message: optional string`

  Human-readable message describing the result.

### Example

```http
curl https://api.colleqtive.net/api/v2/public/products/discountprices \
    -X POST \
    -H "Authorization: $COLLEQTIVE_BEARER_TOKEN"
```

#### Response

```json
{
  "success": true,
  "data": "data",
  "message": "message"
}
```
