Prechat Capture form

Prechat Capture is a widget add-on which leverages the form message type, and allows you to capture profile fields like a user’s name, email and category before the start of a conversation.

Prechat Capture

When enabled, the chat input is disabled and the user is greeted by a welcome message and a form asking for their name and email. Once the form is successfully submitted, a 'thank you' message is sent to the user and the conversation is then initialized, connecting the user to your business.

When the customer is done filling the form fields (the customer cannot enter any other message before finishing the form), the form values are processed immediately (and the conversation possibly routed), while the customer is still typing their first real question in the chat window.

Enable the Scenario Bot

The Scenario Bot manages the prechat capture settings. To enable the prechat capture experience, simply hire the bot from the bot store, and configure the bot:

Scenario Bot

A default prechat capture form is provided, which will ask for the contact's name and email.

Custom Prechat Capture

Any form can be used to push to the contact: simply create or find a form named "Prechat Capture", and assign it in the Scenario bot configuration. All form fields of type text or select will be pushed to the contact before starting a conversation.

Prechat Capture

Contact profile properties

If the form field is called name or email or telephone, it will set the name, email or telephone in the contact's profile after filling in the contact form.

Routing Commands

Prechat Capture routing is a way to speed up the response time of the agents by routing the conversation to the right agent even while the customer is still busy typing their first real question. By preparing our Prechat Capture form with specially named form fields, we can give the form extra capabilities like immediately setting a category, notifying inboxes or assigning to a bot.

To build a routing-capable dropdown menu, create a field with as key "/command" in your Prechat Capture form. Make it a 'select' type, and use a command-type message as option names, followed by a value.

Typically, you'll want to use the following commands as option keys:

  • /set @category <category-name>
  • /notify <channelId>
  • /assign <botId>
  • /mention <botId botCommand arguments>

You can mix and match different commands in the same select dropdown menu. When the dropdown option is chosen by the consumer, the command will be executed.

Option: Set a category

Use the following option name to set the conversation category to 'Used Car':

/set @category Used Car

You can also use the /set command to set the conversation language. See the /set reference for details.

Option: Notify the organization

To trigger the organization's (and parent organization's) routing rules, use just this option name:

/notify

Option: Notify a specific inbox

Use the following option name to notify an inbox that has inbox ID '62c4d0fd07a9e73050b9a554':

/notify 62c4d0fd07a9e73050b9a554

Option: Assign to a bot

To assign to the Contact Me bot (which has botID '6050966f00c6e002dc2fbb6e')

/assign 6050966f00c6e002dc2fbb6e

Option: Mention a bot

To mention a bot, use the /mention <botId botCommand arguments> construct.

The ChatScript bot (having botId 6248f0083ab5d5001e523146) for example, supports mention texts that begin with the word 'start'. It parses mention text like

  • start <conversationId> to start a conversation
  • start <conversationId:messageId> to start the bot from a specific message.

As an option value, this would amount to:

/mention 6248f0083ab5d5001e523146 start 626ed838809b981773134000:626ed838809b981773134002

The first ID is the bot, accepting a conversation ID and a message ID as the 'start' arguments.

Example PcC form with commands

As an example, take a look at a Prechat Capture form that uses the above /mention construct to point to three subflows in a scripted conversation:

Prechat Capture

Recording the response

The form values entered by the consumer will be recorded as a Report message type in the conversation.