Line

Introduction

Line is one of the world’s most popular instant messaging platforms, used by millions of engaged users. Through LINE, brands can easily engage their customers with rich messaging.

MoEngage <> Line

MoEngage and Line integration allows you to leverage advanced segmentation, predictive capabilities, personalization, and triggering features to message your users in Line.

Integration

library_add_check

Prerequisites

  • Line business account: To use this integration, you must have an official Line business account. When sending Line messages, your messages are associated with your Line official account, resulting in users seeing your account name and page.
  • Messaging API channel: When enabling the messaging API in the Line official account manager, a messaging API channel is created. You can use this channel to communicate with your customers.
  • Channel access token: The channel access token allows you to send messages to users who have added your Line official account as a friend. You can find it in the Line Developer Console under the Messaging API tab.
  • Line user IDs: To send messages on LINE, you need users’ Line IDs (which are different from users’ usernames). After a user adds your Line official account as a friend, you can access the user’s Line ID through Line’s Users API.

Line allows you to send promotional and non-promotional messages to users, provided your brand has secured their consent. To send to your users, one of the following conditions must be fulfilled:

  • Users who have added your Line official account as a friend
  • Group chats or multi-person chats in which your Line official account has been joined
  • Users who have sent a message to your Line official Account within 7 days in the one-to-one chat (*)

Step 1: Collect User Line IDs

To send messages in Line, you must collect your users’ Line IDs to consistently identify and interact with them. Line IDs are not the same as the user’s Line  usernames. Line IDs are generated by Line and can be used when interacting with Line APIs.

You can obtain Line IDs using the Line User ID API. This endpoint returns a list of Line IDs for all users who have added your Line official account as a friend or sent your account a message and have not blocked you.

When making a GET request to the endpoint https://api.line.me/v2/bot/followers/ids, you will get the followers' Line IDs.

Step 2: Save the User's Line ID on MoEngage

After obtaining a list of Line IDs, you must add them to MoEngage as a line_id, a custom-tracked user attribute or property. You can do one of the following:

Step 3: Integrate Line with MoEngage

To integrate Line with MoEngage, perform the following steps:

  1. On the left navigation menu in the MoEngage dashboard, click App marketplace.
  2. On the App Marketplace page, search for Line.
  3. Click the Line tile.
  4. On the Line page, go to the Integrate tab and click + Add connection.
  5. Enter the following details:
    Field Description
    Connection name Name of the Line connection.
    Channel Access Token

    The Channel Access Token lets you send messages to users who have added your Line official account as a friend. It is located in the Line Developer Console under the Messaging API tab.

    Screenshot 2024-11-27 at 1.45.34 PM (1).png

  6. Click Connect. Your Line connection is now integrated.Screenshot 2024-11-19 at 9.28.25 PM (1).pngYou can now use Line to start creating campaigns.

Step 4: Create a Campaign on MoEngage to Send a Line Message

To create a campaign on MoEngage:

  1. On the left navigation menu in the MoEngage dashboard, click Engage, and then click  Campaigns.
  2. On the All campaigns page, click + Create campaign.
  3. On the Create campaign dialog box, under Connected Apps, click Line and then click the most suitable delivery type.
  4. Under Select audience, click Filter users by.
  5. On the User property tab, select the segment of users for whom line_id exists (you can combine it with other segment criteria).
    Screen_Shot_2022-02-22_at_4.45.12_PM.png
  6. In step 2 of the Campaign Creation, select the pre-configured connectors and specify the content you want to send out. Enter the following details:
    Field Description
    Connector Select a pre-configured connector you want to use.
    Connections Select the connection you added to the MoEngage App marketplace.
    LINE ID Enter the LINE ID. It is a unique identifier assigned to each user on the Line messaging platform. You can also use personalization here.
    Message Enter the message content you want to send. You can also use personalization here.

  7. Your campaign is now ready to be tested and sent. Using the Test functionality, you can also test your connector configuration. 

    If your test user successfully receives the message, your setup is ready.
  8. Publish the campaign.

Send a Line Message to the Groups or Rooms

Perform the following steps to send campaigns to your LINE group or room:

  1. Create a new user in MoEngage to message a group or a room. Ensure the LINE ID here is your group ID or room ID. For more information on these IDs, refer here.
  2. Select the user by creating a segment for it. Ensure only one user is included in the segment. When multiple users are selected for the campaign, the message gets sent to the group or room many times.
  3. In Step 2 of Create Campaign, enter the LINE ID of your group or room. You can also use personalization here.

Campaign Analytics

MoEngage campaigns provide powerful analytics that allow you to analyze your campaign performances. Each channel in MoEngage provides in-depth metrics that help you quantify your campaign goals. For more information on the MoEngage Analytics functionalities refer to Campaign Analytics.

By default, we provide the following metrics for LINE campaigns:

  • Attempted: After removing the users who breached the frequency capping (FC), is calculated as the number of users who qualified for the LINE campaigns and to whom we attempted to send messages.
  • Failed: Number of users for whom Line did not send any message or the users for whom we failed to find any value against the user or event attributes used in the campaign.
  • Successfully sent: The campaign is marked as successful when LINE APIs accept the request to send the message to users/groups/rooms (with a 200 status code). For more information on LINE Message API responses, refer to their help documentation.

Previous

Next

Was this article helpful?
0 out of 0 found this helpful

How can we improve this article?