Delete Discount Code

Allows you to remove a discount code from a specified price rule.

🔒

Requires price_rules access scope. More access scope

The Delete Discount Code API allows you to remove a discount code from a specified price rule.

This API is especially useful for:

  1. Removing obsolete discount codes.
  2. Managing discount codes dynamically.
  3. Ensuring that invalid or expired discount codes do not remain active.

Request Parameters

Public Request Parameters

📘

Path Parameters

ParameterTypeRequiredDescriptionExample
price_rule_idstringYesID of the price rule associated with the discount codepr_123456
discount_code_idstringYesID of the discount code to retrieve details fordc_789012

Response Explanation

Public Response Parameters

📘

Successful Response

ParameterTypeExampleDescription
codestring200Error code (200 indicates success)
messagestringSuccessError message
dataobject{...}

Error Response

FieldTypeExampleDescription
codestringInvalidParameterError http message
messagestring``Error message

API Structure Overview

Language
Credentials
Header
URL
Click Try It! to start a request and see the response here!