Skip to content
This repository has been archived by the owner on May 12, 2020. It is now read-only.

how to send payment to other account ? #25

Closed
kiro112 opened this issue Feb 12, 2014 · 6 comments
Closed

how to send payment to other account ? #25

kiro112 opened this issue Feb 12, 2014 · 6 comments

Comments

@kiro112
Copy link

kiro112 commented Feb 12, 2014

right now. i can send payment and the account that will receive tha payment is the account that handle/hold my data in the paypal configure(client_id, secret)..

i cant see any example/documentation that tell how to configure the receiver of the payment.

thanks

@avidas
Copy link
Contributor

avidas commented Apr 14, 2014

Hey @kiro112 , as of now the receiver of the payment must have a client_id and client_secret i.e. they would need to have a merchant account with paypal.

If you have multiple client id and client secrets, on the node sdk you could have them as

var receivers = {
"receiver1" : {client_id: "xyz",
client_secret: "abc"},
"receiver2": {client_id: "123",
client_secret: "456"},
}

Now, you could use them for creating payments. e.g. In samples/payment/create_with_credit_card.js, you could do

paypal_api.payment.create(create_payment_json, receivers.receiver1, function (error, payment) {
}

This would ensure that receiver1s credentials are used while creating the payment. Hope this helps.

@avidas
Copy link
Contributor

avidas commented Apr 22, 2014

@kiro112 closing as this is the only currently existing way to transfer to different account via REST. Native support for configuring the receiver of the payment might be added in a future release of the APIs.

@junaidvbase
Copy link

Hi,
How can i pass the products details into the API, like the product name, quantity and the amount as we are passing the total amount.

Thanks

@kiro112
Copy link
Author

kiro112 commented Oct 31, 2014

@junaidvbase in his sample ( https://github.com/paypal/PayPal-node-SDK/blob/master/samples/payment/create_future_payment.js ) he has a "description" attribute, perhaps you can put the products detail through a json string ?

sorry for my grammar.

@junaidvbase
Copy link

Yes you're right, but i want as the list, the description shows only a paragraph.not in a table or div format like invoice!. Thanks for you reply :)

@avidas
Copy link
Contributor

avidas commented Dec 30, 2014

Hey @kiro112 with the release of the payouts api, you have the option to send a single or batch payout, allowing payments to be sent to single or multiple recipients. Here is a sample for single payout. Please reopen if this does not serve your use case.

@junaidvbase it would be better to open a new issue if you are still encountering the problem.

@avidas avidas closed this as completed Dec 30, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants