Skip the Welcome Message

Abby Updated by Abby

Because we're simulating a user input with code, every time the page is loaded it will be counted as a chat

To skip the welcome message and directly begin the flow with other blocks we'll need to use Javascript in the Custom Javascript section of the bot, as well as CSS

This is what the flow looks like:

We'll still need to add a welcome message in order to publish the bot, here we added a Question block which we'll hide with CSS

The flow will start at the Global Keyword, it's important that the text in the Global Keyword is default

After the Global Keyword you can add anything you want, just keep in mind that parameters in the url won't be available until after a real user input

This is what the Design Section looks like (Custom Code):

The first snippet we'll add is the CSS, we'll add it in the first box where it says 'Add CSS':

[data-block="welcome"] { display:none!important;}

This hides the welcome message

Next we'll add the Javascript, this is what we'll add:

<script>
var landbotScope = this;
this.onLoad(function(){

landbotScope.core.events.on("init", () => {

landbotScope.core.sendMessage({ type: 'hidden', payload: "default" })
}
)
})
</script>

This script simulates a user input when the bot loads and directs the user through the default option in Global Keywords as soon as the bot is loaded

That's it!

In order to test you will need to test with the url or in an embedded page, you cannot test with preview for this workaround

How did we do?

Two-Step Email Verification

Fixing Web Bot Loading Issues for iOS Devices in Meta Campaigns with Disclaimers

Contact