Create a Coupon

POST /user/coupons/

The POST /user/coupons/ endpoint allows users to create a new coupon.

Parameters

Field

Type

Description

data

Object (Body)

The data object containing the coupon details.

value

String (Decimal)

The value of the coupon. This is a required field.

expiration_date

String (Date-Time)

The expiration date of the coupon. This is a required field.

Responses

Code

Description

201

Coupon created successfully.

Example Response Body

{
  "id": 123,
  "code": "ABCD1234",
  "value": "50.00",
  "expiration_date": "2024-12-31T23:59:59Z"
}

Last updated