---
updatedAt: 2026-09-16T14:56:26.000Z
agentTools:
  projectIndex: https://docs.stay.ai/llms.txt
---

# Add Discount

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "line-updates",
    "version": "2.0"
  },
  "servers": [
    {
      "url": "https://api.retextion.com/api/v2/subscriptions"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "in": "header",
        "x-default": "{{APP_API_KEY}}",
        "name": "X-RETEXTION-ACCESS-TOKEN"
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/{subscriptionId}/add-discount": {
      "post": {
        "summary": "Add Discount",
        "description": "",
        "operationId": "add-discount",
        "parameters": [
          {
            "name": "subscriptionId",
            "in": "path",
            "description": "Internal or external subscription line item ID.",
            "schema": {
              "type": "string"
            },
            "required": true
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "redeemCode"
                ],
                "properties": {
                  "redeemCode": {
                    "type": "string",
                    "description": "Shopify Discount Code"
                  },
                  "initiator": {
                    "type": "string",
                    "description": "Initiating actor. Can be `MERCHANT` or `CUSTOMER`. Default: `MERCHANT`"
                  }
                }
              },
              "examples": {
                "Request Example": {
                  "value": {
                    "redeemCode": "MYPROMOCODE",
                    "initiator": "MERCHANT"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"success\": true\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "example": true,
                      "default": true
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {}
                }
              }
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```