Check if paypal email address is a verified user

泄露秘密 提交于 2019-12-03 06:48:43

If you're not already, I would recommend using the Express Checkout API. This will allow you to check the payer status prior to finalizing the payment.

The SetExpressCheckout API would generate your token that you use to redirect the user to PayPal with. They would then sign in, review the order, and click continue which would send them back to your site.

At that point, you can call GetExpressCheckoutDetails to obtain all the buyer details including their verified status.

To finalize the whole thing you would call DoExpressCheckoutPayment. In cases where the payer is not verified, though, you could simply stop the flow and leave this call out. No payment will have taken place so no refund would be necessary. You can simply display a message that they need to verify their account prior to making purchases from you.

If you happen to be working with PHP I would recommend taking a look at my class library for PayPal. It makes all of this very simple for you.

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