@plentymarkets/shop-api / getExecutePayPalOrder
Function: getExecutePayPalOrder() ​
getExecutePayPalOrder(
context
,params
):Promise
<Data
<PayPalExecutePayment
>>
Method getExecutePayPalOrder - checks the PayPal payment status and changed the plenty order status accordingly
Parameters ​
• context: PlentysystemsIntegrationContext
• params: PayPalExecuteParams
mode: string - mode of the payment (e.g. paypal) plentyOrderId: number - plenty order id paypalOrderId: string - PayPal transaction id paypalMerchantId: string - PayPal merchant id
Returns ​
Promise
<Data
<PayPalExecutePayment
>>
Remarks ​
- Calls rest/payment/payPal/{params.mode}/{params.plentyOrderId}/{params.paypalTransactionId}/{params.paypalMerchantId}/execute-payment
- This method is used to check the PayPal payment status and changed the plenty order status accordingly
Example ​
ts
const { data } = await useSdk().plentysystems.getExecutePayPalOrder({
plentyOrderId: 1606,
paypalTransactionId: '6GY88326V4505594A',
mode: 'paypal',
});