paypalpayflowpro

How can I simulate an error using Paypal Payments Pro sandbox?


How do I simulate an error with PayPal Payments Pro? I am trying to simulate things such as Suspected Fraud, Declined cards etc.

We are using Magento Commerce Enterprise edition and would love to be able to see errors from the user interface. Any help would be greatly appreciated.

We are developing using the PayPal sandbox.


Solution

  • On the Developer Central site (https://developer.paypal.com), log in and go to Dashboard >> Sandbox >> Accounts. Find the email address for the PayPal Payments Pro account. Click on it, then click Profile. On the Settings tab, make sure that Negative Testing is enabled.

    Once Negative Testing is enabled, make sure that the order total matches one of PayPal's error codes (you can see the full list here). For example, to simulate error code 15005 (which is your basic "card was declined" error), run a transaction for $150.05.

    More info available here.

    Edit 7/7/2017: Changed instructions to reflect the current location of the negative test mode toggle, and changed the link to PayPal's dev documentation.