Android


6. Promotion Posting Basic

This promotion postingbasic is done by calling Goodie.setPromotionPostingBasic() function.

Here is example:

Goodie. setPromotionPostingBasic(authToken, deviceUniqueId, memberId,
        merchantId, storeId, productCode, refNumber, totalTrxAmount)

        .promotionInquiryBasicGoodie(this, new SetPromotionInquiryBasicListener() {

            @Override

            public void onSuccess(PromoInqBasicResponse res){

        if(res.getAbstractResponse().getResponseStatus().equals("INQ000")){

            //on success

                }

            }

            @Override
            public void onError(Throwable throwable) {
                //on error
                }
            });
                    

Where :
Param Type Description
authToken String authToken is used as for header authentication purpose
deviceUniqueId String deviceUniqueId is identify android device
memberId String memberId is identifier that will be used to identity a member
merchantId String merchantId is identifier that will be used to identity a merchant
storeId String storeId is identifier that will be used to identity a store
productCode String productCode is identifier that will be used to identity a product
refNumber String refNumber is
totalTrxAmount Integer totalTrxAmount is total transaction amount

Response promotion posting basic :
{
    "memberId": "8A2EC944-3E83-4D9F-9E0C-D47CEBF5C20C",
    "merchantId": "5F773EA1-1E66-4F9E-B9C8-E1FA8156AD20",
    "memberName": "hana susan",
    "storeId": "",
    "transactionDate": "2019-04-02",
    "transactionId": "",
    "totalPointIssuing": 200,
    "promotionNumberIssued": [
    {
        "promotionCode": "PRM32019001",
        "promotionName": "Promo2019",
        "basicRuleName": "General Transaction",
        "basicRulePoint": 200,
        "customRulePoints": []
    }
    ],
        "abstractResponse": {
        "responseStatus": "INQ000",
        "responseMessage": "Inquiry success"
    }
}