Hi there @shevczulak, welcome to the Community!
That’s a great question! There isn’t a trigger for Interfaces that looks like it would run when the user sends a message but you could trigger a Zap if they click on a specific button, does that help?
The Update Customer (WooCommerce) action has the ability for you to update a Meta data field:
So you could potentially use that field to add the new points value and not need to write a script/plugin for this.
In order for the Zap to know what new points value to set you’d likely need to use a Find Customer (WooCommerce) action to get their current points value. Then use a Formatter (Numbers > Spreadsheet-Style Formula) action to subtract the necessary amount from the current points value to get the new points value.
Here’s an outline of the workflow I’m picturing:
- Trigger: Chatbot Button Click (Interfaces) - runs when the user clicks a specific button.
- Action: Find Customer (WooCommerce) - searches for customer using email address supplied by Interfaces trigger. See: Search for existing data in Zaps
- Action: Numbers > Spreadsheet-Style Formula (Formatter) action - uses formula to calculate new points value. See: Use spreadsheet-style formula functions in Zaps
- Action: Update Customer (WooCommerce) - updates customer that was found (use the Custom value option to select the Customer ID output by Find Customer action to reference the correct customer).
Do you think that approach could work? If I've misunderstood what you're looking to do or you run into any issues in setting this up just let us know. Always happy to help further!
I think it will be helpfull, but for now i have other problem :)
I can’t connect Zapier to my WooCommerce site.
I have to buy special plugin zapier for woocommerce for 79$ for year?