Create ecommerce coupon
curl --request POST \
--url https://api.service.getjusto.com/v3/ecommerce/coupons \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"coupon": {
"name": "<string>",
"description": "<string>",
"active": true,
"code": "<string>",
"percentageOff": 123,
"maxPercentageOffDiscount": 123,
"discountAmount": 123,
"fixedAmount": 123,
"fromDate": "2020-01-01T00:00:00.000Z",
"endDate": "2020-01-01T00:00:00.000Z",
"maxRedemptions": 123,
"maxRedemptionsPerUser": 123,
"maxRedemptionsPerUserPerDay": true,
"maxRedemptionsPerCode": 123,
"onlyForNewUsers": true,
"onlyForProductsWithoutDiscount": true,
"requirePhoneVerification": true,
"requiresCategoriesIds": [
"<string>"
],
"requiresProductsIds": [
"<string>"
],
"requiresStoresIds": [
"<string>"
],
"requiresMenusIds": [
"<string>"
],
"requiresPaymentTypes": [
"<string>"
],
"requireChannels": [
"<string>"
],
"requiredBINs": [
"<string>"
],
"minimumOrderPrice": 123,
"maximumOrderPrice": 123,
"dontApplyToProductsIds": [
"<string>"
],
"dontApplyDiscountToOptions": true,
"isHidden": true,
"allowedEmails": [
"<string>"
],
"externalId": "<string>",
"isBirthdayCoupon": true,
"onlyRedeemOnBirthday": true,
"autoRecommend": true,
"applyDeliveryDiscount": true,
"deliveryDiscountValue": 123,
"deliveryDiscountType": "<string>",
"deliveryDiscountPercentage": 123,
"maxProductsPerOrder": 123
}
}
'{
"success": true,
"data": {
"_id": "<string>",
"websiteId": "<string>",
"code": "<string>",
"name": "<string>",
"description": "<string>",
"active": true,
"percentageOff": 123,
"maxPercentageOffDiscount": 123,
"discountAmount": 123,
"fixedAmount": 123,
"fromDate": "2020-01-01T00:00:00.000Z",
"endDate": "2020-01-01T00:00:00.000Z",
"maxRedemptions": 123,
"maxRedemptionsPerUser": 123,
"maxRedemptionsPerUserPerDay": true,
"maxRedemptionsPerCode": 123,
"totalRedemptions": 123,
"onlyForNewUsers": true,
"onlyForProductsWithoutDiscount": true,
"requirePhoneVerification": true,
"requiresCategoriesIds": [
"<string>"
],
"requiresProductsIds": [
"<string>"
],
"requiresStoresIds": [
"<string>"
],
"requiresMenusIds": [
"<string>"
],
"requiresPaymentTypes": [
"<string>"
],
"requireChannels": [
"<string>"
],
"requiredBINs": [
"<string>"
],
"minimumOrderPrice": 123,
"maximumOrderPrice": 123,
"dontApplyToProductsIds": [
"<string>"
],
"dontApplyDiscountToOptions": true,
"isHidden": true,
"allowedEmails": [
"<string>"
],
"externalId": "<string>",
"isBirthdayCoupon": true,
"onlyRedeemOnBirthday": true,
"autoRecommend": true,
"applyDeliveryDiscount": true,
"deliveryDiscountValue": 123,
"deliveryDiscountType": "<string>",
"deliveryDiscountPercentage": 123,
"maxProductsPerOrder": 123,
"createdAt": "2020-01-01T00:00:00.000Z",
"deletedAt": "2020-01-01T00:00:00.000Z"
}
}Cupones
Create ecommerce coupon
Crea un cupón ecommerce para la marca autorizada. Si se envía code, se crea también un primer código asociado.
POST
/
ecommerce
/
coupons
Create ecommerce coupon
curl --request POST \
--url https://api.service.getjusto.com/v3/ecommerce/coupons \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"coupon": {
"name": "<string>",
"description": "<string>",
"active": true,
"code": "<string>",
"percentageOff": 123,
"maxPercentageOffDiscount": 123,
"discountAmount": 123,
"fixedAmount": 123,
"fromDate": "2020-01-01T00:00:00.000Z",
"endDate": "2020-01-01T00:00:00.000Z",
"maxRedemptions": 123,
"maxRedemptionsPerUser": 123,
"maxRedemptionsPerUserPerDay": true,
"maxRedemptionsPerCode": 123,
"onlyForNewUsers": true,
"onlyForProductsWithoutDiscount": true,
"requirePhoneVerification": true,
"requiresCategoriesIds": [
"<string>"
],
"requiresProductsIds": [
"<string>"
],
"requiresStoresIds": [
"<string>"
],
"requiresMenusIds": [
"<string>"
],
"requiresPaymentTypes": [
"<string>"
],
"requireChannels": [
"<string>"
],
"requiredBINs": [
"<string>"
],
"minimumOrderPrice": 123,
"maximumOrderPrice": 123,
"dontApplyToProductsIds": [
"<string>"
],
"dontApplyDiscountToOptions": true,
"isHidden": true,
"allowedEmails": [
"<string>"
],
"externalId": "<string>",
"isBirthdayCoupon": true,
"onlyRedeemOnBirthday": true,
"autoRecommend": true,
"applyDeliveryDiscount": true,
"deliveryDiscountValue": 123,
"deliveryDiscountType": "<string>",
"deliveryDiscountPercentage": 123,
"maxProductsPerOrder": 123
}
}
'{
"success": true,
"data": {
"_id": "<string>",
"websiteId": "<string>",
"code": "<string>",
"name": "<string>",
"description": "<string>",
"active": true,
"percentageOff": 123,
"maxPercentageOffDiscount": 123,
"discountAmount": 123,
"fixedAmount": 123,
"fromDate": "2020-01-01T00:00:00.000Z",
"endDate": "2020-01-01T00:00:00.000Z",
"maxRedemptions": 123,
"maxRedemptionsPerUser": 123,
"maxRedemptionsPerUserPerDay": true,
"maxRedemptionsPerCode": 123,
"totalRedemptions": 123,
"onlyForNewUsers": true,
"onlyForProductsWithoutDiscount": true,
"requirePhoneVerification": true,
"requiresCategoriesIds": [
"<string>"
],
"requiresProductsIds": [
"<string>"
],
"requiresStoresIds": [
"<string>"
],
"requiresMenusIds": [
"<string>"
],
"requiresPaymentTypes": [
"<string>"
],
"requireChannels": [
"<string>"
],
"requiredBINs": [
"<string>"
],
"minimumOrderPrice": 123,
"maximumOrderPrice": 123,
"dontApplyToProductsIds": [
"<string>"
],
"dontApplyDiscountToOptions": true,
"isHidden": true,
"allowedEmails": [
"<string>"
],
"externalId": "<string>",
"isBirthdayCoupon": true,
"onlyRedeemOnBirthday": true,
"autoRecommend": true,
"applyDeliveryDiscount": true,
"deliveryDiscountValue": 123,
"deliveryDiscountType": "<string>",
"deliveryDiscountPercentage": 123,
"maxProductsPerOrder": 123,
"createdAt": "2020-01-01T00:00:00.000Z",
"deletedAt": "2020-01-01T00:00:00.000Z"
}
}Crea un cupón ecommerce para la marca autorizada. ElDocumentation Index
Fetch the complete documentation index at: https://docs.getjusto.com/llms.txt
Use this file to discover all available pages before exploring further.
websiteId se toma desde la autorización API, por lo que no debe enviarse en el body.
Puede crear un código inicial usando coupon.code. Para crear muchos códigos o asociarlos a emails, usa el endpoint de creación de códigos del cupón.Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Campos para crear o actualizar un cupón ecommerce.
Show child attributes
Show child attributes
⌘I