• Resolved Ricardo

    (@rickdroio)


    Dears,
    I’m using Woocommerce webhooks for approved orders in order to upload products and user data to my internal ERP.
    The webhook target is a firebase cloudfunction.
    It usually works fine, but sometimes I got a http_request_failed from google server:

     [Response] => Array
                    (
                        [Code] => http_request_failed
                        [Message] => cURL error 6: Could not resolve host: us-central1-xxxxx.cloudfunctions.net
                        [Headers] => Array
                            (
                            )
    
                        [Body] => Webhook body is not logged unless WP_DEBUG mode is turned on. This is to avoid the storing of personal data in the logs.
                    )

    The webhooks retry works after few hours later (sometimes it doesnt work). Is it possible to change it settings? Reduce retry time, trials, etc?

    Thanks for your support

    • This topic was modified 4 years ago by Ricardo.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Ricardo

    (@rickdroio)

    No ideas?

    Plugin Contributor Claudio Sanches

    (@claudiosanches)

    Hello @rickdroio,

    Is it possible to change it settings? Reduce retry time, trials, etc?

    It’s necessary some coding, but it’s possible to change trials time with:

    add_filter( 'woocommerce_max_webhook_delivery_failures', function( $max ) {
        return 10; // Default is 5.
    });
    

    It’s also possible to control and trigger something else custom in case a webhook keep failing using the woocommerce_webhook_disabled_due_delivery_failures hook.

    But about the “retry time” note that Webhooks are sent by Action Scheduler, you can change the Action Scheduler settings, but it change for all things on your store. You can also go to “WooCommerce > Status > Action Scheduler” and check the list of webhooks (and other tasks) that are pending.

    I hope it helps you ??

    Plugin Support Damianne P (a11n)

    (@drwpcom)

    Hi @rickdroio. We haven’t heard from you in a while so I’m going to go ahead and mark this thread as resolved. If you still need help with this issue or have any other questions about the WooCommerce plugin, please start a new thread.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Webhooks Retry’ is closed to new replies.