Skip to content

Latest commit

 

History

History
38 lines (25 loc) · 804 Bytes

README.md

File metadata and controls

38 lines (25 loc) · 804 Bytes

This sample-bot uses linebot framework

Documentation

Channel token

Example

var linebot = require('linebot');

var bot = linebot({
    channelId: CHANNEL_ID,
    channelSecret: CHANNEL_SECRET,
    channelAccessToken: CHANNEL_ACCESS_TOKEN
});

bot.on('message', function (event) {
    event.reply(event.message.text).then(function (data) {
        // success
    }).catch(function (error) {
        // error
    });
});

bot.listen('/linewebhook', 3000);

message

picture