Choose the recipient of the payment in PayPal Express Checkout - paypal

I am creating a marketplace-type checkout process with PayPal's Express Checkout. Am I correct to call the Classic API with
SUBJECT=somebody#email.com
in the SetExpressCheckout call to ensure that somebody#email.com is the recipient of the payment, not myself?
I'll need to do this for a bunch of sellers on the marketplace, so that everybody can receive payments directly from buyers to their PayPal account.
It's not in the documentation at https://developer.paypal.com/docs/classic/api/merchant/SetExpressCheckout_API_Operation_NVP/ but I found it searching on Google.
Am I calling this correctly?
UPDATE 1:
Or should I be using PAYMENTREQUEST_n_SELLERPAYPALACCOUNTID?
UPDATE 2:
I tried using PAYMENTREQUEST_n_SELLERPAYPALACCOUNTID? and it didn't work, saying I did not have authorization. But then I used SUBJECT= and it worked fine, even though that account never granted me permissions.
Is this the correct way? I just need people being able to send payments to multiple sellers. I don't need to do anything fancy like refunds or things like that.

Are you trying to pass PAYMENTREQUEST_0_SELLERPAYPALACCOUNTID without any other credentialing parameters (e.g., USER, PWD, and SIGNATURE)? This might be your problem.
There are three different ways that you can process payments for another user without API permissions:
Pass SUBJECT by itself.
Pass USER, PWD, SIGNATURE, and SUBJECT.
Pass USER, PWD, SIGNATURE, and PAYMENTREQUEST_0_SELLERPAYPALACCOUNTID. (Note that it should be PAYMENTREQUEST_0_SELLERPAYPALACCOUNTID, not PAYMENTREQUEST_n_SELLERPAYPALACCOUNTID.
Here are the caveats:
Option 1 can be (and, in some instances, has been) shut off at any time — so really, option 2 or option 3 is your best option. (Option 1 is really best for downloadable shopping carts that want to offer merchants a quick way of enabling PayPal.) Some people will tell you that option 3 is the preferred way to do it, but really, option 2 and option 3 both work equally well.
If the subject hasn't granted you any API permissions, you'll be limited to Sale transactions — so make sure that PAYMENTREQUEST_0_PAYMENTACTION is set to Sale.
There's a setting in the merchant's account to block payments from uncredentialed shopping carts. If this option is turned on, none of these approaches will work unless the merchant grants you API permissions. (However, this option is turned off by default, and most merchants don't know about it.)

You should be using the concept of Express Checkout parallel payments instead of using the "subject" parameter . In the parallel payments whomever you are going to put under "PAYMENTREQUEST_n_SELLERPAYPALACCOUNTID" will receive the payments . With this you can send the payments to upto 10 sellers at a stretch unlike the "subject" parameter where you can send payment only to one receiver at a time.
I have included the request for SETEXPRESSCHECKOUT call for parallel payment .
NVP Request:
USER=XXXXXXXXXX&PWD=XXXXXXXXXXXX&SIGNATURE=XXXXXXX&VERSION=109.0&METHOD=SetExpressCheckout&RETURNURL=http://XXXXX/index.php?action=ECreturn&CANCELURL=http://XXXXX/index.php?action=ECcancel&LANDINGPAGE=BILLING&SOLUTIONTYPE=SOLE&PAYMENTREQUEST_0_CURRENCYCODE=USD&PAYMENTREQUEST_0_AMT=300&PAYMENTREQUEST_0_ITEMAMT=200&PAYMENTREQUEST_0_TAXAMT=100&PAYMENTREQUEST_0_DESC=Summer Vacation trip&PAYMENTREQUEST_0_INSURANCEAMT=0&PAYMENTREQUEST_0_SHIPDISCAMT=0&PAYMENTREQUEST_0_SELLERPAYPALACCOUNTID=Eshan#XXXX.pro&PAYMENTREQUEST_0_INSURANCEOPTIONOFFERED=false&PAYMENTREQUEST_0_PAYMENTACTION=Order&PAYMENTREQUEST_0_PAYMENTREQUESTID=CART26488-PAYMENT0&PAYMENTREQUEST_1_CURRENCYCODE=USD&PAYMENTREQUEST_1_AMT=200&PAYMENTREQUEST_1_ITEMAMT=180&PAYMENTREQUEST_1_SHIPPINGAMT=0&PAYMENTREQUEST_1_HANDLINGAMT=0&PAYMENTREQUEST_1_TAXAMT=20&PAYMENTREQUEST_1_DESC=Summer Vacation trip&PAYMENTREQUEST_1_INSURANCEAMT=0&PAYMENTREQUEST_1_SHIPDISCAMT=0&PAYMENTREQUEST_1_SELLERPAYPALACCOUNTID=Eshan#XXXXX.com&PAYMENTREQUEST_1_INSURANCEOPTIONOFFERED=false&PAYMENTREQUEST_1_PAYMENTACTION=Order&PAYMENTREQUEST_1_PAYMENTREQUESTID=CART26488-PAYMENT1&L_PAYMENTREQUEST_0_NAME0=Depart San Jose Feb 12 at 12:10PM Arrive in Baltimore at 10:22PM&L_PAYMENTREQUEST_0_NAME1=Depart Baltimore Feb 15 at 6:13 PM Arrive in San Jose at 10:51 PM&L_PAYMENTREQUEST_0_NUMBER0=Flight 522&L_PAYMENTREQUEST_0_NUMBER1=Flight 961&L_PAYMENTREQUEST_0_QTY0=1&L_PAYMENTREQUEST_0_QTY1=1&L_PAYMENTREQUEST_0_TAXAMT0=50&L_PAYMENTREQUEST_0_TAXAMT1=50&L_PAYMENTREQUEST_0_AMT0=50&L_PAYMENTREQUEST_0_AMT1=150&L_PAYMENTREQUEST_0_DESC0=SJC Terminal 1. Flight time: 7 hours 12 minutes&L_PAYMENTREQUEST_0_DESC1=BWI Terminal 1. Flight time: 7 hours 38 minutes&L_PAYMENTREQUEST_1_NAME0=Night(s) stay at 9990 Deereco Road,Timonium, MD 21093&L_PAYMENTREQUEST_1_NUMBER0=300&L_PAYMENTREQUEST_1_QTY0=1&L_PAYMENTREQUEST_1_TAXAMT0=20&L_PAYMENTREQUEST_1_AMT0=180&L_PAYMENTREQUEST_1_DESC0=King No-Smoking; Check in after 4:00 PM; Check out by 1:00 PM
NVP Response:
TOKEN=EC-59G28135S2093963X
TIMESTAMP=2015-04-05T21:51:31Z
CORRELATIONID=419ef62debfd2
ACK=Success
VERSION=109.0
BUILD=16057073
Then your buyer will see something like below :

Related

Paypal ExpressCheckout + chained Payment

I developed a Web Application that accepts payments via the ExpressCheckout API, for users to become a members.
Everything works fine.
I now want to extend my Web Application Services and offer my users with the possibility to buy items which are sold by third parties (my members).
The principle I would like to implement is quite simple: for each order, let the user pay for the item they choose and then transfer a part of the amount I received to the item provider, and keep some money for me. I would like to automate this process so that once I received the payment notification, I compute the amount of money to transfer to the item provider who might or not have a Paypal account (in other words, this means that I could maybe need to transfer the money to a bank account, using the IBAN/SWIFT data) and then proceed with the money transfer.
I tried to find a solution reading your documentation and came across the "chained payment" but the latter does not seem to be used within the ExpressCheckout workflow.
Also, since my implementation of the ExpressCheckout flow works, I would not like to have to find a totally different solution but rather extend it... if possible.
Could you please tell me which is the best solution for me?
In advance, many thanks for your help.
You could do 1 of 2 things. You could use Express Checkout with parallel payments. This means you could split the transaction up between different accounts at the time of purchase. The other option would be to just receive all of the funds into your account, and then when you are wanting to send money to the other accounts you could either use the Adaptive Payments (Pay) API or the MassPayments API to send money to the other accounts. Keep in mind you would have to send it to their PayPal accounts, you would not be able to send it directly to a bank account with either one of these API's.
I had the same issue and I got an answer from PayPal that it is not allowed to use Express Checkout to transfer money to your PayPal account and - at a later point in time - transfer the amount minus your service fee (which stays on your PayPal account) via Adapative Payments API to the seller's PayPal account. PayPal suggested to use Chained Payments API instead. All works fine in the sandbox, but once you need a Live APP ID from PayPal they will review your business case and deny it. At least that what happened to me.
I know that is old question, but anyway, I tried to find solution and was enable to perform the simillar thing like described in question. So, then I asked paypal about this, and they gave me advice to use SellerDetailsType Fields that 's called PayPalAccountID, description for this field is Unique identifier for the merchant. For parallel payments, this field is required and must contain the Payer Id or the email address of the merchant. It wasn't clear for me to use this field for solving my problem. Here is link https://developer.paypal.com/webapps/developer/docs/classic/api/merchant/SetExpressCheckout_API_Operation_SOAP/ I described field for soap request, for NVP it's called PAYMENTREQUEST_n_SELLERPAYPALACCOUNTID, but the idea is the same. I hope it will help someone.

Paypal Marketplace Seller

I'm struggling to pick the right Paypal solution for a small marketplace website.
The site has a number of vendors and customers buy directly from them. There is no commission or complication - payment is direct, buyer to vendor.
It crosses my mind that although I'm the merchant, I'm not the final funds recipient - so I can't see how I can make this work. I'd like to use Express, but I'm not sure that I can set the funds recipient to a third party account.
I don't want to use Adaptive. I've tried that before and it has some features missing (mostly relating to verified addresses, ability to list invoice items etc).
It also crosses my mind that if buyer A sends to Vendor B through the site, then there can be no IPN as the merchant is not the final recipient.
Really I'm looking for the right way to go to deploy a solid Paypal solution for this.
You could use Express Checkout for this. They vendors would just need to grant API permissions to your API username so that your user name has the permissions to execute Express Checkout API calls on their account. This will allow you directly process the transactions on their PayPal account. You can also pass over the IPN URL in the API call that you would like to have the IPN sent to. Also by passing it over in the API call, it will override the one set in the account for the particular transaction you pass it over for. This way the merchant/vendor can still use the one they may have set in their account for something else.

Paypal payment process in 2 step?

I want to make payment process in 2 step , in first step paypal should collect fund from user account but not transfer to the merchant account .
when i send another request with sucess action at that type paypal should transfer fund to merchant account or if i pass fail action then paypal should refund to user.
is there any way to do this ?
i reefer following URL but cant find solution .
https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_api_WPECIntegration#id0861K0T0WY4
Express Checkout is what you want, but there's better documentation available.
Basically, what you're after is Authorization and Capture. When you create your Express Checkout API requests you'll set the PAYMENTACTION to Authorization. Then, when you're ready to process the payment you call DoCapture and pass in the transaction ID you get back from Express Checkout.
No money is processed until the DoCapture call is processed. If you don't end up needing to process it you can simply do nothing, but that would strand the authorization on the user's account for the default period of time depending on their bank. Usually 30 days.
It's a better practice to call DoVoid at that point, which would cancel the authorization and release those funds back to the user's account immediately.
If you want to do the same thing with credit cards directly you can use Payments Pro. The process is almost identical, except there are actually fewer calls involved.
If you're using PHP I would recommend taking a look at my PHP class library for PayPal. It'll make all of this very simple for you, and I can provide 30 min of free training to help you get going if you want, too.

Paypal recurring payment

I've got an enhancement from client and big trouble with answer if it is possible or not to do.
What I have is a web which provides seo service.
Client types phrase than chooses service option etc.
There are severals service options like:
single payment - service will be active per only 90 days
membership - client declare to pay a sum of money every 90days (recurring payment)
membership + extra support - same as membership but + extra sum of money
1) Suppose that client choosed first option and after 90 days decided to continue service.
Is it possible to set reccuring payment via paypal without need of client's interference* (we do not store any credit cards numbers in database).
2) Suppose that client choosed second option and after about 10 days decided to get extra support.
Is it possible to change sum of money which we are charging from client every 90 days, without his interference*.
* client don't have to fill up payment form (paypal side) once again.
I would be very grateful if anyone can help me with this issue. If it is possible which paypal accout do I have to get.
Thanks
Maciek
Thanks for reply. However I still don't get it.
Do you know how can I (as merchant) from my website/shop admin panel (not paypal profile site) cancel subscriber's subscription ?
In PDF "Recurring Payments API Overview" I have read that
"N O T E : There is currently no API access to allow merchants to modify or cancel a profile."
and in limitation:
"You cannot modify or cancel a recurring payment profile using the Recurring Payments API".
What can I do with this issue? Maybe there is another Paypal API that lets me to do what I want.
By the way reading PayPal Payments Standard Integration Guide I found that without subscriber's log in it is not possible to upgrade his account. Is it possible to upgrade ( charge more money monthly) without his log in?
Thanks
Maciek
Yes, PayPal has a "subscription" mode to handle this sort of thing, including the ability to modify a subscription. See https://www.paypal.com/pdn-recurring.

