🦞
Channel Integration

Connect OpenClaw to LINE

Integrate OpenClaw with LINE messenger for AI-powered conversations across Japan, Taiwan, Thailand, and beyond.

🟢 Why Use LINE?
  • Massive Asian User Base — 200M+ users in Japan, Taiwan, Thailand, Indonesia
  • Rich Messaging — Stickers, Flex Messages, and rich media
  • LINE Official Account — Professional presence for your bot
  • LIFF Integration — Embed mini-apps in LINE
  • Group Support — Works in group chats and 1:1 messages

Setup Steps

1

Create a LINE Developers Account

Sign up for LINE Developers:

  • • Go to LINE Developers Console
  • • Log in with your LINE account
  • • Create a new Provider (your company/personal name)
2

Create a Messaging API Channel

Set up a new channel for your bot:

  • • Under your Provider, click "Create a new channel"
  • • Select "Messaging API"
  • • Fill in the channel details (name, description, category)
  • • Agree to the terms and create the channel
3

Get Channel Credentials

Retrieve the required tokens and secrets:

  • • In the channel settings, go to "Messaging API" tab
  • • Copy the Channel Secret
  • • Issue a Channel Access Token (long-lived)
  • • Note your Channel ID
4

Configure Webhook URL

Set up the webhook endpoint in LINE Developers:

  • • In "Messaging API" tab, find "Webhook settings"
  • • Enter your webhook URL: https://your-server.com/webhook/line
  • • Enable "Use webhook"
  • • Verify the webhook connection
5

Configure OpenClaw

Add the LINE configuration to your openclaw.json:

{
  "channels": {
    "line": {
      "enabled": true,
      "channelId": "YOUR_CHANNEL_ID",
      "channelSecret": "YOUR_CHANNEL_SECRET",
      "channelAccessToken": "YOUR_CHANNEL_ACCESS_TOKEN",
      "allowFrom": ["USER_ID_1"]
    }
  }
}
6

Add the Bot as a Friend

Start chatting with your bot:

  • • Restart OpenClaw: openclaw restart
  • • Scan the QR code in LINE Developers, or
  • • Search for your Official Account by ID
  • • Add as friend and send a message to test
Advanced Configuration
{
  "channels": {
    "line": {
      "enabled": true,
      "channelId": "YOUR_CHANNEL_ID",
      "channelSecret": "YOUR_CHANNEL_SECRET",
      "channelAccessToken": "YOUR_CHANNEL_ACCESS_TOKEN",
      "allowFrom": ["USER_ID_1", "USER_ID_2"],
      "allowGroups": true,
      "respondToMentions": true,
      "useFlexMessages": true,
      "webhookUrl": "https://your-server.com/webhook/line"
    }
  }
}
  • channelId — Your LINE channel ID
  • channelSecret — Secret for webhook verification
  • allowGroups — Enable group chat support
  • useFlexMessages — Enable rich Flex Message formatting
Features
  • Flex Messages — Rich, customizable message layouts
  • Group Chat Support — Works in groups and multi-person chats
  • Rich Media — Send images, videos, audio, and files
  • Quick Replies — Suggest quick response options
  • Location Sharing — Receive and process location data
⚠️ Troubleshooting

Bot not responding?

Verify the webhook URL is correct and publicly accessible. Use the "Verify" button in LINE Developers.

Webhook verification failed?

Ensure your server returns a 200 OK status and the channel secret is correct.

Can't send messages?

Check that the channel access token is valid and hasn't expired.

For more detailed configuration options and advanced features, visit the official documentation:

docs.openclaw.ai/channels/line →

LINE Connected!

Add more channels or enhance your bot with custom skills.