How can I verify a PayPal ID?

China☆狼群 提交于 2020-01-06 13:21:58

问题


I have an application writted in ASP with a simple form. The users fill up the form with their PayPal ID to receive money exchanging their points.

I want to verify the PayPal ID before they submit the form using some kind of http request. I have looking into the PayPal API but i didn't find anything.

Thanks.


回答1:


If the PayPal api doesn't support a "verify" of call, then here's the usual alternative:

  1. Create a "paypal_ids" database table in your application
  2. When a PayPal id is entered by someone, check your table to see if you have already validated the id for a previous transaction. If you have, then you're all set. -- You could also keep bad ids in the table, to act as a negative cache.
  3. To validate a paypal id, just attempt to do a real transaction against the id, where you try to "send" 1 penny to the id. If it works, then you've validated the id. Store your results in your table and go on from there.

This is how paypal validates checking accounts--by doing a small, but real, test transaction.



来源:https://stackoverflow.com/questions/2478678/how-can-i-verify-a-paypal-id

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!