QuestionQ9
Customize Commerce featuresAn Adobe Commerce Architect must customize the workflow for a monthly-installments payment extension. The extension is supplied by a partner contracted with the default website Payment Service Provider (PSP), which has its own legacy extension—a module that uses a deprecated payment method.
The installments payment partner only manages payment initialization and then delegates capture execution to the PSP. After the amount is successfully captured, the PSP notifies the website by webhook. The webhook’s sole purpose is to create an “invoice” and save the “capture information” for later refund requests through the PSP itself.
The Architect needs the simplest solution to achieve the requested behavior.
Which solution should the Architect implement?
- A Add a plugin before the $invoice->capture() and change its input to prevent the call of the $payment->capture()
- B Change the can_capture attribute for the payment method under config.xml to be <can_capture>0</can_capture>
- C Declare a capture command with type Magento\Payment\Gateway\Command\NullCommand for the payment method CommandPool in di.xml
Community Discussion