I'm implementing magento plugin and I need place order programatically. After payment is authorize (i use sales_order_save_commit_after event) i create invoice and shipping(programatically). After that order is set to processing. Now I want to confirm order and request confirmation to payment gateway. I assume that magento should do this automatically. But I dont know when. When (and where) confirmation to payment gateway is triggered? Where can I find detailed information about this process?


I think you should use sales_order_invoice_pay because all payment methods use $order->pay(),,in this event you can check total paid amount and all other things.

Also, it is very difficult to explain the payment flow in one answer, but I would suggest just going through the below links, may be you will get some better understanding.

Link 1

Link 2

Link 3

  • Sorry Keyur, answers was very helpful but this is not direct answer for main question. When and where confirmation request is triggered? I made few things like create shipment, create invoice and one of these things trigger confirmation request to payment gateway and change overall status of order to completed – Piotr Galas Sep 30 '15 at 5:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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