How to load transaction data by id Magento 2?

Get a specific Payment transaction details by the given Transaction id in Magento 2.

Retrieve the transaction details information will be an array of order id, txn_id, payment id, txn_type, and additional_information from the sales_payment_transaction database table.

The sales module has API TransactionRepositoryInterface, use get() method from the interface to fetch transactional data. Continue reading “How to load transaction data by id Magento 2?”

Payment has already been made for this InvoiceID (#10412: Duplicate invoice) Magento Error.

When Order placed using PayPal payment, Customers facing an error for a #10412 duplicate invoice:

PayPal gateway has rejected request. Payment has already been made for this InvoiceID (#10412: Duplicate invoice).

You can Resolve the error by Paypal Account settings steps. Continue reading “Payment has already been made for this InvoiceID (#10412: Duplicate invoice) Magento Error.”

Remove Billing agreements link from Customer sidebar Magento 2.

Remove the Billing agreements link Tab from the Customer account sidebar page using Magento 2.

You can remove the Billing agreements link using the customer_account.xml file in your theme or module level. Agreements links come from the Magento_Paypal Module. Continue reading “Remove Billing agreements link from Customer sidebar Magento 2.”