To start creating your messenger bot, select Bot Builder from your menu located on the left hand side of your Amico Dashboard. Make sure to select your correct Facebook page at the top before working on a bot.
To respond to each of our user’s actions, we create a separate node for each possible action. Below is a further explanation of how this is done:
- In the
When Receivedrop down, you must first select an action.
- If you select
Text, you will be shown a text box area. This area allows you to specify which text content you want your bot to respond to.
- If you select
Click, you will be shown a dropdown area allowing you to specify how you would like your bot to respond if a user clicks a certain element.
- If you select
- In the
Bot willdrop down, you must then select a message type that you would like your bot to respond with.
Get Started Button
Messenger’s get started button is important, as this is the first thing users will interact with for your bot. If you use our automatic setup, your get started button will be created for you automatically (you can easily edit it by hovering over it in your bot builder and clicking the little pencil icon). To create a get started button yourself, make sure you first have selected the correct page at the top, and then set the
When Receive field to
Click. In the payload field directly underneath, enter the payload of the get started button which is
GIGA_GET_STARTED_PAYLOAD. Now, in the
Bot will section, choose what you would like your bot to respond with once a user clicks your get started button.
It would take forever for us to create nodes for every possible combination of words a user might send. Lucky for you, Amico’s Bot Builder has a very simple to use text matching system. Below, we will demonstrate some different text matching options you can use with the bot builder’s
Text text box.
Match Any Combination of Characters
You can easily match any combination of text from a user by using the
% character will even match upper/lower case variations for you.
Here’s an example:
The above example would automatically be matched with
I want to buy the NEWEST mario game,
buy Mario game, and even
please help me buy that new mario game, etc.
The next example allows you to automatically match with any sentence that begins with the word
awesome followed by any combination of a sentence’s middle text and then ending with the word
dude. For instance:
cool shirt dude,
sweet messenger bot DUDE,
Awesome photos, I like them dude.
Your bot can’t always respond with the same “Hi” greeting for everyone. Often times, you’ll want it to pick random text, like “Hey”, “Sup”, “Hola” so that your bot will have better end user functionality. You can easily achieve this by using our bot builder’s simple built-in “Dynamic Shortcode” functionality.
How to Add A Dynamic Shortcode
Using Random Text
To have your bot randomly choose from a list of words, you must add multiple words between
[/random-text], making sure to keep each word on its own separate line.
You can also easily grab and integrate user info using our default “User Info” Shortcodes. Check it out:
Simple yet powerful
Another option is to place an entire list of strings between
() and separated by
|. The previously mentioned example can easily be rewritten as follows:
In just seconds, you can easily create as many text variations as you want. Wow, that’s easy!
(Yo|Sup|Hey|Hola) [first_name], have a (splendid|good|great|swell) day!
Out of the box, Amico comes with 6 easy to use user info shortcodes built right in. For example, if you set the “Bot will“ “Send Dynamic Shortcode“ field to
Hey [first_name]!, your bot will respond with Hey Jeremy! if the current user’s first name is Jeremy.
Below is a list of the 6 user info shortcodes Amico currently offers:
Another example, if instead of
Hey [first_name]!, you were to use
Hey [first_name] [last_name], you are one good lookin' [gender]!, your Amico bot will respond with Hey Jeremy Franz, you are one good lookin’ male! if the user’s full name is Jeremy Franz and their gender is male.