Skip to main content
POST
/
v1
/
discounts
Create discount
curl --request POST \
  --url https://api.quentli.com/v1/discounts \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "input": {
    "name": "Buen Fin 20%",
    "type": "PERCENTAGE",
    "description": null,
    "codes": [
      "BUEN-FIN-2025"
    ],
    "amountOff": null,
    "percentageOff": 20,
    "active": true,
    "oneOff": false,
    "expiresAt": null,
    "maxApplications": null
  }
}
'
{
  "discount": {
    "id": "disc_1234567890abcdefghij",
    "createdAt": "2025-01-01T00:00:00.000Z",
    "updatedAt": "2025-01-01T00:00:00.000Z",
    "name": "Buen Fin 20%",
    "organizationId": "org_1234567890abcdefghij",
    "type": "PERCENTAGE",
    "active": true,
    "oneOff": false,
    "deletedAt": null,
    "description": null,
    "amountOff": 30000,
    "percentageOff": 20,
    "expiresAt": null,
    "maxApplications": 3
  }
}

Authorizations

Authorization
string
header
required

Organization API key using Authorization: Bearer sk_....

Body

application/json

Request body for creating a discount.

input
object
required

Response

Discount created

Newly created discount.

discount
object
required

A reusable discount that can be applied to invoices or subscriptions.