LINE remains one of the most popular messaging platforms across Asia. Integrating it with MaviBot gives you access to millions of users and enables automated customer communication through one of the region's leading messengers.
This guide walks you through the entire setup process—from creating your LINE account to connecting it with MaviBot and sending your first messages.
Connection
Before connecting LINE to MaviBot, complete the following setup steps:
- Create a LINE Business ID in the LINE Business Center.
- Create a LINE Official Account using the LINE Official Account Manager.
- Enable the Messaging API in your Official Account settings.

After enabling the Messaging API, open Response settings and make sure that Webhooks are enabled.

Important
Webhooks must be enabled. Otherwise, LINE will not send events to MaviBot.
Channel ID and Channel Secret
Open the Messaging API section in your LINE Official Account.
There you will find the two values required to connect your bot:
- Channel ID
- Channel Secret

These credentials are required when connecting LINE to MaviBot.
Connect LINE to MaviBot
- Open the Messengers section in MaviBot.
- Select LINE.
- Paste your Channel ID and Channel Secret.
- Click Done.

If the credentials are valid, the integration will be activated immediately.
Client variables
When a user sends a message, MaviBot automatically stores the following client variables.
| Variable | Description |
|---|---|
line_source_type |
Conversation type. Possible values: user (private chat), group (group chat), room (legacy group chat). |
line_quote_token |
Token used for replying to a specific message. MaviBot always stores the token from the latest incoming message. Can be used with line_send_message(). |
line_request |
Full webhook payload. Available only when the save_webhook variable is enabled. |
latitude |
Latitude received when the user shares a location. |
longitude |
Longitude received when the user shares a location. |
line_address |
Human-readable address received together with the shared location. |
These variables allow you to create flexible chatbot flows and personalize responses.

LINE callbacks
MaviBot receives the following callbacks from LINE.
| Callback | Description |
|---|---|
line_follow |
User added the bot as a friend or unblocked it. |
line_sticker |
User sent a sticker. |
client_unsubscribed |
User blocked the bot. |
line_join |
Bot was added to a group chat. |
line_leave |
Bot left a group chat. |
line_memberJoined |
A new member joined the group chat. |
line_memberLeft |
A member left the group chat. |
These callbacks can be used for automation, triggers, welcome messages, notifications, and logging.

Attachments
LINE supports the following attachment types:
- Images
- Videos
- Audio and voice messages

Please note
LINE allows a maximum of 5 objects in a single message.
Each of the following counts as one object:
- one media attachment;
- the message text;
- a button set.
If your message contains text, media, and buttons, make sure the total number of objects does not exceed five.
Buttons
Keyboard (quick replies)
Displayed above the message input field.
- Maximum: 13 buttons

Buttons in text
Displayed underneath the message text.
- Maximum: 4 buttons
- Maximum message length: 160 characters

Available button types
- Default
- Callback
- Request geolocation (Quick Reply buttons only)
Connecting the bot to a group
To allow your bot to be added to group chats, enable this option in the LINE Official Account Manager.
