Django-paypal: IPN requests with Invalid Postback
Asked Answered
G

1

10

I am building an e-commerce site using django-paypal to accept Paypal payments.

95% of the time, everything works flawlessly, users are able to pay, sandbox or not, and receive what they purchased.

The other 5% of the time, however, instead of 'VERIFIED' or 'INVALID' as the response code, I get: Invalid postback. (<html> <body> Fatal Failure <br> </body> </html> )

This prevents our program from knowing what to do, and so the payment gets verified on our side EVEN THOUGH the payment is marked as 'complete' in the IPN and on Paypal's side.

Gabar answered 5/11, 2015 at 23:31 Comment(0)
T
0

You must reflect (postback) all parameters that Paypal sent you, untouched. Without messing up the encoding. Even if odd characters are occasionally in the data, like \ backslash. Accidentally corrupting the data will yield the "Invalid postback ... Fatal Failure" that you observed.

For detailed troubleshooting please see PP_MTS_Chad's excellent advice in notify_url never call when buyer paid for subscription

Tournament answered 4/1, 2018 at 7:20 Comment(1)
Ok, but where in the code do you "reflect all parameters that Paypal sent you, untouched"?Clinton

© 2022 - 2024 — McMap. All rights reserved.