v1

latestOpenAPI 3.0.22026-07-2645239950.4 KB

post/transactions/redeem

Request body

member_idstring required

Unique Identifier (Member ID) for the member object in the client’s system which was used while creating a member in Zinrelo.

reward_idstring required

Unique ID that identifies a reward in Zinrelo. This is the ID of the reward against which the redemption transaction has to be recorded.

transaction_attributesstring json
<p>Every activity has a two predefined transaction attributes - reason and tags. While redeeming points for an activity, data can be passed in these attributes.</strong></p> <p>For example:</p> <p><code class="c-mrkdwn__code" data-stringify-type="code">{</code><br /><code class="c-mrkdwn__code" data-stringify-type="code">"reason" : "redeem", </code><br /><code class="c-mrkdwn__code" data-stringify-type="code">"tags" : ["purchasenmade","redeemingpoints"]</code><br /><code class="c-mrkdwn__code" data-stringify-type="code">} </code></p> <p>Custom attributes: In addition to the predefined attributes, you can define custom attributes for each activity and pass data in those attributes.&nbsp;</p> <p>The custom attribute should be created in advance. To create custom attributes for your store, reach out to your account manager at support@zinrelo.com.</p>
points_to_be_redeemedinteger

REQUIRED: only for flexible redemption. The number of points to be redeemed.

statusstring

Pass the redemption status—approved or pending. If no entry is passed, the transaction will be redeemed, and its status will be approved.

Example request

{
  "member_id": "john.doe@gmail.com",
  "reward_id": "reward_bc668",
  "status": "pending"
}

Response

200

successboolean

Example response

{
  "data": {
    "status": "pending",
    "transaction_attributes": {
      "reason": "redeem",
      "source_of_redemption": "api",
      "tags": [
        "purchasenmade",
        "redeemingpoints"
      ]
    },
    "last_modified_date": "22-Mar-2023 05:54:11",
    "additional_data": {
      "points_to_be_redeemed": 1400
    },
    "approver_details": {
      "approver_name": "System"
    },
    "approved_date": "22-Mar-2023 05:54:11",
    "reward_info": {
      "reward_name": "&#36;15 OFF COUPON",
      "points_status": "redemption_pending",
      "coupon_code": "81c0bd3b",
      "reward_id": "reward_9c350",
      "points": 1400
    },
    "member_id": "5779678689",
    "created_date": "22-Mar-2023 05:54:11",
    "transaction_type": "redeem",
    "id": "641a9804c2161f000ee6e469"
  },
  "success": true
}