Okay
  Public Ticket #3543442
Invoices
Closed

Comments

  •  2
    Alexander started the conversation

    I have an automation in Mailchimp that is supposed to send an email to my subscribers after they place an invoice through my store. However, that automation is not triggering. Mailchimp's support told me that this is happening because the Mailchimp integration is not receiving the proper API calls in the back-end to trigger the automation

  •  2
    Alexander replied

    This only happens when i use the invoice payment gateway to get a pdf attached to the email

  •  1,910
    WebWizards replied

    Hi Alexander,

    I'd be happy to check and see if there's something we can do on our end to resolve it. The invoice gateway is implemented as a standard WooCommerce payment gateway, so I'm not really sure where to start with it unfortunately.


    Can the Mailchimp team share more details, including technical details? What API calls are not being triggered and do they have any idea why? Are there particular hooks involved, or is this dependant on an order status? Any details and technical info they can share would be helpful. 

    Could the problem be that the invoice gateway uses the "on-hold" order status?


    Kind regards,

    Stefan

  •  1,910
    WebWizards replied

    My suspicion is that the problem could be that Mailchimp only works with the processing order status.

    You can try to add this PHP code snippet to your site, to see if it solves it:

    add_filter('b2bking_invoice_payment_order_status', function($status, $order){
        return 'processing';
    }, 10, 2);
    

    This makes our invoice gateway use processing instead of on-hold.


  •  2
    Alexander replied

    What is the best way i can add this to the site without messing anything up internally


  •  1,910
    WebWizards replied

    The best way to do it would be by using a code snippets plugin.

    You can follow our guide here: https://woocommerce-b2b-plugin.com/docs/how-to-add-a-snippet-php-or-js/