rdrey
rdrey

Reputation: 9529

Django, PayPal IPNs & User Names - concept issues

I'm trying to sell virtual goods using PayPal (already implemented Zong+) in Django. I decided to use django-paypal to handle the IPN for me (decided that IPN was the best fully automated option.)

I've currently made a buy-now button using the PayPal button wizard on their website, ie it's secure and saved on paypal to protect against tampering. (I'm very new to PayPal, not living in a fully supported country, so haven't used it myself.)

My questions:

  1. How do I include the username that made the purchase or a similar means of identifying the user that made the purchase with the IPN callback later and retrieve that with django-paypal? Preferably with no means for the user to mess with it.
  2. Should i ditch the auto-generated button and roll my own instead? Will that let me pass extra invisible parameters that PayPal will send in the IPN later?
  3. The Sandbox doesn't let me make User Accounts that I can test on the real site, right? Unless I make a merchant in the Sandbox and make a button for that merchant, I think.

Upvotes: 1

Views: 343

Answers (1)

Mike Ryan
Mike Ryan

Reputation: 1438

1: If you use the django-paypal PayPalPaymentsForm you can specify a "custom" field containing the username. This will be posted back to you with the IPN. If your buttons are encrypted the user will be unable to tamper with this.

2: Yes, see 1 :-)

3: No, but you can create buyer and seller accounts on the Sandbox.

Upvotes: 1

Related Questions