Search code examples
payment-gatewaysandboxcredit-cardauthorize.net

Authorize.net credit card charging in sandbox returns refTransID in response as null


I'm using sandbox account in Authorize.net and processing credit card charging. There is my response:

{ createTransactionResponse:
   { 'xmlns:xsi': 'http://www.w3.org/2001/XMLSchema-instance',
     'xmlns:xsd': 'http://www.w3.org/2001/XMLSchema',
     xmlns: 'AnetApi/xml/v1/schema/AnetApiSchema.xsd',
     messages: { resultCode: 'Ok', message: [Object] },
     transactionResponse:
      { responseCode: '1',
        authCode: '******',
        avsResultCode: 'Y',
        cvvResultCode: 'P',
        transId: '**********',
        refTransID: null,
        transHash: '************************',
        testRequest: '0',
        accountNumber: 'XXXX0000',
        entryMode: 'Keyed',
        accountType: 'AmericanExpress',
        messages: [Object] } } }

Why refTransID is null? I need this value for refund processing.


Solution

  • From the manual:

    Transaction ID of the original partial authorization transaction. Required only for refundTransaction, priorAuthCaptureTransaction, and voidTransaction. Do not include this field if you are providing splitTenderId

    So unless you are doing a split tender transaction you do not need this field for a refund.