Testing Chargebacks / Dispute with IPN in PayPal Sandbox

Is there any way to test Chargebacks / Disputes on Sandbox PayPal test site?

I am trying to use the permission center to create new cases, both using the usual method of contesting the charge, and using the separate section โ€œCreate or resolve a caseโ€ in the isolated software of the Permission Center.

In any case, I do this, I can only ever resolve disputes in the status of "Being Viewed by PayPal". No IPN notifications.

This support article lists the expected steps that I hope to emulate in a sandbox environment: https://ppmts.custhelp.com/app/answers/detail/a_id/622/kw/Dispute

+4
source share
1 answer

What you need to do is create your own IPN simulator to test this. You can create a basic HTML form with an action set to your IPN URL and hidden fields that correspond to the names / values โ€‹โ€‹that you expect to receive from IPN.

This way you can download your test in a browser and send it to your IPN listener. You will be able to see the results on the screen, which may help in troubleshooting.

Keep in mind that when testing this method, data does not come from the PayPal server, so the IPN will not be verified. You need to make sure your code logic handles this.

Here are some examples of IPNs that you will receive when a refund occurs so that you can see what you expect and configure your simulator accordingly.

New case

txn_type = new_case payment_date = 13:40:52 Aug 05, 2013 PDT case_id = PP-002-576-509-683 receipt_id = 4674-2219-3481-3741 case_type = chargeback business = payments@domain.com verify_sign = AeD56uUedZzgp83xxTHMkZtMZ9FVAzvpMwl6OHUf9CNvlvgA2P0mbcwP payer_email = 9FE47613HE5558457@dcc.paypal.com txn_id = 0PC8014855508203X case_creation_date = 18:40:23 Sep 04, 2013 PDT receiver_email = payments@domain.com payer_id = RZ3LX555U646Q receiver_id = M5VRA555CSK6 reason_code = non_receipt custom = charset = windows-1252 notify_version = 3.7 ipn_track_id = 2842c24f40ac 

Recovery

 mc_gross = -1972.86 protection_eligibility = Ineligible payer_id = RZ3LX555U646Q address_street = N/A payment_date = 18:42:00 Sep 04, 2013 PDT payment_status = Reversed charset = windows-1252 address_zip = 00000 first_name = Tester mc_fee = -44.74 address_country_code = US address_name = Tester Testerson notify_version = 3.7 reason_code = chargeback custom = business = payments@usbswiper.com address_country = United States address_city = NA verify_sign = Ai1PaghZh5FmBLCDCTQpwG8jB264ABWpa3tbhFljkaPnVj1L9ip5EwyS parent_txn_id = 0PC8014555008203X txn_id = 0PC8014855508203X payment_type = instant last_name = Testerson address_state = NA receiver_email = payments@domain.com payment_fee = -44.74 receiver_id = M5VRA555CSK6 item_name = PayPal POS Web Order mc_currency = USD item_number = residence_country = US receipt_id = 4674-2219-3481-3741 handling_amount = 0.00 transaction_subject = payment_gross = -1972.86 shipping = 100.00 ipn_track_id = f456d076de1ff 
+6
source

Source: https://habr.com/ru/post/1500769/


All Articles