Hello,
I'm not a developer and tried to create a bot with AI, but I couldn’t get it to work. I’d really appreciate advice on how to build the following setup:
Before any user interaction, the bot should retrieve:
- the page URL
- today’s date
- whether the user interacted with the bot in the last 7 days
Based on the URL and time of year, the bot should:
- choose the correct start node (e.g. "Product")
- load values like disp_choix, intro, link
- auto-open the chat window if needed (and no recent interaction)
I plan to use a table (TargetingTable) with these fields:
- url_pattern (String): part of the URL to check
- start_date, end_date (String): MM-DD format
- year (optional): specific year or empty for all years
- node_depart, disp_choix, intro, link
- auto_open (Boolean): true/false
- last_interaction_check (Boolean, optional): true = check for interaction in the last 7 days
The URL doesn't need to match exactly—just include the url_pattern.
Also, I want to manage the rules outside the injected code (so no redeployment needed when editing them).
From what I understood, I need to:
• create and query a dynamic table
• use sendCustomEvent to pass the URL to the bot
• use "Expression" cards in Botpress to route to the right node based on node_depart
Thanks in advance to anyone who can help or guide me!