Automatically capture different payment methods

For a merchants B2B shop we have set up an integration to their ERP system which automatically is fulfilling Shopify B2B orders.

In Shopify admin I have set up a Flow that should automatically capture payments once the order is fulfilled. There are two different payment methods: manual and credit card (Shopify Payments).

The Flow is working for orders with manual paytments but is throwing an error for orders payed by credit card and hence the payments are not being captured.

Flow looks like this. What do I need to change, so payments are always captured no matter which payment method??

Mark order as paid != capture payment. They are separate actions.

Yes I guessed that. But is it possible to do a check of the payment method? If it’s manuel then I can mark it as paid otherwise I need to capture payment instead. Or what would you suggest?

Hi Paul,
Could you please let me know if it is possible to do a check of the orders payment method? If possible it would be simple to either mark as paid or else capture payment based on the specific payment method.

Look at order / transactions