Using New Order Webhook for Subscriptions
-
When a subscription is first purchased woocommerce makes a “New Order” webhook call. I will use this webhook to provision the customer, storing the customer details in our database. For each subscription renewal woocommerce also makes a “New Order” webhook call. I want to flag these later webhook calls as “renewals” of the original subscription purchase and not new subscriptions. It looks like the “cart_hash” webhook parameter stays constant in all webhook calls for a given subscription (along with the customer/CC details, of course). I want to use the “cart_hash” as a kind of “subscription id”, a way to associate a “New Order” webhook call with an existing subscription. Is this a correct interpretation?
Note: Our customer can purchase multiple subscriptions, at different times, so we cannot use the customer name, email, etc. to associate a webhook to a given subscription.
- The topic ‘Using New Order Webhook for Subscriptions’ is closed to new replies.