0

when issuing a refund from the braintree or paypal panel the orders in Magento 2.3.4 are not set to "closed" and no credit memo is being created. Is there any setting I need to adjust? Payments work great otherwise. Any help appreciated.

edit: getting following error

[2020-03-19 10:07:13] main.CRITICAL: The "braintree_paypal" method isn't available. {"exception":"[object] (Exception(code: 0): The \"braintree_paypal\" method isn't available. at /home/cloudpanel/htdocs/www.myshop.com/vendor/magento/module-paypal/Model/Ipn.php:109)"}

paypal IPN is set to https://myshop.com/paypal/ipn

I read that I dont have to set this because magento is sending the IPN URL anyway but without it paypal doesnt send any request.

I have no problems with paypal express btw. With or without IPN setting in paypal

1 Answer 1

0

When an action is initiated via the Control Panel, no request is actually being sent via the API, so as a result, no response is sent to your endpoint. The Control Panel is an alternative path to your Braintree gateway that bypasses the API altogether. The Control Panel will not push response receipts to a given endpoint because it is not directly connect to any endpoint like your API integration is.

In order to ensure that refunded orders update in Magento properly, you'll need to initiate the refund via the API - whether that is from your Magento dashboard or directly via your API integration.

Refunds can be issued via the API using Transaction.refund()​:

$result = $gateway->transaction()->refund('the_transaction_id');

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.