Connect LINE
LINE needs a long-lived channel access token and the channel secret, then your callback URL with Use webhook switched on.
Browse topics
What it is
LINE is the default messaging app in Japan, Taiwan, and Thailand, and a LINE Official Account is how businesses there are expected to be reachable. Connecting it lets your chatbot answer people who message that account.
The card asks for two values, both from a Messaging API channel in the LINE Developers console: a Channel access token and a Channel secret. The access token lets Agentency send replies; the channel secret lets Agentency verify that each incoming message really came from LINE.
LINE goes Connected as soon as the token checks out, but it will not receive anything until you paste Agentency's Callback URL into the channel's Webhook URL field and switch Use webhook on. Both halves are required, and the second one is easy to miss.
When you would use it
Use this when your customers are in a market where LINE is the normal way to contact a business, or when you already run a LINE Official Account and its inbox is busier than your team can keep up with.
Where to find it
Open Dashboard → Chatbots → your chatbot → Integrations → Messaging and click the LINE card.
Steps
- In the LINE Developers console, create a provider if you do not have one, then create a Messaging API channel. The drawer's View official setup guide link goes to LINE's own walkthrough.
- On the Messaging API tab, issue a long-lived channel access token and copy it. Short-lived tokens will connect and then expire, taking the channel down with them.
- On the Basic settings tab, copy the Channel secret.
- In Agentency, open Integrations → Messaging → LINE, paste both values, and press Connect. Agentency checks the token against LINE and reads back your account's display name before saving.
- Copy the Callback URL from the panel that appears.
- Back in the LINE console, paste it into Webhook URL on the Messaging API tab, save, and turn Use webhook on.
- In the LINE Official Account Manager, turn the built-in auto-reply and greeting responses off. Left on, LINE's canned replies answer first and your chatbot looks broken or duplicated.
- Add your Official Account as a friend on your phone, send it a question, and confirm the answer.
- Check the thread in Conversations.
What you will see
The connect form shows four numbered steps and the official-guide link. LINE has no extra note callout — the steps are the whole story.
Once connected, the badge reads Connected, the panel shows Connected as followed by your Official Account's display name, and the warning panel One last step shows the callback URL with a copy button. Lifetime message and user counts sit alongside. Test connection re-checks the stored token with LINE; Disconnect removes the connection.
How replies behave
Agentency answers through LINE's push messaging rather than by replying to the original message. The practical effects are worth knowing:
- The answer arrives as a new message from your Official Account, a moment after the question. This is expected, not a fault.
- Long answers are split into several messages, since LINE caps a single message.
- Questions longer than about 2,000 characters are trimmed before the chatbot reads them.
- Stickers, images, and voice messages get a short reply saying the chatbot reads text only. Stickers are common on LINE, so expect to see this.
Each answer spends message credits at your chatbot's live model rate (1X = one credit; see Message credits). LINE may apply its own message allowances on your Official Account plan; that is between you and LINE.
Limits and plan notes
LINE needs a plan with integrations, messaging enabled for this deployment, an Active chatbot, and a free slot under the connected-app cap on the Connected channels card. See Messaging channels availability.
Both values are stored encrypted and never shown again. Reconnecting replaces them without using a second slot. Disconnecting stops replies immediately and clears the credentials, but the Webhook URL stays in your LINE channel — clear it or switch Use webhook off if you are finished.
One Messaging API channel points at one webhook address, so connecting here takes over from any other tool that channel was wired to.
Common problems
Connected here, but LINE messages go unanswered.
Check three things in the LINE console, in this order: the Webhook URL matches the callback URL in the drawer; Use webhook is switched on; and the chatbot is Active in Agentency. The switch is the usual culprit — the URL saves happily while the toggle stays off.
LINE answers with a canned message instead of my chatbot.
The Official Account's auto-reply or greeting messages are still enabled. Turn them off in the LINE Official Account Manager.
Connect is rejected as invalid credentials.
Either the channel access token is wrong or expired, or you pasted the channel secret into the token field. Issue a fresh long-lived token on the Messaging API tab and try again.
It worked, then stopped a while later.
A short-lived token expired. Issue a long-lived one and press Reconnect.
Messages arrive in Conversations but the customer sees nothing.
That points at the access token rather than the webhook: inbound is working and outbound is failing. Reconnect with a current token, then use Test connection.
Everything is verified and it still says nothing.
Confirm the chatbot has knowledge to answer from — see Chatbot readiness — and that you are not out of credits.
Common questions
Why does nothing arrive when the card says Connected?
Either the Webhook URL is missing in the LINE console or Use webhook is still switched off. Both are required.
LINE replies with a canned message instead of my chatbot.
The Official Account's auto-reply or greeting is still enabled. Turn both off in the LINE Official Account Manager.
Which token should I issue?
The long-lived channel access token on the Messaging API tab. A short-lived one expires and takes the channel down with it.
Why does the answer arrive as a new message?
Answers are sent as push messages, because LINE's reply window closes before the chatbot has composed its answer.
Are stickers answered?
No. Stickers, images, and voice notes get a short note saying the chatbot can only read text.
Was this article helpful?
Related articles
Connect Viber
Viber needs one auth token and nothing else. Agentency registers delivery, so the channel is live once the token is accepted.
Connect WeChat
WeChat takes the App ID and App secret of your Official Account, then verifies the moment you enable the server configuration.
Other messaging apps
Ten apps share one grid, one connected-app cap, and three post-save patterns. Pick a platform here, then follow its own guide.
Messaging channels availability
Three conditions decide whether a messaging app can connect: your plan, the deployment rollout, and the platform itself.
Ready to try it on your own content?
Create a free workspace, add a document, and ask the questions your team is tired of answering.