blog

Authorize.net Debugging in Magento

published in

Magento, Web Development

comments

3

Configuring authorize.net with Magento is rather simple – all you need is an API login ID and a transaction key – so usually there are few issues with this on a Magento site. However, on a few occasions I have not been able to get authorize.net connected properly and receive errors that make little sense upon attempting to complete a test order. So here is how to debug authorize.net:

1. In Magento navigate to System -> Configuration -> Payment Methods -> Authorize.net and set Debug to Yes.

2. Next navigate to the Developer tab (from where you currently are) and under Log Settings set Enabled to Yes.

3. Now go ahead and run a test order on the front end of the site until the point when you get an error with it is attempting to authorize/process the payment.

4. From here FTP into your site and navigate to the var/log and look for the file payment_authorize.net.log. Open this file and you should see two arrays, the top containing the request and the bottom containing the result. Here is a shortened example of the result:

Array (
    [response_code] => 3
    [response_subcode] => 1
    [response_reason_code] => 87
    [response_reason_text] => Transactions of this market type cannot be processed on this system.
    [approval_code] =>
)

5. From here you can take these resulting codes and look them up on the Response and Reason Codes page on Authorize.net site.

From this point you should be able to get a better idea of what may be going on. As well this information can be useful when talking to the support desk. Always verify that the account is setup correctly as well. A few times I have have the improper account type (card present retail account vs ecommerce account) which has caused major headaches.

This entry was posted in Magento, Web Development and tagged , , , , . Bookmark the permalink.

3 Responses to Authorize.net Debugging in Magento

  1. Ian Walker says:

    Can you do something similar with paypal?

  2. Kevin says:

    Nice little tip. I found it just at the right time. This is the kind of thing that should be on the Magento wiki.

  3. Bret says:

    Good idea Kevin – I’ll look into submitting that to the wiki.

    Bret

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>