I am getting below give response while doing PayPal payment with card using sandbox credentials.
{
"client": {
"environment": "sandbox",
"paypal_sdk_version": "2.14.6",
"platform": "Android",
"product_name": "PayPal-Android-SDK"
},
"response": {
"create_time": "2017-01-31T08:12:40Z",
"id": "PAY-*************",
"intent": "sale",
"state": "created"
},
"response_type": "payment"
}
Then i tried to get Full details by Payment ID using rest API call and getting "DEAD" state on payment response. Please check below response
{
"id": "PAY-*************",
"create_time": "2017-01-31T08:12:40Z",
"update_time": "2017-01-31T08:13:22Z",
"state": "DEAD",
"intent": "sale",
"payer": {
"payment_method": "credit_card",
"funding_instruments": [
{
"credit_card": {
"type": "visa",
"number": "xxxxxxxxxxxx1111",
"expire_month": "11",
"expire_year": "2025"
}
}
]
},
"transactions": [
{
"amount": {
"total": "2.00",
"currency": "USD",
"details": {
"subtotal": "2.00"
}
},
"description": "New Product",
"related_resources": []
}
],
"links": [
{
"href": "https://api.sandbox.paypal.com/v1/payments/payment/PAY-*************",
"rel": "self",
"method": "GET"
}
]
}
Can anyone please help me to understand why i am getting this ? how to fix this ?
How long will PayPal hold your funds for? Your funds are usually held for up to of 21 days. However, there are several things you can do to expedite this timeline. You can also read our User Agreement for more information on other holds and reserves we may place on your account.
PayPal can freeze your account and its funds for up to 180 days. If you don't do anything, you'll get your frozen funds back in six months. If you're difficult to work with — or PayPal feels you're not cooperating, they can extend the normal 180-day wait time.
PayPal is committed to serving our customers in Thailand. We have been working to update our products and processes to best meet the needs of our customers in Thailand, and we look forward to serving you as we gradually complete the relaunch of PayPal Thailand. Thank you for your continued interest in PayPal.
Finally I got the solution. It's a bit late to reply here but this answer can save time for those who are still struggling.
The JSON below is returned by Android SDK after creating a payment but we can see its status is not approved yet. If we use the payment lookup API (https://api.sandbox.paypal.com/v1/payments/payment/PAY-*************
) to verify the payment we will get a DEAD status and there will not be any transaction id.
{
"client": {
"environment": "sandbox",
"paypal_sdk_version": "2.14.6",
"platform": "Android",
"product_name": "PayPal-Android-SDK"
},
"response": {
"create_time": "2017-01-31T08:12:40Z",
"id": "PAY-*************",
"intent": "sale",
"state": "created"
},
"response_type": "payment"
}
Solution that worked for me
The problem was I created a Business account in my sandbox, but I had to create a Business-Pro account in sandbox. After doing this I got the approved status and when I use the payment lookup API, I get all details we need.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With