Payout REST sandbox api

nandini-dev
Contributor
Contributor

Hi 

I called the rest payout API for test sandbox mode

curl -v -X POST https://api.sandbox.paypal.com/v1/payments/payouts \
-H "Content-Type: application/json" \
-H "Authorization: Bearer A21AAFQD0OIlC7I8eemNg5KWkB-VIC_HHEFEzEqDtYERRrOPEXN7GqXNWfohrgcRlPTjkUCBUKdtOJBNBSj1iNcAWbjuvStNHQ" \
-d '{
"sender_batch_header": {
"sender_batch_id": "Payouts_2019_1005661",
"email_subject": "You have a payout!",
"email_message": "You have received a payout! Thanks for using our service!"
},
"items": [
{
"recipient_type": "EMAIL",
"amount": {
"value": "15",
"currency": "USD"
},
"note": "Thanks for your patronage!",
"sender_item_id": "20140314002101",
"receiver": "email_id",
"alternate_notification_method": {
"phone": {
"country_code": "91",
"national_number": "67542634"
}
}
}
]
}'



But in response I am getting 
"time_processed": "2019-10-23T09:57:27Z",
"errors": {
"name": "RECEIVER_UNREGISTERED",
"message": "The recipient for this payout does not have an account. A link to sign up for an account was sent to the recipient. However, if the recipient does not claim this payout within 30 days, the funds will be returned to your account.",
"information_link": "https://developer.paypal.com/docs/api/payments.payouts-batch/#errors",
"details": []
},
"links": [
{
"href": "https://api.sandbox.paypal.com/v1/payments/payouts-item/3S5DRGGF2YGBS",
"rel": "item",
"method": "GET",
"encType": "application/json"
}
]
email that I am using as receiver is registered with paypal still getting  "transaction_status": "UNCLAIMED",
in reposne.

Please suggest me 

Login to Me Too
1 REPLY 1

MTS_Justin
Moderator
Moderator
Hello,

You're testing this in our sandbox environment.

Is the recipient email added to a sandbox account ?

Sandbox and our production environment are two separate environments. If you have an email address registered on a production account and you attempt to use that email address to send a payment in our sandbox environment, if the email address is not registered on a sandbox account you will receive the message that the payment is "unclaimed", as there is no account to send to funds to.

Thanks !

Was my post helpful? If so, please give me a kudos!
Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.