PayPal - Unattended charges

Well, I didn't really know how to call this...
I have been surfing PayPal's developer documentation for a while now, but there is nothing that speaks to me with direction as to achieving what I am looking for.
It's probably well documented, but I don't grasp it well enough yet to make sense while reading each part separately.
I have read about Preapproval, though it seem to require that I send the customer's browser to the designated PayPal address.
I have thought about creating a database with credit card information, but that is too scary -- so I am looking to see if there is a way for a customer to allow me to do unattended charges to their PayPal account, much like I would be able to do if I had a database with customer credit card information.
Any direction would be appreciated.
Yes, this is possible. There are two options:
PayPal Express Checkout with a Billing Agreement
This works similarly to Preapprovals (which is Adaptive Payments, a different set of API's). You would need to redirect the buyer to PayPal in order to accept the billing agreement, and from then on you can bill the user using to DoReferenceTransaction API.
PayPal DoDirectPayment (Website Payments Pro) with Reference Transactions
You would need to have an existing transaction, and instead of a billing agreement ID, you would submit a prior transaction ID to the DoReferenceTransaction API. You can then re-bill the user on the card details which are stored with PayPal (up to 1 year. assuming the card details are still valid).
Do note that both options require you having access to the DoReferenceTransaction API, which you will not have access to by default.
For further information on the API itself, see https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_api_nvp_r_DoReferenceTransaction
Important: You will need to call in to get Billing Agreements activated. Good luck finding someone that knows what you need (no really) :-)
You will eventually find someone who knows what DoReferenceTransaction is and then once you've finally found them they'll probably tell you they can only activate it in the sand box and transfer you to someone in the Business Office. They'll have to then submit it to approval with someone else. Est. Total call time 59 minutes 8 seconds.
The guy I just spoke with said he's probably handled only 2 call in a year about DoReferenceTransaction - so you may need to ask around. They have other subscription billing and that's not what you want.
Also realize that approval is not instant and you may need to have established history. The guy who helped me said this is the best number
888 215 5506. Be sure to explain why you need them carefully and try to reassure them you're legitimate. A reputable website behind the domain for your paypal email will probably help.
Good news: I applied for Reference Transactions Friday and was approved today (Sunday). This was for two accounts - one which had only been established the day before.
Thank you for contacting us about enabling reference transactions on
your PayPal account.
I am pleased to inform you that your request has been approved. You
can begin using this feature immediately.
If you have further questions regarding this email, please contact a
Merchant Services Specialist at 1-888-221-1161.
Sincerely,
AJ Merchant Risk Operations
I was trying to do this recently and I found this question with no luck because the Express Checkout with a Billing Agreement method is deprecated since January 1, 2017.
There is a new REST method called Vault payment methods that recently entered open beta and it's not in the official documentation (to this date), so I leave the link to Create transactions when your buyer isn't present, in case someone needs it.
The process it's explained in the documentation but basically, you need to create a payment token (the source can be a PayPal account or a credit card), and then use that token to capture the payment.