ReferencedRefundNotification Class

When a payment gateway sends a notification for a refund transaction, the payment gateway adapter creates the ReferencedRefundNotification object to store information about notification.

CommercePayments

This class is used with asynchronous payments. When a payment gateway sends a notification for a refund transcation, the gateway adapter creates an object of type ReferencedRefundNotification to populate the respective values.

The constructor of this class takes no arguments. For example:

CommercePayments.ReferencedRefundNotification rrn = new CommercePayments.ReferencedRefundNotification();

The following are methods for ReferencedRefundNotification.

Sets the transaction amount. Can be positive, negative, or zero.

global void setAmount(Double amount)

  • amount:

    Type: Double

    The amount to be debited or captured.

Type: void

Sets the AVS (address verification system) result code information that the gateway returned. Maximum length of 64 characters.

public void setGatewayAvsCode(String gatewayAvsCode)

  • gatewayAvsCode:

    Type: String

    Used to verify

    the address mapped to a payment method when the payments platform requests tokenization from the payment gateway.

Type: void

Sets the date that communication for the refund notification occurred with the payment gateway.

global void setGatewayDate(Datetime gatewayDate)

  • gatewayDate:

    Type: Datetime

    The date that communication happened with the gateway.

Type: void

Sets information or messages that the gateway returned.

global void setGatewayMessage(String gatewayMessage)

  • gatewayMessage:

    Type: String

Type: void

Sets the payment gateway’s reference details.

global void setGatewayReferenceDetails(String gatewayReferenceDetails)

  • gatewayReferenceDetails:

    Type: String

    Provides information about

    the gateway communication.

Type: void

Sets the payment gateway’s reference number.

global void setGatewayReferenceNumber(String gatewayReferenceNumber)

  • gatewayReferenceNumber:

    Type: String

    Unique transaction ID created by the payment gateway.

Type: void

Sets the payment gateway’s result code.

global void setGatewayResultCode(String gatewayResultCode)

  • gatewayResultCode:

    Type: String

    The gateway result code. You must map this to a Salesforce-specific result code.

Type: void

Sets the payment gateway’s result code description.

global void setGatewayResultCodeDescription(String gatewayResultCodeDescription)

  • gatewayResultCodeDescription:

    Type: String

    Description of the gateway result code. Provides additional context about the result code .

Type: void

Sets the ID of a notification sent by the payment gateway.

global void setId(String id)

Type: void

Sets Salesforce result code information.

global void setSalesforceResultCodeInfo(commercepayments.SalesforceResultCodeInfo salesforceResultCodeInfo)

Type: void

Sets the notification status value on the notification object.

global void setStatus(commercepayments.NotificationStatus status)

  • status:

    Type: NotificationStatus

    Indicates whether the payments platform successfully received the notification from the payment gateway.

Type: void