Reputation: 159
How to find the transaction ID from PayPal V2 API? I would like to give the transaction ID for buyer to track their transaction.
I can get the order ID and Capture ID but fail to find where to find the transaction ID. Only the deprecated V1 API can get the transaction ID. Is it not available anymore for V2?
FYI, the answer for V1 is here Paypal Transaction ID
Upvotes: 6
Views: 4883
Reputation: 31
In the PayPal V2 API, there are three APIs are normally associated:
Create authorization - https://developer.paypal.com/docs/api/overview/#authentication-and-authorization
Create order - https://developer.paypal.com/docs/api/orders/v2/#orders_create
Capture order - https://developer.paypal.com/docs/api/orders/v2/#orders_capture
You can get the Transaction ID from this API response. It should be under
"payments": {
"captures": [
{
"id": "3C679366HH908993F",
Upvotes: 3
Reputation: 175
Best way to do tracking on the transaction with your system and PayPal, use invoice_id in the purchase_units of the PayPal buttons. Checkout https://stackoverflow.com/a/66943880
Upvotes: 0
Reputation: 732
An API caller is never shared the transaction ID that is sent in the receipt to the buyer. Seller has their own capture/authorization id Buyer has their own capture/authorization id
if you want to use a common tracking identifier you can populate invoice_id ?
just curious how do intent to use >> I would like to give the transaction ID for buyer to track their transaction. >> can you elaborate it a little bit.
Upvotes: 1