Voucher Creation
Promotion Campaign is usually used to encourage customer's purchase intention. Customers can obtain vouchers via these methods:
- Collect voucher
- Exchange voucher with a currency
- Buy voucher
- Play game to receive voucher
The instructions below show how you can integrate with MoMo to distribute your vouchers band how API Configurations operate.
Process Flow
API Configurations
Create a campaign
Partner uses this API to create a voucher on MoMo.
HTTP RequestPOST /v1/merchants/{partnerId}/campaigns
Variable | Type | Description |
---|---|---|
partnerId | String | ID of Merchant on MoMo |
Parameter description
Property | Type | Required | Description |
---|---|---|---|
requestType | String | Values: DCORP | |
id | String | ID of the promotion campaign on Partner | |
name | String | Name of the campaign | |
description | String | Description of the campaign | |
logoURL | String | URL to campaign’s logo. Size: 80x80 pixel. | |
bannerURL | String | URL to campaign’s banner. Size: 375x210 pixel. | |
startAt | Long | Define when the campaign comes to effect in UNIX timestamp. | |
endAt | Long | Define when the campaign ends in UNIX timestamp. | |
promoScheme | Enum | Voucher type: DISCOUNT_ON_TOTAL_BILL: Discount on the bill amount BUY_X_GET_Y: Buy something and get something free DISCOUNT_ON_ITEMS_IN_BILL: Discount on some items in bill SAME_PRICE_DISCOUNT: All items has same price | |
discountType | Enum | (*) | Discount type: VALUE: Discount on fixed amount PERCENTAGE: Discount by percentage |
discountValue | Long | (*) | Discount percentage. discountValue must be a multiple of 5, example: 10%, 15%, 50%, 75%,... discountValue > 0.05 (5%) When discountType = PERCENTAGE: discountValue must be less than or equal to 1. (*) Required when promoScheme = DISCOUNT_ON_TOTAL_BILL, DISCOUNT_ON_ITEMS_IN_BILL |
maxDiscountAmount | Long | (*) | Max discount amount. maxDiscountAmount >= 5000 When discountType = PERCENTAGE: maxDiscountAmount > discountValue x minBillValue. (*) Required when promoScheme = DISCOUNT_ON_TOTAL_BILL, DISCOUNT_ON_ITEMS_IN_BILL |
voucherCount | Integer | The number of vouchers will be issued. | |
billTimes | Array of object | Define the condition when a bill is eligible to apply the voucher. Described below. | |
minBillValue | Long | Minimum order amount that the voucher could be applied. | |
minOrderItemsCount | Long | (*) | Minimum number of items required in the order that the voucher could be applied. (*) Required when promoScheme = BUY_X_GET_Y |
eligibleStores | Array of object | Eligible stores (on the Partner's system) that the voucher can be applied. | |
eligibleMenuItems | Array of object | Eligible menu items that the voucher could be applied, for example: Matcha Milk-tea, Watermelon juice... Detail is described below. | |
eligibleMenuItemTypes | Array of object | Eligible menu items that the voucher could be applied, for example: category Coffee, Milk-tea,... Detail is described below. | |
maxGiftItemsCount | Long | (*) | The maximum item count could be applied to the voucher. (*) Required when promoScheme = BUY_X_GET_Y, SAME_PRICE_DISCOUNT |
giftItems | Array of object | Define offered items to user when applying a voucher, for example: Matcha Milk-tea, Watermelon juice... (*) Required when promoScheme = BUY_X_GET_Y | |
giftItemTypes | Array of object | Define types of items offered to user when applying a voucher, for example: category Coffee, Milk-tea,... (*) Required when promoScheme = BUY_X_GET_Y | |
giftItemMechanism | String | (*) | Mechanism for gift items: NONE: Default. The first ordered items are gifted. ASCENDI NG: Items with the lowest price are gifted. DESCENDING: Items with the highest price are gifted. (*) Required when promoScheme = BUY_X_GET_Y |
parityPrice | Long | (*) | Price of item when applying a voucher. (*) Required when promoScheme = SAME_PRICE_DISCOUNT |
Details of billTimes
Property | Type | Required | Default | Description |
---|---|---|---|---|
daysOfWeek | Array of integer | [2, 3, 4, 5, 6, 7, 8] | Days of week that the voucher could be applied: Monday: 2 Tuesday: 3 Wednesday: 4 Thursday: 5 Friday: 6 Saturday: 7 Sunday: 8 | |
timeFrom | String | 00:00:00 | Define the start time that the voucher could be applied. Format: hh24:mm:ss | |
timeTo | String | 23:59:59 | Define the end time that the voucher could be applied. Format: hh24:mm:ss |
Details of eligibleStores
Property | Type | Required | Description |
---|---|---|---|
storeId | String | ID of store at Partner side, it is used to link with store on MoMo system |
Details of eligibleMenuItems
Property | Type | Required | Description |
---|---|---|---|
id | String | Item id at Partner side | |
name | String | Item name at Patner side | |
originalPrice | Double | The original price before discount of the item, used to show attractive information to users. | |
discountPrice | Double | The price after applying discount |
Details of eligibleMenuItemTypes
Property | Type | Required | Description |
---|---|---|---|
id | String | Item type id at Partner side | |
name | String | Item type name at Patner side |
Describe how promoScheme
& discountType
& discountValue
& maxDiscountAmount
correlated to the final discount amount of a bill
- When
promoScheme
= DISCOUNT_ON_TOTAL_BILL,discountType
= VALUE,discountValue
= 10000, the bill got discount an amount of 10000 but not exceeds maxDiscountAmount (if defined) - The bill amount is 100000. When:
promoScheme
= DISCOUNT_ON_TOTAL_BILL,discountType
= PERCENTAGE,discountValue
= 0.3,maxDiscountAmount
= 15000, the bill got discount an amount of 15000 which is the minimum value of (0.3*100000) andmaxDiscountAmount
Example of Scheme Discount on total bill
{
"requestType": "DCORP",
"id": "GIAM30KT062023",
"name": "Giảm 10% hoá đơn tối đa 30K đơn từ 75k tháng 6-2023",
"description": "Giảm 10% hoá đơn tối đa 30K đơn từ 75k tháng 6-2023",
"logoURL": "https://...",
"bannerURL": "https://...",
"startAt": 1693526400000,
"endAt": 1696118399000,
"promoScheme": "DISCOUNT_ON_TOTAL_BILL",
"discountType": "PERCENTAGE",
"discountValue": 0.1,
"maxDiscountAmount": 30000,
"voucherCount": 1000,
"billTimes": [
{
"daysOfWeek": [2, 3, 4],
"timeFrom": "00:00:00",
"timeTo": "23:59:59"
},
{
"daysOfWeek": [5, 6, 7, 8],
"timeFrom": "00:00:00",
"timeTo": "12:00:00"
}
],
"minBillValue": 75000,
"minOrderItemsCount": 1,
"eligibleStores": [
{
"storeId": "store id at Partner side"
}
],
"eligibleMenuItems": [
{
"id": "item id at partner side",
"name": "item name at partner side",
"originalPrice": 50000
}
],
"eligibleMenuItemTypes": [
{
"id": "item type id at partner side",
"name": "item type name at partner side"
}
]
}
Example of Scheme Buy X Get Y
{
"requestType": "DCORP",
"id": "TANGTRANCHAUT062023",
"name": "Mua trà sữa size L bất kỳ tặng trân châu tháng 6-2023",
"description": "Mua trà sữa size L bất kỳ tặng trân châu tháng 6-2023",
"logoURL": "https://...",
"bannerURL": "https://...",
"startAt": 1693526400000,
"endAt": 1696118399000,
"promoScheme": "BUY_X_GET_Y",
"voucherCount": 1000,
"minOrderItemsCount": 1,
"maxGiftItemsCount": 10,
"billTimes": [
{
"daysOfWeek": [2, 3, 4, 5, 6, 7, 8],
"timeFrom": "00:00:00",
"timeTo": "23:59:59"
}
],
"eligibleStores": [
{
"storeId": "store id at Partner side"
}
],
"eligibleMenuItems": [
{
"id": "trasua01",
"name": "Trà sữa Trân Châu Hoàng Kim size L",
"originalPrice": 50000
}
],
"giftItems": [
{
"id": "tranchau01",
"name": "Trân Châu Trắng",
"originalPrice": 10000
}
]
}
Example of Scheme Discount on items in bill
{
"requestType": "DCORP",
"id": "asdasd2134353asdsad5",
"name": "Giảm 10% tối đa 30K cho món trà sữa trân châu",
"description": "Giảm 10% tối đa 30K cho món trà sữa trân châu",
"logoURL": "https://...",
"bannerURL": "https://...",
"startAt": 1699599288000,
"endAt": 1699685688000,
"promoScheme": "DISCOUNT_ON_ITEMS_IN_BILL",
"discountType": "PERCENTAGE",
"discountValue": 0.1,
"voucherCount": 1000,
"maxDiscountAmount": 30000,
"billTimes": [
{
"daysOfWeek": [
2,
3,
4
],
"timeFrom": "00:00:00",
"timeTo": "23:59:59"
},
{
"daysOfWeek": [
5,
6,
7,
8
],
"timeFrom": "00:00:00",
"timeTo": "12:00:00"
}
],
"minBillValue": 75000,
"eligibleStores": [
{
"storeId": "store id at Partner side"
}
],
"eligibleMenuItems": [
{
"id": "item id at partner side",
"name": "item name at partner side",
"originalPrice": 50000
}
],
"eligibleMenuItemTypes": [
{
"id": "item type id at partner side",
"name": "item type name at partner side"
}
],
"minGiftItemsCount": 10,
"giftItems": [
{
"id": "item id at partner side",
"name": "item name at partner side",
"originalPrice": 50000
}
],
"giftItemTypes": [
{
"id": "item type id at partner side",
"name": "item type name at partner side"
}
]
}
Example of Scheme Same Price discount
{
"requestType": "DCORP",
"id": "asdasd2134353asdsad5asd",
"name": "Đồng giá 30K cho món trà sữa trân châu",
"description": "Đồng giá 30K cho món trà sữa trân châu",
"logoURL": "https://...",
"bannerURL": "https://...",
"startAt": 1699599288000,
"endAt": 1699685688000,
"promoScheme": "SAME_PRICE_DISCOUNT",
"voucherCount": 1000,
"billTimes": [
{
"daysOfWeek": [
2,
3,
4
],
"timeFrom": "00:00:00",
"timeTo": "23:59:59"
},
{
"daysOfWeek": [
5,
6,
7,
8
],
"timeFrom": "00:00:00",
"timeTo": "12:00:00"
}
],
"minBillValue": 75000,
"eligibleStores": [
{
"storeId": "store id at Partner side"
}
],
"eligibleMenuItems": [
{
"id": "item id at partner side",
"name": "item name at partner side",
"originalPrice": 50000
}
],
"eligibleMenuItemTypes": [
{
"id": "item type id at partner side",
"name": "item type name at partner side"
}
],
"maxGiftItemsCount": 10,
"parityPrice": 30000
}
HTTP Response
Property | Type | Description |
---|---|---|
status | String | See convention for common status code |
message | String | The description of the above status code |
data | Object | Described below |
formErrors | Object | Described below. This property is set on status = FAIL and http status code is 400 |
Details of data
Model
Property | Type | Description |
---|---|---|
campaignId | String | Campaign id at MoMo |
id | String | Received id in the request |
status | Enum | Campaign status at MoMo, default WAITING_FOR_APPROVAL. Check the section Campaign Description for more detail. |
errorMessage | String | Error description if any |
Details of FormErrors Model
Property | Type | Description |
---|---|---|
[each property in request body] | Array of string | Error message |
Example of a Successful Request
{
"status": "SUCCESS",
"message": "Thành công",
"data": {
"campaignId": "voucher id at MoMo side",
"id": "GIAM30KT062023",
"status": "WAITING_FOR_APPROVAL"
}
}
Example of a Bad Request
{
"status": "FAIL",
"message": "Thất bại",
"formErrors": {
"name": [
"Tên voucher vượt quá 100 ký tự"
],
"discountValue": [
"Giá trị không hợp lệ"
],
"billTimes": [
{
"daysOfWeek": [
"Giá trị không hợp lệ"
],
"timeFrom": [
"Thời gian sai định dạng"
]
}
],
}
}
Import voucher codes of a campaign
Merchant uses this API to specify voucher codes in a campaign that MoMo will distribute to users. This API accepts a text file. Describe the input file:
- A text file in csv format with no header and encoding UTF8.
- Each line in the file defines a voucher code, only in column A of the first sheet, without any header or any information.
- Code data is without any formulas, no duplicated codes in 1 campaign and contains only English alphabet characters (from a to Z, case-sensitive) and numeric characters (from 0 to 9).
- The maximum length of each voucher code is 20 characters and minimum 1 character.
- Max file size is 5MB and limited to 100.000 codes per file.
HTTP Request
POST /v1/merchants/{partnerId}/campaigns/{momoCampaignId}/voucher-codes/by-file
Variable | Type | Description |
---|---|---|
partnerId | String | ID of Merchant on MoMo |
momoCampaignId | String | ID of the promotion campaign on MoMo |
Parameter description
Property | Type | Required | Description |
---|---|---|---|
Content-Type | String | text/csv |
Request Body: file binary
Example of a Request
curl --location '<MoMoHost>/v1/merchants/{partnerId}/campaigns/{momoCampaignId}/voucher-codes/by-file' \
--header 'Content-Type: text/csv' \
--data '@/data/voucher_codes.csv'
HTTP Response
Property | Type | Description |
---|---|---|
status | String | Status of Importing Codes. Check section of Result Codes & Messages |
message | String | See convention |
data | Object | Described below |
Details of data
Model
Property | Type | Description |
---|---|---|
campaignId | String | ID of the promotion campaign on MoMo |
wasConfirmed | Boolean | Whether MoMo accepts the file: - True: The received file looks good (format, size) and MoMo accepts it for further processing later. - False: There’s something wrong with the file and MoMo rejects it. |
Example of a Successful Response
{
"status": "SUCCESS",
"message": "Thành công",
"data": {
"campaignId": "GIAM30KT062023",
"wasConfirmed": true,
}
}
Get campaign detail
Partner uses this API to get a campaign detail that was created previously on MoMo.
HTTP RequestGET /v1/merchants/{partnerId}/campaigns/{momoCampaignId}
Variable | Type | Description |
---|---|---|
partnerId | String | ID of Merchant on MoMo |
momoCampaignId | String | ID of the promotion campaign on MoMo |
HTTP Response
Property | Type | Description |
---|---|---|
status | String | See convention |
message | String | See convention |
data | Object | Described below |
Details of data
Model
Property | Type | Description |
---|---|---|
id | String | ID of the promotion campaign on MoMo |
name | String | Name of the campaign |
description | String | Description of the campaign |
status | Enum | Campaign status |
logoURL | String | URL to campaign’s logo. |
bannerURL | String | URL to campaign’s banner |
startAt | Long | Define when the campaign comes to effect in UNIX timestamp. |
endAt | Long | Define when the campaign ends in UNIX timestamp. |
promoScheme | Enum | Voucher type: DISCOUNT_ON_TOTAL_BILL: Discount on the bill amount BUY_X_GET_Y: Buy something and get something free DISCOUNT_ON_ITEMS_IN_BILL: Discount on some items in bill SAME_PRICE_DISCOUNT: All items has same price |
discountType | Enum | Discount type: VALUE: Discount on fixed amount PERCENTAGE: Discount by percentage |
discountValue | Double | Discount percentage. When discountType = PERCENTAGE, discountValue must be less than or equal to 1. |
maxDiscountAmount | Double | Max discount amount. |
voucherCount | Integer | The number of vouchers will be issued. |
billTimes | Array of object | Define the condition when a bill is eligible to apply the voucher. Described below. |
minBillValue | Double | Minimum order amount that the voucher could be applied. |
minOrderItemsCount | Integer | Minimum number of items required in the order that the voucher could be applied. |
eligibleStores | Array of object | Eligible stores (on the Partner's system) that the voucher can be applied. |
eligibleMenuItems | Array of object | Eligible menu items that the voucher could be applied. Described below. |
eligibleMenuItemTypes | Array of object | Eligible menu item types that the voucher could be applied. Described below. |
minGiftItemCount | Integer | The maximum item count could be applied to the voucher. |
giftItems | Array of object | Define offered items to user when applying a voucher. |
giftItemTypes | Array of object | Define types of items offered to user when applying a voucher. |
Details of billTimes
Property | Type | Description |
---|---|---|
daysOfWeek | Array of integer | Days of week that the voucher could be applied: Monday: 2 Tuesday: 3 Wednesday: 4 Thursday: 5 Friday: 6 Saturday: 7 Sunday: 8 |
timeFrom | String | Define the start time that the voucher could be applied. Format: hh24:mm:ss |
timeTo | String | Define the end time that the voucher could be applied. Format: hh24:mm:ss |
Details of eligibleStores
Property | Type | Description |
---|---|---|
storeId | String | Store ID (on the Partner's system) |
storeName | String | Store name |
momoStoreId | String | Store ID (on MoMo's system) |
oaId | String | ID of MoMo's Official Account of your eligible stores |
Details of eligibleMenuItems
Property | Type | Description |
---|---|---|
id | String | Item id at Partner side |
name | String | Item name at Patner side |
originalPrice | Double | The original price before discount of the item, used to show attractive information to users. |
Details of eligibleMenuItemTypes
Property | Type | Description |
---|---|---|
id | String | Item type id at Partner side |
name | String | Item type name at Patner side |
Example response
{
"id": "GIAM30KT062023",
"name": "Giảm tối đa 30K đơn từ 75k tháng 6-2023",
"description": "Giảm tối đa 30K đơn từ 75k tháng 6-2023",
"logoURL": "https://...",
"bannerURL": "https://...",
"campaignId": "OPTIONAL campaignId",
"promoScheme": "DISCOUNT_ON_TOTAL_BILL",
"discountType": "VALUE",
"discountValue": 15000,
"voucherCount": 1000,
"billTime": [
{
"daysOfWeek": [2, 3, 4],
"timeFrom": "00:00:00",
"timeTo": "23:59:59"
},
{
"daysOfWeek": [5, 6, 7, 8],
"timeFrom": "00:00:00",
"timeTo": "12:00:00"
}
],
"minBillValue": 1000000,
"eligibleStores": [
{
"storeId": "store id at partner side",
"momoStoreId": "store id at MoMo side",
"oaId": "OA id at MoMo side",
}
],
"eligibleMenuItems": [
{
"id": "item id at partner side",
"name": "item name at partner side",
}
],
"eligibleMenuItemTypes": [
{
"id": "item type id at partner side",
"name": "item type name at partner side",
}
],
"giftItems": [
{
"id": "tranchau01",
"name": "Trân Châu Trắng",
"originalPrice": 10000
}
]
}
Get status of imported voucher codes
Merchant uses this API to determine whether voucher codes (that are pushed to MoMo using API described here) have been processed successfully or something went wrong.
HTTP Request
GET /v1/merchants/{partnerId}/campaigns/{momoCampaignId}/voucher-codes/status
Variable | Type | Description |
---|---|---|
partnerId | String | ID of Merchant on MoMo |
momoCampaignId | String | ID of the promotion campaign on MoMo |
HTTP Response
Property | Type | Description |
---|---|---|
status | String | Status of the request. Check section of Result Codes & Messages |
message | String | See convention |
data | Object | Described below |
Details of data
Model
Property | Type | Description |
---|---|---|
campaignId | String | ID of the promotion campaign on MoMo |
numberOfCodes | Integer | The number of codes in the input file that has been imported successfully into MoMo system. |
needToImportCodes | enum | Whether partner should send voucher codes to MoMo: - True: Partner should import voucher codes to MoMo using API described here. - False: Otherwise. |
importTime | Long | The last time MoMo received a file in milliseconds. |
Example response
{
"status": "SUCCESS",
"message": "Thành công",
"data": {
"campaignId": "GIAM30KT062023",
"numberOfCodes": 30000,
"needToImportCodes": false,
"importTime": 1713148723
}
}
Update status of a campaign
Partner uses this API to update status of a campaign that was created previously on MoMo.
HTTP RequestPOST /v1/merchants/{partnerId}/campaigns/{momoCampaignId}
Variable | Type | Description |
---|---|---|
partnerId | String | ID of Merchant on MoMo |
momoCampaignId | String | ID of the promotion campaign on MoMo |
Parameter description
Property | Type | Required | Description |
---|---|---|---|
status | Enum | Campaign status. Only allow this status: STOPPED |
Example request
{
"status": "STOPPED"
}
HTTP Response
Property | Type | Description |
---|---|---|
status | String | See convention |
message | String | See convention |
data | Object | Described below |
Details of data
Model
Property | Type | Description |
---|---|---|
campaignId | String | ID of the promotion campaign on MoMo |
status | Enum | Current campaign status: - STOPPED - DELETED |
Example of a Successful Request
{
"status": "SUCCESS",
"message": "Thành công",
"data": {
"campaignId": "GIAM30KT062023",
"status": "STOPPED"
}
}
Web hook to receive updates about campaign
MoMo notifies Partner updates related to the campaign's status via web hook that is provided by Partner.
HTTP RequestParameter descriptionPOST
<your endpoint, needed to register first with MoMo>
Property | Type | Description |
---|---|---|
requestId | String | UUID, unique for every request |
event | Enum | There’s just one value for now: STATE_CHANGE_MSG (means campaign’s status has updated) |
data | Object | Described below |
Details of data
Model
Property | Type | Optional | Description |
---|---|---|---|
campaignId | String | ID of the promotion campaign on MoMo | |
campaignState | Enum | Campaign status at MoMo, default WAITING_FOR_APPROVAL. Check the section Campaign Description for more detail. | |
operationType | Enum | Allowed actions can be made to the campaign: CREATE, APPROVE, REJECT, STOP, UPDATE. | |
operationMessage | String | Description of the event from MoMo | |
operationTime | Long | Epoch timestamp in milliseconds |
Example request
{
"requestId": "f215406f-e928-43fa-8639-68458fdaa3e7",
"event": "STATE_CHANGE_MSG",
"data": {
"campaignId": "238239582395",
"campaignState": "ACTIVE",
"operationType": "APPROVE",
"operationMessage": "Look good to me!!",
"operationTime": 1686705424000
}
}
HTTP Response
HTTP Status Code: 200
Parameter descriptionProperty | Type | Required | Description |
---|---|---|---|
campaignId | String | ID of the promotion campaign on MoMo | |
wasConfirmed | Boolean | Whether the request has been processed. True: The request has been processed. False: You received the request but has not processed it yet. | |
message | String | Some message about the request you want MoMo to know | |
errorCode | Integer | Your error code |
Result Codes and Messages
After submitting an API request, you'll receive a response inform that your request was received and processed. Depending on the HTTP status code of the response, please handle the corresponding logical actions:
2xx
: indicates a well received and processed request4xx
: you did something wrong in the request.5xx
: something's wrong with the server, or connection.
Other than HTTP status code, you'll also receive MoMo error codes and messages (in EN and VI) in the response. Each of them will carry out a distinguish result of your request, so please apply the logical handlers for them all.
Result code | Description | Type | Recommended actions |
---|---|---|---|
0 | Success. | ||
11 | Access denied. | System error | Merchant settings issue. Please check your settings in M4B portal, or contact MoMo for configurations. |
13 | Merchant authentication failed. | Merchant error | Please check your credentials and the ones provided in M4B portal. |
010001 | Duplicated request. | System error | Duplicated request. |
010002 | The request is being processed. | System error | The request is being processed. |
100001 | Please do not leave request ID blank. | Merchant error | Please retry with another request ID. |
100002 | Campaign type does not exist. | Merchant error | Please retry with the campaign type defined in the documentation. |
100003 | Invalid logo URL. | Merchant error | Please do not leave logo blank. |
100004 | Invalid banner URL. | Merchant error | Please do not leave banner blank. |
100005 | Total voucher issued is less than 0 or greater than 100.000. | Merchant error | Total voucher issue should be in range [1 - 100.000]. |
101001 | Voucher type does not exist. | Merchant error | Please retry with the voucher type defined in the documentation. |
101002 | Discount value is less than 0 or greater than > 1 → Wrong format. | Merchant error | discountValue should be greater than 0 and less than or equal to 1. |
101003 | Max discount amount is less than 0 → Wrong format. | Merchant error | maxDiscountAmount should be greater than 0. |
101004 | Same price amount is less than 0 → Wrong format. | No | parityPrice should be greater than 0. |
101005 | Quantity of discount items is less than 0 → Wrong format. | Merchant error | Quantity of discount items should be greater than 0. |
101006 | Mechanism for gift items does not exist (only for voucher type BUY_X_GET_Y). | Merchant error | giftItemMechanism does not exist. |
101007 | Both offered items and offered item types do not have values. | Merchant error | There should be at least either discount items or discount item types. |
101008 | ID of offered items are empty. | Merchant error | Item ID of discount items should not be empty. |
101009 | Name of offered items are empty. | Merchant error | Item name of discount items should not be empty. |
101010 | ID of offered item types are empty. | Merchant error | Item Type ID of discount items should not be empty. |
101011 | Name of offered item types are empty. | Merchant error | Item Type Name of discount items should not be empty. |
102001 | Campaign start time is less than current timestamp | Merchant error | Campaign start time should be greater than current time. |
102002 | Campaign end time is less than current timestamp | Merchant error | Campaign end time should be greater than current time. |
102003 | Day of week is less than 1 and greater than 7 → Wrong format. | Merchant error | daysOfWeek should be in range [1,7]. |
102004 | timeFrom is in wrong format hh:mm:ss. Correct format: 0 <= hh < 24. 0 <= mm < 60. 0 <= ss < 60. | Merchant error | timeFrom should follow the format hh:mm:ss. |
102005 | timeTo is in wrong format hh:mm:ss. Correct format: 0 <= hh < 24. 0 <= mm < 60. 0 <= ss < 60. | Merchant error | timeTo should follow the format hh:mm:ss. |
103001 | The minimum bill valiue is less than 0. | Merchant error | minBillValue should be greater than or equal to 0. |
103002 | Minimum items count required in the order is less than 0 (only for voucher type BUY_X_GET_Y). | Merchant error | minOrderItemsCount should be greater than 0. |
103003 | Both eligible items and eligible item types do not have values (only for voucher type BUY_X_GET_Y, SAME_PRICE_DISCOUNT). | Merchant error | There should be at least either eligible items or eligible item types. |
103004 | storeId of eligibleStores does not have values. | Merchant error | storeId of the eligibleStores should not be empty. |
103005 | ID of eligible items are empty. | Merchant error | |
Item ID of eligible items should not be empty. | |||
103006 | Name of eligible items are empty. | Merchant error | Item name of eligible items should not be empty. |
103007 | ID of eligible item types are empty. | Merchant error | Item Type ID of eligible items should not be empty. |
103008 | Name of eligible item types are empty. | Merchant error | Item Type Name of eligible items should not be empty. |
110001 | Master Merchant who requested to update campaign is not the Master Merchant creating the campaign. | Merchant error | You don't have permission to take this action on the campaign that belongs to others. |
110002 | Campaign is not in the state of updating status (including: Rejected, Error, Terminated, Completed, Archived) | Merchant error | This campaign is not in the state of updating status. |
200001 | The number of unique codes in the received file does not match the voucher count defined in the campaign | Merchant error | Please import the same amount of codes with campaign. |
200002 | There’s invalid voucher code format in the file. | Merchant error | Description: Codes should be a combination of uppercase, lowercase letters and numbers, and less than or equal to 20 characters. Codes should not contain any symbols or special letters. {Number_of_lines}} are in wrong format. These are three of them: {{list the first 3 lines}}. Example: Codes should be a combination of uppercase, lowercase letters and numbers, and less than or equal to 20 characters. Codes should not contain any symbols or special letters. 33 lines are in wrong format. These are three of them: 2, 5, 10. |
200003 | There are duplicated voucher codes in the file. | Merchant error | Description: File should not contain duplicated codes. {{Number_of_lines}} lines contain duplicated codes. These are three of them: {{list the first 3 lines}} Example: File should not contain duplicated codes. 10 lines contain duplicated codes. These are three of them: 2, 5, 10. |
210001 | Duplicated file codes with the same campaignId. | Merchant error | This campaign has already imported codes. This request is rejected. |
210002 | Campaign ID does not exist. | Merchant error | Campaign ID does not exist. |
210003 | Campaign is not in the state of importing codes (including: Scheduled, Active, Stopped, Rejected, Error, Terminated, Completed, Archived) | Merchant error | This campaign is not in the state of importing codes. |
210004 | The imported file’s format is invalid. | Merchant error | Please import the csv file.. |
210005 | File size exceeded limitation | Merchant error | File should be not larger than 5MB. |
210006 | Master Merchant who requested to import codes is not the Master Merchant creating the campaign. | Merchant error | You don't have permission to take this action on the campaign that belongs to others. |