v1

latestOpenAPI 3.0.3raw.githubusercontent.com2024-10-2916802.4 MB
🛒 Ecommerce

Get coupon by id

The API endpoint allows a logged-in user to retrieve a coupon by providing the couponId as a path variable.

By making a request to the API with the appropriate couponId, the server will return the corresponding coupon details, such as its code, discount amount, expiration date, or any other relevant information associated with that specific coupon.

get/ecommerce/coupons/{couponId}

Response

Get coupon by id

messagestring
statusCodenumber
successboolean

Example response

{
  "data": {
    "_id": "649e792a64e7dba29b7266ae",
    "couponCode": "IPSAM813",
    "createdAt": "2023-06-30T06:41:46.410Z",
    "discountValue": 813,
    "expiryDate": "2025-07-06T05:37:19.370Z",
    "isActive": true,
    "minimumCartValue": 1113,
    "name": "excepturi",
    "owner": "649e792964e7dba29b72634a",
    "startDate": "2022-10-29T15:51:08.574Z",
    "type": "FLAT",
    "updatedAt": "2023-06-30T06:41:46.410Z"
  },
  "message": "Coupon deleted successfully",
  "statusCode": 200,
  "success": true
}