Payment Void / Refund API
Cancels or refunds a completed payment. The same endpoint handles both same-day voids and post-settlement refunds.
Test Credentials
API Information
POST/v3/APIPayCancel.do
Content-Type
application/json; charset=UTF-8테스트
https://tbezauthapi.settlebank.co.kr/v3/APIPayCancel.do운영
https://ezauthapi.settlebank.co.kr:8081/v3/APIPayCancel.doRequest Parameters
타입 표기법
N숫자A영문H한글AN영문+숫자AHN영문+한글+숫자예: AN(10) = 영문+숫자, 최대 10byte
Required Parameters
└hdInfoAN(50)Alphanumeric, up to 50 bytes*Message type code.
Message type code.
*Fixed value
└apiVerAN(4)Alphanumeric, up to 4 bytes*API version.
API version.
*Fixed value
└mercntIdAN(8)Alphanumeric, up to 8 bytes*Unique merchant identifier assigned by Hecto Financial.
Unique merchant identifier assigned by Hecto Financial.
└oldTrNoAN(50)Alphanumeric, up to 50 bytes*Original transaction reference number (trNo from the capture response).
Original transaction reference number (trNo from the capture response).
└ordNoAN(100)Alphanumeric, up to 100 bytes*Cancellation order number. A new merchant-generated unique identifier for this void/refund request.
Cancellation order number. A new merchant-generated unique identifier for this void/refund request.
└cancelPriceAN(13)Alphanumeric, up to 13 bytes*
AES-256AES-256/ECB/PKCS5Padding + HexAmount to void or refund.Amount to void or refund.
└reqDayN(8)Numeric, up to 8 bytes*Request date (yyyyMMdd).
Request date (yyyyMMdd).
└reqTimeN(6)Numeric, up to 6 bytes*Request time (HH24MISS).
Request time (HH24MISS).
└signatureAN(200)Alphanumeric, up to 200 bytes*
SHA-256SHA-256 hash value for tamper protection.(실시간 생성)SHA-256 hash value for tamper protection.
NOTE
Signature Composition
mercntId + oldTrNo + ordNo + cancelPrice (plaintext) + reqDay + reqTime + hashKey
Optional Parameters
└taxPriceAN(13)Alphanumeric, up to 13 bytes
AES-256AES-256/ECB/PKCS5Padding + HexTaxable amount for the cancellation. Required for mixed-taxation transactions; omit for full cancellations.Taxable amount for the cancellation. Required for mixed-taxation transactions; omit for full cancellations.
└vatPriceAN(13)Alphanumeric, up to 13 bytes
AES-256AES-256/ECB/PKCS5Padding + HexVAT amount for the cancellation. Required for mixed-taxation transactions; omit for full cancellations.VAT amount for the cancellation. Required for mixed-taxation transactions; omit for full cancellations.
└dutyFreePriceAN(13)Alphanumeric, up to 13 bytes
AES-256AES-256/ECB/PKCS5Padding + HexTax-exempt amount for the cancellation. Required for mixed-taxation transactions; omit for full cancellations.Tax-exempt amount for the cancellation. Required for mixed-taxation transactions; omit for full cancellations.
Response Parameters
타입 표기법
N숫자A영문H한글AN영문+숫자AHN영문+한글+숫자예: AN(10) = 영문+숫자, 최대 10byte
└resultCdN(1)Numeric, up to 1 bytes*Result code.
0Result code.
0: Success -1: Failure└errCdAN(5)Alphanumeric, up to 5 bytes*Error code. See error code reference.
0000Error code. See error code reference.
└resultMsgAN(200)Alphanumeric, up to 200 bytes*Human-readable result message.
SuccessHuman-readable result message.
└oldTrNoAN(50)Alphanumeric, up to 50 bytes*Original transaction reference number.
STFP_PNPTms00001t00220922182409M1962430Original transaction reference number.
└trNoAN(50)Alphanumeric, up to 50 bytes*Void/refund transaction reference number.
STFP_PNPTms00001t00220404134307M1550602Void/refund transaction reference number.
└cancelPriceN(13)Numeric, up to 13 bytes*Voided/refunded amount.
9000Voided/refunded amount.
└disntCancelPriceN(13)Numeric, up to 13 bytes*Promotional discount amount reversed.
1000Promotional discount amount reversed.
└payCancelPriceN(13)Numeric, up to 13 bytes*Net settlement amount reversed (excluding discounts).
8000Net settlement amount reversed (excluding discounts).
└criPriceN(13)Numeric, up to 13 bytes*Cash receipt cancellation amount (cash-equivalent portion only).
7000Cash receipt cancellation amount (cash-equivalent portion only).
└criTaxVatPriceN(13)Numeric, up to 13 bytes*Cash receipt taxable cancellation amount (inclusive of VAT).
5500Cash receipt taxable cancellation amount (inclusive of VAT).
└criDutyFreePiceN(13)Numeric, up to 13 bytes*Cash receipt tax-exempt cancellation amount.
1500Cash receipt tax-exempt cancellation amount.
└cancelDayN(8)Numeric, up to 8 bytes*Void/refund date (yyyyMMdd).
20190222Void/refund date (yyyyMMdd).
Request Example
{
"hdInfo": "IA_CANCEL",
"apiVer": "3.0",
"mercntId": "ms00003t",
"oldTrNo": "STFP_PNPTms00001t00220922182409M1962430",
"ordNo": "OID201902210001",
"reqDay": "20190221",
"reqTime": "142120",
"cancelPrice": "[AES-256 encrypted amount]",
"signature": "[SHA-256 hash]"
}
Need technical support?
Code Samples
HectoFinancial GitHub