WotNot Help Center
Create a ticketBook a demoProduct
  • 👋Welcome!
  • 🏁Getting Started
    • Building a chatbot
    • Testing a chatbot
    • Publishing your bot
      • Web
        • Embed chatbots on website
      • WhatsApp
        • Meta
        • 360Dialog
        • Twilio
        • GupShup
        • TechAlpha
      • Instagram
      • Facebook Messenger
      • SMS
      • Mobile app
      • API
    • Utility Tools
    • Contacts
      • Scheduling a Contact Report
      • Exporting a Contact List
      • Blocking contacts
    • Chatbot Appearance
      • Custom CSS
      • Image dimensions
      • Pop-up messages
  • ⚒️Bot builder
    • Action blocks
      • Trigger
      • Send message
      • Collect input
      • Buttons
      • Reply buttons
      • Carousel
      • Agent
      • Answer AI
      • Set AI
      • Send an email
      • List
      • Condition
      • Talk to human
      • Dynamic data
      • Javascript
      • Collect file
      • Form
      • Webhook
      • Flow
      • Jump
      • Options
      • Calendar
      • Delay
      • Codeblock
      • Slider
      • Image gallery
      • Send WhatsApp
      • Send SMS
      • Send Email
      • Send Status
      • WhatsApp flow
      • Catalogue
    • Outbound bots
      • Building One Off Campaign
      • Building Ongoing Campaign
    • Variables
    • Cloning bots
    • Requesting edit access
    • Connecting action blocks
    • Creating a loop
  • ✨AI Studio
    • Building a GPT chatbot
    • Knowledge base
    • Custom Answers
    • Functions
    • Prompts
    • AI credits
    • Refresh frequency
  • 💬Live Chat
    • Overview
    • Building a bot with live chat
    • Creating views
    • Adding labels
    • Saved replies
    • Settings
  • 🔗Integrations
    • Overview
    • HTTP request
    • Ready integrations
      • Google Calendar
      • Google Sheets
      • Google Analytics
        • Using Javascript
      • Salesforce
      • HubSpot
      • Calendly
      • Slack
      • Airtable
      • Zendesk
      • Freshdesk
      • DialogFlow
      • Zoho CRM
    • Events
    • Zapier
    • Public APIs
  • 💬WhatsApp Business API
    • Getting a WhatsApp API
      • Getting WhatsApp API (Old approach)
      • Sandbox WhatsApp API
    • Facebook Business Manager (FBM) Verification
    • Creating a WhatsApp Template
    • Cost
    • Messaging Limits, Quality Rating
    • Official Business Account (Green tick verification)
  • 📊Reporting
    • Overview
    • Chatbot Report
    • Agent Report
    • Outbound Report
    • Link analytics
    • Weekly email report
  • 🛠️Troubleshooting
    • Getting notification for leads
    • JS functions to trigger chat widget
    • Opt-out management
    • Setting up link tracking
    • How do I hard refresh my browser?
    • Cookies
    • Notifications
    • Tracking Facebook Pixel
    • Setting up SSO login
    • Inviting teammates
    • Teams
  • 🧑‍💻Support
    • Creating a ticket
    • Book a demo
    • Purchasing a subscription
    • Cancelling a subscription
    • Refund policy
    • Reset password
    • Deleting account
Powered by GitBook
On this page
  • Conditions for trigger
  • Contact subscription
  • Inject data into the chatbot
  • Using Query params
  • Using JSON

Was this helpful?

  1. Bot builder
  2. Action blocks

Trigger

Starting point of the chatbot flow.

The trigger block is what determines which chatbot is to be executed when a user requests a chat.

Conditions for trigger

As you can have more than one chatbot on your account, the conditions on the trigger help the system qualify the right chatbot for the conversation.

You can also combine multiple conditions using an AND / OR operation.

The conditions on the trigger can be:

URL

The webpage URL the user is on.

For example, "URL contains pricing" or "URL equals https://wotnot.io"

Browser language

The default language set by the user on their browser. For example, "Language is French"

Date range

The date when the user is initiating the chat. For example, you can build a separate chatbot flow that activates during Christmas or for a new launch announcement.

Keyword

[Only for WhatsApp and SMS] The incoming keyword from the user that started the chat. For example, the user sent a keyword containing "Book appointment".

Button payload

[Only for WhatsApp and SMS] When the user receives a template message from the business and clicks on a button.

Conditions are not mandatory. If you have not defined any conditions for your chatbots, the first active chatbot on the list will be activated.

Contact subscription

Applicable only for WhatsApp and SMS.

In channels like WhatsApp and SMS, businesses can reach out to contacts at any time, even if the contact doesn't want to have a conversation.

Countries' laws mandate that companies maintain a subscription status for each contact, meaning that a contact has subscribed or unsubscribed from receiving your communication. This is similar to how unsubscription works on emails.

SUBSCRIBED - Will receive any new template message that the company sends as a promotion.

UNSUBSCRIBED - Will not receive any template message that the company sends as a promotion.

So, based on the conditions you define for the trigger, you can choose to set the subscription status for the contact.

Generally, you should always have two chatbots:

  • Your main chatbot, which has the 'Subscribed' status

  • An acknowledgment chatbot for when users type 'STOP.'

Inject data into the chatbot

If you want to send external data to the chatbot, you can use this option. Once enabled, you can map the fields that contain the value with the WotNot variable.

Two ways you can inject the data:

Using Query params

With this method, when the WotNot snippet is loaded on the website for the first time, the defined query params and their values will be stored in the WotNot variable.

For example, if your URL is the followingwww.wotnot.io?cust_id=1234&plan=9896

You can choose to store the values of cust_id and plan on the trigger action block.

Using JSON

With this method, you can inject a JSON payload inside the WotNot’s code snippet and map the objects to be stored in the trigger action block.

To do this you need to add the following object with your desired fields in the WotNot code snippet

data-session-payload='{"field1": "value", "field2: "value"}

Now, let's take an example to understand this.

Assume you are using the chatbot in your web app and you already know who is the user initiating the chat. For your agents to be aware of the user details, you can add their name, email, customer_id, plan, etc. to the WotNot code snippet.

<script src="" data-session-payload='{"name": "Charles", "phone": "8164848686"}' defer></script>

We have stored the “name” and “phone" fields to WotNot variables on the trigger action block.

Note:

  • WotNot reads this object only once when the code snippet is fired. Sending data after the code snippet loads will not be read.

  • Dynamically add the data-session-payload object to the WotNot code snippet

Use the following object paths to store the selected button's text, payload, or text message in a variable within the trigger block for WhatsApp Meta Cloud.

  • For selected button's payload

    • entry[0]['changes'][0].value.messages[0].button.payload

  • For selected button's text

    • entry[0]['changes'][0].value.messages[0].button.text

  • For a text message

    • entry[0]['changes'][0].value.messages[0].text.body

PreviousAction blocksNextSend message

Last updated 3 months ago

Was this helpful?

⚒️