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
}
}Creates a new reusable 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
}
}Organization API key using Authorization: Bearer sk_....
Request body for creating a discount.
Show child attributes
Discount created
Newly created discount.
A reusable discount that can be applied to invoices or subscriptions.
Show child attributes
Was this page helpful?