Issue user reward

This API is used to issue a reward to the user based on mobile number/ email ID/ external ID

👍

Note

For detailed information about our APIs and for hands-on testing, refer documentation in API overview and step-by-step guide on making your first API call in Make your first API call .

Prerequisites

  • Basic Authentication
  • Default access group

Resource information

URI/api_gateway/rewards/core/v1/user/reward/{reward Id}/issue?username={store}&skip_validation=true
HTTP MethodPOST
PaginationNo
Batch supportNo
Rate limit informationNone

API endpoint example

https://eucrm.cc.capillarytech.com/api_gateway/rewards/core/v1/user/reward/{reward Id}/issue?username={store}&skip_validation=true

Request path parameters

Parameter NameData TypeDescription
Reward ID*StringUnique identifier of the reward.

Request query parameters

Parameter NameData TypeDescription
username*StringName of the store.
skip_validationBooleanA validation code is used to redeem points for the transaction. skip_validation is set to true as brands configured in Marvel bypass validation code.

Request body parameters

ParameterData TypeDescription
mobileStringThe mobile phone number associated with the transaction.
Email*StringThe email ID of the customer.
External ID*StringThe external ID of the customer.
brandStringBrand identifier, possibly indicating the company or product line.
transactionNumberStringUnique identifier for the transaction.
notesStringAdditional notes or comments related to the transaction.
rewardOwnershipROObjectOwner validation for issuance of rewards only when the owner's details are provided.
ownerTypeEnumModule for which the reward was created. Supported values: Loyalty program, Milestones, Campaigns, Journeys, Goodwill.
ownerIdStringUnique identifier of the owner to claim the reward. Ex:12345678
rewardsArrayA list of rewards associated with the transaction.
-rewardIdIntegerThe unique identifier of a specific reward.
-quantityIntegerThe quantity of the specific reward issued.
-paymentConfigObjectPayment configuration details for the reward.
--idIntegerUnique identifier for the payment configuration.
--paymentModeEnumThe type of payment mode supported to redeem the reward. Supported values: POINTS, FREE, CASH, POINTS_CASH,CONV_RATIO.

For more information, refer to Supported payment modes.
tenderObjectThe tender details contain the customer transaction details. For example, if the customer has opted for a CASH+POINTS payment mode and uses the card to pay for the reward, then the card information is captured here.
totalAmountIntegerThe total amount the customer is required to pay to purchase the reward.
methodOfPaymentEnumThe method the customer uses to pay for the reward.
methodOfPaymentIdStringYou can enter the identifier for the payment method.
tenderIdIntegerEnter a unique identifier for the tender.
amountIntegerThe amount paid from the payment mode.

{
  "mobile": "919456430850",
  "brand": "BUKL",
  "transactionNumber": "23444",
  "notes": "test"
}
{
  "externalId": "919456430850",
  "brand": "BUKL",
  "transactionNumber": "01987"
}
{
  "emailId": "[email protected]",
  "brand": "BUKL",
  "transactionNumber": "23444",
  "notes": "test"
}
{
    "mobile": "917411982768",
    "brand": "SAHANA_TEST",
    "rewardOwnershipRO": {
        "ownerType": "CAMPAIGNS",
        "ownerId": "abc7"
    }
}
{
    "mobile": "919825752814",
    "brand": "testOrg_marvel_20230822_147",
    "transactionNumber": "2344s4",
    "notes": "This is test",
    "rewards": [
        {
            "rewardId": 56037,
            "quantity": 1,
            "paymentConfig": {
                "id": 18,
                "paymentMode":"CONV_RATIO",
                "points":400
            }
        }
    ],
    "tender":{
        "totalAmount":100,
        "tenders":[
            {
                "methodOfPayment":"CARD",
                "methodOfPaymentId":"HDFC",
                "tenderId":"123",
                "amount":40
            },
            {
                "methodOfPayment":"CARD",
                "methodOfPaymentId":"ICICI",
                "tenderId":"123456",
                "amount":60
            }
        ]
    }
}

Response parameters

ParameterData TypeDescription
successBooleanIndicates if the request was successful
codeIntegerHTTP status code of the response
messageStringDescription of the response status
pointsRedeemedStringNumber of points redeemed
couponCodeStringThe coupon code issued
codeExpiryStringExpiry date and time of the coupon
promotionStringInformation about the promotion
vendorStringInformation about the vendor

{
   "status": {
       "success": true,
       "code": 200,
       "message": "Reward issued successfully"
   },
   "intouch": {
       "pointsRedeemed": "50",
       "couponCode": "T4NLN0ZV",
       "codeExpiry": "2023-06-09 00:00:00"
   },
   "promotion": null,
   "vendor": null
}


API-specific error codes

Error codeDescription
8003fail to issue reward as Reward is disabled or not started yet or expired
3004Brand not found
8004fail to issue reward as points are not redeemable
12005Reward constraint evaluation failed. Request failed. Max limit for the DAYS is reached. Allowed limit is 15 For Level CUSTOMER
Language
Authorization
Basic
base64
:
URL
Click Try It! to start a request and see the response here!