PayPal

Redirect-based wallet payment. The customer is redirected to PayPal to authenticate and approve the payment, then returned to your return_url.

const paymentClient = new PaymentClient(config);

const response = await paymentClient.authorize({
    merchantTransactionId: "txn_001",
    amount: { minorAmount: 1000, currency: Currency.USD },
    paymentMethod: {
        paypalRedirect: {
            email: { value: "[email protected]" },
        },
    },
    captureMethod: CaptureMethod.AUTOMATIC,
    address: { billingAddress: {} },
    authType: AuthenticationType.NO_THREE_DS,
    returnUrl: "https://example.com/return",
});

Last updated

Was this helpful?