Skip to main content

Create a Global Node

Now you can see your first node in the workspace, how about on your testing chatbot? In this section, we will teach you to create another type of node: Global Node. Global node allows you to trigger the same node at any point of your conversation flow.

Once added to Channel, Global Node is often used as a "door" to kickstart a conversation. For example, it is used extensively on the "Get Started" button or the "Persistent Menu" buttons of Facebook Messenger.

Without a Global Node, no one can ever kick-start your chatbot.

Expected Outcome

You should also be able to trigger the first node on your testing chatbot in two ways: by clicking the Get Started button or the Main Menu button.

Get started button
Get started button
Main menu button
Main menu button

Create 1st Global Node: Main Menu

Enter your Bot Builder.
  1. Select "+" on right top corner of workspace.
  2. Select "+ Global Node".
Add Global Node
Add Global Node
  1. Head to the "Node Inspector" and name your global node.

  2. Usually we would put Global at the end of the global node to identify it from the general node with the same name. Since we are going to create a persistent menu button Main Menu to trigger our first node, name the global node "Main Menu Global".

Name Global Node
Name Global Node

Create a Trigger

  1. Scroll down to "Trigger" and click "+ New Trigger".
Add trigger
Add trigger
  1. A new window of Trigger Builder will be opened. You can first name your trigger.
Create New Trigger
Create New Trigger
  1. Under Resource Template, select "Keywords / Payload" from the dropdown.
Select Trigger Type
Select Trigger Type
  1. Type the payload and then click "Enter" to confirm. The payload is "MAIN_MENU" in this example.
Type Payload
Type Payload
  1. Finally, you can "Save" the trigger settings and close the pop-up window.
Save Trigger
Save Trigger

Toggle on Redirect

  1. Scroll down to "Redirect" and toggle it on (it will turn green).

  2. Select the chatbot and node you want to redirect your users to whenever they click on this global node and usually it's the chatbot and you are editing right now. So for chatbot, select "Restaurant Info"; for node, select your first node "User clicks Get Started".

Toggle on Redirect
Toggle on Redirect
Select the chatbot and node you want to redirect to
Select the chatbot and node you want to redirect to
tip

Sometimes we could also redirect users from one chatbot to another chatbot. It is applicable when you have multiple chatbots in your channel.

  1. Click "Save" at the bottom to save the node.
Save the node
Save the node

Create 2nd Global Node: Get Started

  1. Repeat the same steps from 1 to 12 to create another global node: "Get Started Global".
New Global Node
New Global Node

The payload for this global node is "Get_STARTED" in this example.

Add another global node
Add another global node

Add Chatbot to Channel

  1. Head back to "Channel". Enter your Facebook channel. Click "Edit" to enter into the testing channel.
Enter Channel
Enter Channel
  1. On the left tab, click "Chatbot Settings". Click "+ New Chatbot" under "Default".
Add Tree to Channel
Add Tree to Channel
  1. Select the chatbot from the dropdown, and select the global nodes. Remember to "Save" the chatbot settings.
Select your chatbot
Select your chatbot

Set up Persistent Menu

Now you have to add the menu button "Main Menu" on the Persistent Menu.

  1. In "Channel" -> "Platform", please make sure you have "Get Started" setup.
Get Started Button
Get Started Button
  1. Scroll down to Persistent Menu and click "+ Button".
Add persistent menu button
Add persistent menu button
  1. Fill in the Title and Payload, this payload should match with the payload you have created for the global node. Remember to Save the persistent menu settings.
Create persistent menu button
Create persistent menu button
tip

Sometimes the persistent menu will be cached and it needs a little time to refresh. One trick to refresh conversation is to delete the whole conversation manually and you should be able to see the changes immediately. Try killing the app if you still can't see the new changes.