• Resolved sanjaym23

    (@sanjaym23)


    I have integrated core woocommerce API in one of my websites. While placing an order from the website – the order status – “Pending payment” and once payment processed the order status should change to “completed” and email trigger to admin.

    However, if user placing the order from the mobile app using create an order REST API, The order status – “Processing” and email shoot to admin about the order. Then user processing payment or cancel payment, the order status update accordingly.

    But due to this weird behavior, there is unnecessary email triggered to admin while placing an order from mobile without complete the payment and client getting worried about this. Can you please suggest any hook which helps to send the proper order status for mobile API. By this way, Web and the Mobile app should work properly.

Viewing 1 replies (of 1 total)
  • Plugin Support Fernando a11n

    (@fhaps)

    Automattic Happiness Engineer

    Hi @sanjaym23,

    I’m not entirely sure I understand the issue completely. Are you saying that, when payment is received from an order, that order is placed in the Processing status? Is that something you’d like to change?

    Because, that is the default, correct behavior of WooCommerce. When payment is received for an order, that order’s status is updated to Processing, and an email is triggered for the admin to know that they have received an order. The intended workflow is that the admin would then manually mark the order as Completed once this order has been fulfilled.

    The only exception to this flow, are orders who contain only products that are both virtual and downloadable. Those orders are sent directly to the Completed status, without passing through Processing.

    I hope this helps clarify things a bit. If I misunderstood your question, or you are trying to achieve something different, please let us know!

Viewing 1 replies (of 1 total)
  • The topic ‘Create an order working different way from web and API’ is closed to new replies.