Welcome to use Botimize, the conversation analytics platform for bot builders.
In here, we are giving an example of building a botimize integrated messenger bot, written in nodeJS.
We also provide the same example for other platforms/languages, check out our sample bot list.
To get started, just follow four steps:
3. Integrate our SDK (or use RESTful API) to track your chatbot
const botimize = require('botimize')('<YOUR-BOTIMIZE-API-KEY>', 'facebook');
app.post('/webhook', function (req, res)) {
botimize.logIncoming(req.body);
...
}
let options = {
uri: 'https://graph.facebook.com/v2.6/me/messages',
qs: { access_token: accessToken },
method: 'POST',
json: true,
body: messageBody,
};
request(options, function (error, response, body) {
botimize.logOutgoing(options, {parse: 'request'});
...
});