Paypal REST API Adaptive / Multiple Payments (change payee)

不羁岁月 提交于 2019-11-26 09:39:45

问题


I\'ve just started looking at Paypal\'s REST api. One thing I can\'t seem to see is a feature paypal call Adaptive Payments. This allows me to register my app with my developer account, but not be involved in the actual payments. e.g. my app allows my users to accept payment for their services, which they sell through my app.

I have been through Paypals REST API documents. I have worked out how to complete a payment, but all the transactions get sent through to my developer paypal account. I can\'t find where i would change the receiver details, i.e. the seller, to allow payments to be sent to a different paypal account.


回答1:


As of January 3rd 2017, PayPal has now added the ability to set the payee to anyone you wish.

Notice the new payee object below:

{
    'intent':'sale',
    'redirect_urls':{
        'return_url':'http://localhost:3000/process',
        'cancel_url':'http://localhost:3000/cancel'
    },
    'payer':{
        'payment_method':'paypal'
    },
    'transactions':[{
        'amount':{
            'total':'10',
            'currency':'USD'
        },
        'payee':{
            'email': 'payee@test.com'
        },
        'description':'My amazing product'
    }]
}

However, there doesn't seem to be an ability to have multiple payee's.

Additional info here: https://devblog.paypal.com/setting-payee/




回答2:


Ok, after some extensive googling, I managed to find the answer here

This general model enables us to easily add support for variety of payment models in the future (Parallel, Chained, etc). The Payee could be a funding instrument (like a Credit/Debit Card,) or a PayPal account (wallet) itself. The Payee could be set explicitly if the Payee is not the same as the Payment Facilitator ( in this current release we only support the case where the Payee is same as the Facilitator) so this is not currently required.

So looks like a payee is just added to the transactions array, but this is not currently implemented as of the date of this answer.



来源:https://stackoverflow.com/questions/15405632/paypal-rest-api-adaptive-multiple-payments-change-payee

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