Reversal Transaction

In this section you will learn how to process a reversal transaction

Reversal Overview

The purpose of a reversal transaction is to cancel a transaction during or after processing but before settlement.

985

🚧

Key points when cancelling a transaction

*Partial reversals may not be supported by your acquirer. Please check with your acquirer for further details

  • Any over authorised funds will be dealt with by the acquirer and card scheme by PXP sending the Scheme Reference Data. Except for Omnipay, the over authorised funds remain authorised against the card.

How to process a Reversal Transaction

The merchant's system sends a request to ANYpay POS to reverse the original transaction. The TokenReversalRequest element is used in a message to request the reversal of a transaction.

📘

Key elements of a TokenReversalRequest message

Either a Token or a combination of a TokenizedCardNumber and TransactionReference MUST be supplied.

When providing the Tokenized Card Number with a Transaction Reference, the Transaction Reference must be the original reference of the transaction you are attempting to reverse.

TransactionAmount element is optional but is only used when providing the Tokenized Card Number with a Transaction Reference. If TransactionAmount is not provided then the full transaction amount will be reversed.

Section TokenReversalRequest Element describes the elements required to build an IccTransactionRequest message. An example of a TokenReversalRequest message can be seen below.

<?xml version="1.0" encoding="utf-16" standalone="yes"?>
<TokenReversalRequest xmlns="http://servebase.com/2009/06/pedframework">
  <TransactionConfig>
    <CustomerCode>PXP</CustomerCode>
    <Site>PXP000000001</Site>
    <Culture>en</Culture>
    <Workstation>001</Workstation>
    <MerchantId>2100112262</MerchantId>
    <Username>PxpUser1</Username>
    <Password>PxpPassword</Password>
    <IpAddress>127.0.0.1</IpAddress>
  </TransactionConfig>
  <TokenisedCardNumber>9946000000000150185</TokenisedCardNumber>
  <TransactionReference>Sale</TransactionReference>
	<TransactionAmount currency="GBP">20.00</TransactionAmount>
  <IsPartialReversal>true</IsPartialReversal>
  <ReverseReason>Incorrect Amount</ReverseReason>
  <PrintDataRequired>false</PrintDataRequired>  
</TokenReversalRequest >
<?xml version="1.0" encoding="utf-16" standalone="yes"?>
<TokenReversalRequest xmlns="http://servebase.com/2009/06/pedframework">
  <TransactionConfig>
    <CustomerCode>PXP</CustomerCode>
    <Site>PXP000000001</Site>
    <Culture>en</Culture>
    <Workstation>001</Workstation>
    <MerchantId>2100112262</MerchantId>
    <Username>PxpUser1</Username>
    <Password>PxpPassword</Password>
    <IpAddress>127.0.0.1</IpAddress>
  </TransactionConfig>
  <Token>1d811b87-5f84-41d9-9484-8a1a6adfd022</Token>
</TokenReversalRequest >

Handling an IccTransactionResponse message

Section IccTransactionResponse Element describes the elements that are returned in an IccTransactionResponse message. An example of an IccTransactionResponse for a TokenReversalRequest can be seen below.

<?xml version="1.0" encoding="utf-16"?>
<IccTransactionResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://servebase.com/2009/06/pedframework">
  <Language>en</Language>
  <ResponseCode>Authorised</ResponseCode>
  <FaultResponseCode>0</FaultResponseCode>
  <ResponseMessage>APPROVAL</ResponseMessage>
  <ReceiptInfo xsi:type="IccReceiptInfo">
    <CardNumber>541333******0185</CardNumber>
    <ExpiryDate year="49" month="12" />
    <StartDate year="96" month="12" />
    <TransactionAmount currency="GBP">15.00</TransactionAmount>
    <TransactionReference>Sale</TransactionReference>
    <PreAuthTransactionReference>Sale</PreAuthTransactionReference>
    <MerchantId>2100112262</MerchantId>
    <TerminalId>210011226201</TerminalId>
    <CardScheme code="MSC" creditDebitIndicator="CREDIT">Mastercard</CardScheme>
    <CaptureMethod>Icc</CaptureMethod>
    <Dcc xsi:nil="true" />
    <BelowSignatureLimit>false</BelowSignatureLimit>
    <BalanceOnCard xsi:nil="true" />
    <AuthorizedTransactionAmount currency="GBP">15.00</AuthorizedTransactionAmount>
    <ApplicationId />
    <PanSequenceNumber>00</PanSequenceNumber>
    <TransactionDateTime>2018-02-14T17:24:27.5916242+00:00</TransactionDateTime>
    <TransactionType>ReversalSale</TransactionType>
    <AuthorisationResponseCode />
    <IccAccreditationInfo>
      <CryptogramTransactionType>00</CryptogramTransactionType>
      <CryptogramInformationData>00</CryptogramInformationData>
      <TerminalType>00</TerminalType>
    </IccAccreditationInfo>
  </ReceiptInfo>
  <Token>1d811b87-5f84-41d9-9484-8a1a6adfd022</Token>
  <TokenisedCardNumber>9946000000000150185</TokenisedCardNumber>
  <AuthorityCode>  SALE</AuthorityCode>
  <AuthorityMethod>Online</AuthorityMethod>
  <TfsEligible>false</TfsEligible>
</IccTransactionResponse>