Note I am using Classic API because I am in a country where I can't use the REST API for credit card payments.
I am just getting started on setting up an application to use Express Checkout instead of Payment Standard and I'm totally lost with PayPal's API set-up. They made it incredibly difficult even reading the documentation.
I did the following already:
Set up a Classic API account for my "App" and got:
Sandbox ID: APP-XXXXXXXXXXXXX Live App ID: APP-XXXXXXXXXXXXX
Generated API Signature in my Premier account and got:
Credential: API Signature API Username : name_api1.domain.com API Password: XXXXXXXXXXXX Signature: (Really long string)
Now, I figured out that I can call this to create a test token like this:
curl -s --insecure https://api-3t.sandbox.paypal.com/nvp
-d "USER=platfo_1255077030_biz_api1.gmail.com&
PWD=1255077037&
SIGNATURE=Abg0gYcQyxQvnf2HDJkKtA-p6pqhA1k-KTYE0Gcy1diujFio4io5Vqjf&
METHOD=SetExpressCheckout&
VERSION=78&
PAYMENTREQUEST_0_PAYMENTACTION=SALE&
PAYMENTREQUEST_0_AMT=19&
PAYMENTREQUEST_0_CURRENCYCODE=USD&
cancelUrl=http://www.example.com/cancel.html&
returnUrl=http://www.example.com/success.html
But how do I call it with my own API username and password? I tried replacing my info with the PWD
and the USER
and it's not working.
Do I always test with the above cURL request while in sandbox? Or should I be using my own? If so, how? And what is the Sandbox ID for? I can't seem to specify it anywhere in the cURL.
I checked the documentation at https://developer.paypal.com/docs/classic/products/#ec but it doesn't make any sense.