Re: response and post in django
The straightforward thing is to use urllib2. The tricky thing is that
the thread that got the post from them in the first place will be
blocked waiting for their response.
But are you understanding the API correctly? I would expect the
"VERIFIED" to either be in their POST to your listener (to indicate
that the payor's payment method is valid), or that it would be in your
response to that POST to tell paypal that this looks like a valid
payment (the payment amount or item quantities haven't been hacked,
etc.).
But you could be right.
Bill
On 3/12/12, hack <scottmacri@gmail.com> wrote:
> I read the paypal ipn docs, and think I understand the procedure for
> processing payments.
> The only issue I have is that I am not 100% certain how to do this via
> django.
>
> Basically you setup a listener http://mysite.com/mylistener/, and when
> someone makes a payment paypal responds by notifying your litener. (ie
> - http://mysite.com/mylistener/?paypalparms=somepaypalstuff&blah=blah
>
> So I then access all the parms and verify them. However, the place where
> I'm stuck is how exactly do I programmatically execute a post back to
> paypal to confirm my receipt and how do I obtain their response object to
> view response.content? Basically I need to view the content of the body to
> see if it contains VERIFIED, etc. Django seems a little different than
> java servlets, which is what I am used to using. Thanks.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/django-users/-/wCjYi1UxT50J.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscribe@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home