NICEPAY API
...
Payment API
API Payloan

Cancel - API Payloan

13min
about api payloan cancel this {{api}} uses to cancel a {{transaction}} that has been paid if {{the}} {{transaction}} cancels before {{the}} settlement {{process}} is complete, {{the}} {{transaction}} is considered void, and {{the}} {{transaction}} funds will return to {{the}} {{customer}} api payloan cancel the {{payloan}} cancel {{api}} uses for {{the}} cancel {{system}} for {{payment}} s via {{payloan}} api end point /nicepay/direct/v2/cancel request method post post header content type application/json merchant token sha256( timestamp + imid + txid + amt + merchantkey ) payment methods available for cancel code paymethod 01 {{cc}} 02 {{va}} 03 {{cvs}} 04 {{directdebit}} 05 {{ewallet}} 06 payloan payloan 08 {{qris}} 09 {{gpn}} request parameters for payloan cancel the following is a list of {{parameter}} s for requesting {{integration}} of {{the}} cancel {{payment}} {{process}} on {{the}} {{payloan}} {{paymethod}} these {{parameter}} s are used via {{the}} {{api}} {{testing}} platform parameter type size description example / notes timestamp required required n 14 {{api}} request timestamp 20221213141266 txid required required an 30 transaction id payloantes00202212131410560896 imid required required an 10 {{merchant}} id payloantes paymethod required required n 2 payment method code docid\ ek 0djw7nuhytcda4sa3p 06 canceltype required required n 2 cancel type code docid\ ly9czdrbjtw3rjv3l7r6v 1 cancelmsg an 255 cancel message request cancel merchanttoken required required an 255 {{merchant}} token 9d1835e8bf87b51b44de9b2455fa37e733a87b12644b9cd4546e2ec2de651863 amt required required n 12 {{paymentproduct}} amount 12000 canceluserid an 30 user id admin response parameter for payloan cancel following are {{the}} response {{parameter}} s from {{the}} results of {{the}} request {{parameter}} s for canceling {{payloan}} handling parameter type size description example/notes txid an 30 transaction id payloantes00202212131410560896 referenceno ans 40 {{merchant}} order number ord20200910170911 transdt n 8 transaction date 20221213 transtm n 6 transaction time 141056 amt n 12 amount 12000 resultcd n 4 result code docid 2r5sr3xvppu1eju1nitg 0000 resultmsg an 255 result message error code docid 4 fpewlvczfhcvygxwck9 success sample json for payloan cancel json request { 	"timestamp" "20221213141266", 	"txid" "payloantes00202212131410560896", 	"imid" "payloantes", 	"paymethod" "06", 	"canceltype" "1", 	"cancelmsg" "request cancel", 	"merchanttoken" "9d1835e8bf87b51b44de9b2455fa37e733a87b12644b9cd4546e2ec2de651863", 	"amt" "12000", "canceluserid" "admin" } json response { "txid" "payloantes00202212131410560896", "referenceno" "ord20200910170911", "resultcd" "0000", "resultmsg" "success", "transdt" "20221213", "transtm" "141056", "amt" "12000" } java request //cancel registration// nicepay settimestamp("20221213141266"); nicepay setimid("payloantes"); nicepay setamt("12000"); nicepay setmerchanttoken(nicepay maketoken(nicepay getmerchanttoken()); nicepay settxid("payloantes00202212131410560896"); nicepay setpaymethod("06"); nicepay setcanceltype("1"); nicepay setcancelmsg("request cancel"); nicepay setcancaluserid("admin"); // request cancel nicepay cancel(); // response string // system out println("final response string " + nicepay getresponsestring()); string resultcd = nicepay get("resultcd"); string resultmsg = nicepay get("resultmsg"); string txid = nicepay get("txid"); string referenceno = nicepay get("referenceno"); string amt = nicepay get("amt"); string cancelreferenceno = nicepay get("cancelreferenceno");