E-Payment Integrator 2020 C++ Edition

Questions / Feedback?

Refund Method

Refunds a previously captured transaction.

Syntax

ANSI (Cross Platform)
int Refund(const char* lpszTransactionId, const char* lpszRefundAmount);

Unicode (Windows)
INT Refund(LPCWSTR lpszTransactionId, LPCWSTR lpszRefundAmount);
- (void)refund:(NSString*)transactionId :(NSString*)refundAmount;
#define MID_ICHARGE_REFUND 12

INPAY_EXTERNAL int INPAY_CALL InPay_ICharge_Do(void *lpObj, int methid, int cparam, void *param[], int cbparam[], int64 *lpllVal);

Remarks

This method refunds a transaction that has already been captured, or settled. If the transaction is still outstanding use the VoidTransaction method instead. The TransactionId parameter indicates to the Gateway which transaction is to be refunded, and should contain the ResponseTransactionId from the original transaction. The RefundAmount parameter is the value to be refunded back to the customer, and can be all or part of the original TransactionAmount

Please see the gateway information in the table of contents to determine if your gateway supports Refund transactions.

The gw3DSI gateway requires the following additional fields for Refund transactions:


class.AddSpecialField "UserId", "my 3DSI-assigned UserId" '(Different than MerchantLogin)
class.MerchantPassword = "my 3DSI-assigned Pwd"

The LinkPoint and PSIGateXML gateways require you send the ResponseInvoiceNumber rather than the ResponseTransactionId.

Error Handling (C++)

This method returns a result code; 0 indicates success, while a non-zero error code indicates that this method encountered an error during its execution. If an error occurs, the GetLastError() method can be called to retrieve the associated error message. (Note: This method's result code can also be obtained by calling the GetLastErrorCode() method after it returns.)

Copyright (c) 2021 /n software inc. - All rights reserved.
E-Payment Integrator 2020 C++ Edition - Version 20.0 [Build 7941]