Accepting payments and sending invoices
Sending order updates
Sample Messenger store assistant
Intents and Entities
Building Dialogflow agent and connecting to Activechat
Sending user input to NLP engine
Triggering bot skills by intents and events
Working with entities
NLP best practices
Facebook Messenger has a limit of 10 cards in a single gallery. What happens if you have more than 10 products in a category? Obviously, you need some kind of pagination to display the whole list.
First of all, Let’s do some changes to the flow so we could implement this. We’ll be using $_shopify_total_pages system variable for this ($_woo_total_pages if you’re using WooCommerce) – each time dynamic gallery is rendered, this variable is updated to show actual number of pages (10 products per page) that gallery can display.
Here’s the logic behind the bot:
When user clicks “Next 10” or “Prev 10” button (quick reply), the bot is adding (or subtracting) 1 to $current_page and goes back to dynamic products gallery.
The bot is only 18 blocks, and provides complete e-commerce shop navigation.
Here is how it looks in the Messenger: