Search code examples
paypal

Get PayPal Client ID from MY CLIENTS email address


I am creating a web app where my client will provide an email address where to get paid via PayPal for their customers to pay them. Problem is my clients will mostly have personal accounts and not business.

I know how to create the buttons using the API however I will need my client'ss client-id to render it. For business this is easy and I could give instructions where to find it, but what about personal? Better yet, can it be done programmatically?

https://www.paypal.com/sdk/js?client-id=[HOW DO I GET THIS FROM EMAIL ADDRESS ONLY]&currency=USD&disable-funding=credit,card&locale=en_US


Solution

  • A couple alternatives:

    1. Instead of using their client-id , use yours and their merchant-id, which they can obtain from their account settings or if you integrate "Log in with PayPal". See https://developer.paypal.com/sdk/js/configuration/#link-merchantid , the same ID needs to be specified in the v2/checkout/orders payee.merchant_id field.

    2. Use the payee.email_address field: https://developer.paypal.com/docs/checkout/standard/customize/pay-another-account/