Instructions and for running your own code snippets in a bot action.
exports.main()
function is called when the code snippet action is executed.event
argument is an object containing details for the visitor and chat session.callback()
function is used to pass data back to the bot and user. It should be called in the exports.main
function.event
object will contain the following data:
callback()
function is used to send data back to the bot. The argument should be an object with the following data:
require()
function at the top of your code.