Estimate Points to Earn
URL:
Method: POST
https://saasapi.igainapp.in/v1/order.php/pointsestimate
Request Parameters
| Parameter | Type | Position | # | Description |
|---|---|---|---|---|
| Authorization | string |
Header |
Required |
Authorization is the Enrypted Company API KEY |
| membershipid | string |
Body |
Required |
Membership ID / Mobile No. |
| outletno | integer |
Body |
Required |
Outlet ID |
| orderno | integer |
Body |
Required |
Order No. |
| orderamount | integer |
Body |
Required |
Order Amount |
| itemsdata | array |
Body |
Required |
Order Items Details |
| redeemdetails | array |
Body |
Required |
Redeem Points Details |
Sample Request Body
{
"membershipid":"40000000002",
"outletno":"21806",
"orderno":"10823",
"orderamount":"4200.00",
"itemsdata":[{"code":"flight-booking","quantity":"1","price": "600"},
{"code":"hotel-booking","quantity":"1","price": "600"},
{"code":"meet-n-greet","quantity":"1","price": "600"},
{"code":"lounge","quantity":"1","price": "600"},
{"code":"in-dest-experience","quantity":"1","price": "600"},
{"code":"fast-track","quantity":"1","price": "600"},
{"code":"baggage-insurance","quantity":"1","price": "600"}],
"redeemdetails":{"points":"0","amount":"0"}
}
Sample Request Response
{
"errorcode":1001,
"message":"Successful",
"membershipid":"40000000002",
"membername":"Amit Kamble",
"orderno":"10823",
"orderamount":"4,200.00",
"pointsamount":"0.00",
"balancedue":"4,200.00",
"pointstogained":53,
"firstorderpoints":53,
"bdaypoints":53,
"currentbalance":0
}
Error Codes
| Error Code | Description |
|---|---|
| 3121 | Required field(s) is missing or empty |
| 3103 | Invalid item code Or Item not exist |
| 3101 | Insufficient current balance |
| 2066 | Equivalent redeem amount / discount amount is more than order amount |
| 2009 | Invalid outlet no. |
| 2003 | Invalid or unable to locate membership id |
| 1002 | Order amount doesn't match with items price |
| 1001 | Successful |