Reputation: 153
I stared taking payments using paypal buttons, I then used adaptive payments API, I am now using rest API.
I have all the transactionId 's for all transactions, what I would like to do is get a list of all the transactions, or one by one.
I want to start storing the payments in a database differently and need to get some data from previous transactions.
I realized that with Rest you can only get transaction details for transactions you created with rest.
What API should I use, what is the easiest. Thanks
Upvotes: 0
Views: 2155
Reputation: 1723
You can get the history of all your transactions created via REST APIs by using https://developer.paypal.com/webapps/developer/docs/api/#list-payment-resources. Example in python sdk, https://github.com/paypal/rest-api-sdk-python/blob/master/samples/payment/all.py
For getting history of one transaction, you can use https://developer.paypal.com/webapps/developer/docs/api/#look-up-a-payment-resource. Example in python sdk, https://github.com/paypal/rest-api-sdk-python/blob/master/samples/payment/find.py
Upvotes: 1