line-echobot-heroku

LINE Messaging API echo bot. Official Ruby SDK's example with tweaks for Heroku.

Setup

1. Get Channel Secret and Channel Access Token

2. Deploy to Heroku

Deploy

  • Fill LINE_CHANNEL_SECRET with Channel Secret
  • Fill LINE_CHANNEL_TOKEN with Channel Access Token

3. Add FIXIE Outbound IPs to Server IP Whitelist

At dashboard.heroku.com:

  • Manage App -> Overview -> Fixie
  • Account -> Outbound IPs -> copy and memo it

At developers.line.me:

  • Server IP Whitelist -> IP address -> Fill FIXIE Outbound IPs -> ADD
  • Add alL Outbound IPs

4. Set Webhook URL

At dashboard.heroku.com:

  • Open app -> Copy app URL and memo it

At developers.line.me:

  • Basic information -> EDIT -> Webhook URL -> Fill it with ${APP_URL}/callback -> SAVE -> VERIFY (ensure Success.)

5. Add LINE@ account to your friend. Talk to bot.