API approved order not forwarding to PayPal

FishpoolDuan
Contributor
Contributor

I use my personal PayPal account to test run PayPal api integrated in my app which is linked to my PayPal business account.

 

It can generate prepaid order PAYER_ACTION_REQUIRED  and I can click to pay with no problem

 

But after the "Successful Payment" showed up, and the statues became APPROVED , there is no actual inquiry either from my associated bank account nor to Paypal. 

 

No money outbound and I asked customer service several times after different attempts they all replied there is no evidence of transection request happened on either account after every attempt.

 

Wonder how do I fix this

 

{"id":"6CY052871D001944R","intent":"CAPTURE","status":"APPROVED","payment_source":{"paypal":{"email_address":"exampleemail","account_id":"P278YUGWM4NFE","account_status":"VERIFIED","name":{"given_name":"Firstname","surname":"Lastname"},"address":{"country_code":"US"}}},"purchase_units":[{"reference_id":"default","amount":{"currency_code":"USD","value":"2.00","breakdown":{}},"payee":{"email_address":"businessaccount","merchant_id":"GWY77AJXSYNU8"}}],"payer":{"name":{"given_name":"Firstname","surname":"Lastname"},"email_address":"exampleemail","payer_id":"EXAMPLEWM4NFE","address":{"country_code":"US"}},"create_time":"2024-04-30T01:45:26Z","links":[{"href":"https://api.paypal.com/v2/checkout/orders/6CY052871D001944R","rel":"self","method":"GET"},{"href":"https://api.paypal.com/v2/checkout/orders/6CY052871D001944R","rel":"update","method":"PATCH"},{"href":"https://api.paypal.com/v2/checkout/orders/6CY052871D001944R/capture","rel":"capture","method":"POST"}]}

Login to Me Too
1 ACCEPTED SOLUTION

Accepted Solutions
Solved

MTS_Jennifer
Moderator
Moderator

Hello @FishpoolDuan 

Thank you for posting to the PayPal Merchant Community. Thank you for providing the details of your testing. Once the payment has been approved by the buyer, you have three hours to send the capture api call. If the capture API call is not sent within 3 hours of the order creation the order will be voided. Once the order is captured a transaction id is created, the payment status changes to completed, and the funds are sent to your PayPal account.

Here is the documentation:

Complete integration documentation, including back end coding:

https://developer.paypal.com/studio/checkout/standard/integrate

API calls for capturing the order:

https://developer.paypal.com/docs/api/orders/v2/#orders_capture

 

This is the example API Call to capture the Order:

curl -v -X POST https://api-m.sandbox.paypal.com/v2/checkout/orders/5O190127TN364715T/capture \
-H 'PayPal-Request-Id: 7b92603e-77ed-4896-8e78-5dea2050476a' \
-H 'Authorization: Bearer access_token6V7rbVwmlM1gFZKW_8QtzWXqpcwQ6T5vhEGYNJDAAdn3paCgRpdeMdVYmWzgbKSsECednupJ3Zx5Xd-g'  

 

Thank you,

Jennifer

MTS

PayPal

View solution in original post

Login to Me Too
2 REPLIES 2
Solved

MTS_Jennifer
Moderator
Moderator

Hello @FishpoolDuan 

Thank you for posting to the PayPal Merchant Community. Thank you for providing the details of your testing. Once the payment has been approved by the buyer, you have three hours to send the capture api call. If the capture API call is not sent within 3 hours of the order creation the order will be voided. Once the order is captured a transaction id is created, the payment status changes to completed, and the funds are sent to your PayPal account.

Here is the documentation:

Complete integration documentation, including back end coding:

https://developer.paypal.com/studio/checkout/standard/integrate

API calls for capturing the order:

https://developer.paypal.com/docs/api/orders/v2/#orders_capture

 

This is the example API Call to capture the Order:

curl -v -X POST https://api-m.sandbox.paypal.com/v2/checkout/orders/5O190127TN364715T/capture \
-H 'PayPal-Request-Id: 7b92603e-77ed-4896-8e78-5dea2050476a' \
-H 'Authorization: Bearer access_token6V7rbVwmlM1gFZKW_8QtzWXqpcwQ6T5vhEGYNJDAAdn3paCgRpdeMdVYmWzgbKSsECednupJ3Zx5Xd-g'  

 

Thank you,

Jennifer

MTS

PayPal

Login to Me Too

FishpoolDuan
Contributor
Contributor

Thank you very much problem solved 

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.