# News: Articles for #Messaging API

Reminder: Notice of domain name change for certain endpoints (Domain names must be updated by October 30, 2020)

As announced on November 8, 2019, March 19, 2020, and August 12, 2020, the domain name of certain Messaging API endpoints has been changed from api.line.me to api-data.line.me.

The initial plan was to complete the transition by April 30, 2020, but was extended to October 30, 2020 based on the usage situation.

# Target endpoint

# Influence

If you are using the above endpoints, please change your domain during the transition period.

Once the transition period ends, accessing an endpoint of the old domain name will return a 404 status code.

We apologize for any inconvenience this may cause. Thank you for your understanding.

# Transition period

November 8, 2019 - October 30, 2020 14:00

[Updated] Flex Message Update 2 released

Added October 22, 2020

Flex message's play animated images feature has been temporarily disabled due to a technical issue. As of current, regardless of the value of the animated property in the image component, animated images cannot be played.

We sincerely apologize for any inconvenience this may have caused. We will notify you through this news article once the issue is fixed and the feature has been enabled again.

Flex Message Update 2 has been released for the Messaging API.

Flex Message Update 2 includes these improvements:

# Changed the maximum number of bubbles that can be included in a carousel

We changed the maximum number of bubbles that can be included as child elements of a carousel container. This table provides a side-by-side comparison of values before and after the change.

# Added more component alignment options

We added the justifyContent and alignItems properties to Flex Message box components. These properties let you specify how child elements and free space should be arranged; for example, you can choose to evenly distribute the child elements or keep them all centered.

flex-start flex-center flex-end space-between space-around space-evenly

For more information, see Arranging a box's child elements and free space in the Messaging API documentation.

# Allowed gradients to be used as a box's background image

You can use a linear gradient as the background image for a box component by setting its background.type property equal to linearGradient.

Linear gradient at 0 degrees Linear gradient at 45 degrees Linear gradient at 90 degrees

For more information, see Linear gradient backgrounds in the Messaging API documentation.

# Allowed an empty array to be specified as the value of a box's contents property

You can now specify an empty array as the value of a box component's contents property.

  • Box component

    Item Before After
    contents property Empty arrays can't be specified Empty arrays can be specified
    When would it be helpful to specify an empty array?

    When using box components for decoration like the four squares shown below, it used to be necessary to add filler components as child elements to each of the boxes. Starting with Flex Message Update 2, you only need to specify an empty array.

    offset property example 1

    Let's compare the JSON data for the yellow box component on the left before and after this change:

    • Before
    {
        "type": "box",
        "layout": "vertical",
        "contents": [
            {
            "type": "filler"
            }
        ],
        "width": "30px",
        "height": "30px",
        "backgroundColor": "#FFFF7F"
    }
    
    • After
    {
        "type": "box",
        "layout": "vertical",
        "contents": [],
        "width": "30px",
        "height": "30px",
        "backgroundColor": "#FFFF7F"
    }
    

# Added support for animated images

Added October 22, 2020

Flex Message's play animated images feature has been temporarily disabled due to a technical issue. As of current, regardless of the value of the animated property in the image component, animated images cannot be played.

We sincerely apologize for any inconvenience this may have caused. We will notify you through this news article once the issue is fixed and the feature has been enabled again.

It is now possible to specify animated images (APNG) in the image component of Flex Message.

For more information, see the Image component in the Messaging API Reference.

# Changed how sizes are specified

We changed how you specify a component's size. This table provides a side-by-side comparison of values before and after the change.

# Allowed text to automatically shrink to fit a component's width

We added the adjustMode property to text and button components. If you specify a value of shrink-to-fit for this adjustMode property, the text's font size will automatically shrink to fit the width of the component.

Automatically shrink fonts to fit

For more information, see the Text and Button components in the Messaging API reference.

# Spacer has been discontinued

The spacer component, which was previously deprecated, has been discontinued. We recommend setting the padding of the box without using a spacer from now on.

For more information, see Box padding in the Messaging API documentation.

# Added support for Update 2 in the Flex Message Simulator

Flex Message Simulator now supports the new properties and objects introduced in Flex Message Update 2, as well.

Using Flex Message Simulator, you can easily generate JSON data for Flex Messages and visually examine how they're laid out.

Caveats

Flex Message Simulator doesn't make any guarantees about the layout of a Flex Message. A Flex Message's appearance may vary from one device to the next. In addition to the version of the LINE app being used, a device's operating system, resolution, language settings, and fonts may affect how messages are rendered.

TLS 1.0 and TLS 1.1 support by the webhook notification source will be discontinued at the end of January 2021

The following updates are planned for the LINE Platform, the source of webhook notifications for the Messaging API.

If you are using a webhook, please confirm communication from the new environment during the transition period.

What is a webhook?

A webhook is one of the features of LINE's Messaging API. It's a system in which the LINE Platform notifies the bot server of the provider (corporate or developer) of events such as adding friends and sending messages via HTTPS POST requests.

You can specify the bot server to which you want to be notified of webhooks by specifying the webhook URL in the LINE Developers Console. For more information on webhooks, see Receiving messages (webhooks) in the Messaging API documentation.

# Supported SSL/TLS protocol versions

We no longer support TLS 1.0 and TLS 1.1.

See the table below for the differences before and after the transition.

Protocol version Before transition After transition
TLS 1.3
TLS 1.2
TLS 1.1
TLS 1.0
SSL 3.0
SSL 2.0

# Supported HTTP versions

See the table below for differences before and after the transition.

HTTP version Before transition After transition
HTTP/2
HTTP/1.1
HTTP/1.0

# Supported root certification authorities

Webhook URLs (the bot server to which webhooks are notified) must be configured with an SSL/TLS certificate issued by a trusted certification authority. Self-signed certificates aren't allowed.

See the table below for differences before and after the transition.

Before transition After transition
Available SSL/TLS Certificates An SSL/TLS certificate issued by a "Certificate authority trusted by LINE" SSL/TLS certificates issued by a root certification authority that's widely trusted by most browsers

The "Certificate authority trusted by LINE" list will be removed at the end of the transition period.

# Transition period

October 6, 2020 - January 31, 2021 JST (GMT+9)

# Impact

If you're using Messaging API webhooks, we recommend that you use one of the following methods during the migration period to verify that the new LINE Platform can be used to communicate with the bot server.

# Verification method 1: Verify with an endpoint for webhook URL validation

Please verify the connection by using the endpoint for webhook URL test.

Return status code 200 for the communication request
  • The LINE Platform sends an HTTP POST request that doesn't include a webhook event to the webhook URL (bot server) to confirm communication. Design your bot server to return status code 200.

    Example HTTP POST request without a webhook event:

    {
        "destination": "xxxxxxxxxx",
        "events": []
    }
    

# Verification method 2: Use the webhook URL's "Verify" button in the LINE Developers Console

In the LINE Developers Console, click the Webhook URL's "Verify" button to perform the verification.

send target

The webhook URL's "Verify" button will be available soon

The Webhook URL's "Verify" button will soon be able to confirm communication from the environment after migration.

We will inform you when it becomes available.

LINE will continue to improve the quality of its services to prevent future outages. Thank you for your understanding.

Messaging API update for October 2020

We added new endpoints to the Messaging API.

This is a summary of each new endpoint. For details, see each endpoint in the Messaging API reference.

# Get bot info

Gets basic information about the bot, such as:

  • Bot's user ID
  • Bot's basic ID
  • Bot's premium ID
  • Bot's display name
  • Profile image URL
  • Bot response mode ("Chat" or "Bot")
  • If the bot is set to automatically read messages

For more information, see Get bot info in the Messaging API reference.

# Get webhook endpoint information

Gets this information about the webhook endpoint:

  • Webhook URL
  • Webhook usage status (enabled or disabled)

For more information, see Get webhook endpoint information in the Messaging API reference.

# Set webhook endpoint URL

Sets the webhook endpoint URL. It may take up to 1 minute for changes to take place due to caching.

For more information, see Set webhook endpoint URL in the Messaging API reference.

# Test webhook endpoint

Checks if the configured webhook endpoint can receive a test webhook event.

For more information, see Test webhook endpoint in the Messaging API reference.

Redelivery object has been added to the criteria for narrowing down the narrowcast message target

Redelivery object has been added to the criteria for narrowing down the narrowcast message target in the Messaging API. Using the redelivery object, you can send a message conditioned on users who have previously received a narrowcast message.

# Redelivery object was added

Narrowcast messages are usually sent to all users who added a specific LINE Official Account as a friend. However, by specifying the demographic filter object when you send a narrowcast message, you can narrow down the target of your message based on certain conditions.

narrowcast message

To narrow down the target by a recipient object, in addition to the existing audience object, you can now specify the redelivery object.

By specifying the request ID in the redelivery object, you can send a message to users who have previously received a narrowcast message.

Conditions for specifying the request ID

The request ID specified in the requestId property must satisfy all of these conditions:

  • The request ID was issued by the delivering a narrowcast message
  • The narrowcast message was delivered within the past seven days
  • The delivery process is completed (The value of the phase property is succeeded in the response of the Get narrowcast message status endpoint)

For more information on redelivery object, see:

# Specify the target using the operator object (AND, OR, NOT)

Similar to existing audience objects, you can specify the target based on complex conditions using operators (AND, OR, NOT) with the redelivery object.

Below is an example of a recipient object with users with a specific chat tag and (AND) users who received a narrowcast message previously delivered set as the target:

send target

"recipient": {
    "type": "operator",
    "and": [
        {
            "type": "audience",
            "audienceGroupId": 5614991017776
        },
        {
            "type": "redelivery",
            "requestId": "5b59509c-c57b-11e9-aa8c-2a2ae2dbcce4"
        }
    ]
}

For more information about narrowing down the narrowcast message target, see these:

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. All functions provided by the Messaging API may have been affected by this outage.

The issue has now been resolved. We apologize for any inconvenience that this may have caused.

# Date and time of outage

Date: September 15, 2020 Time: 11:37-11:53 (GMT+9)

# Cause

Issue with our servers

# Details

The Messaging API call returned a status code 403 even if the request was correct.

# Affected services

All Messaging API endpoints (https://api.line.me/v2/bot/*)

LINE will continue to improve the quality of its services to prevent future outages. Thank you for your understanding.

Messaging API update for September 2020

We've added new features to the Messaging API.

These are the features added in this update:

# Narrowcast messages can now be sent within the maximum number of messages that can be delivered

The limit.upToRemainingQuota property has been added to narrowcast messages.

By specifying this property when delivering a narrowcast message, you can send the message within the maximum number of messages that can be delivered.

What is the benefit of using the limit.upToRemainingQuota property?

If you try to send narrowcast messages that exceed the maximum number of messages that can be delivered, the delivery will fail.

For this reason, it was necessary to specify the maximum number of messages to send before sending narrowcast messages.

For example, if you can send up to 750 messages in a month, you'll send them with the limit.max property set to 750.

However, if you set the limit.upToRemainingQuota property to true, even if the number of messages to be sent exceeds the maximum number of messages that can be sent, the message won't fail and will automatically be sent within the limit.

The advantage of this property is that it automatically delivers within the maximum number of targets without having to check how many messages you can still send.

The distribution targets will be randomly selected.

For more information, see the limit.upToRemainingQuota property in the Send narrowcast message section of the Messaging API reference.

For more information on the maximum number of messages that can be delivered, see Messaging API pricing.

# The maximum size of JSON data that defines a bubble is 30 KB

The maximum size of JSON data that defines a bubble in Flex Messages has changed.

Subject Before change After change
Maximum size 10KB 30KB

For more information about Flex Message bubble containers, see Bubble in the Messaging API reference.

Reminder: Notice of domain name change for certain endpoints (Domain names must be updated by October 30, 2020)

As announced on November 8, 2019 and March 19, 2020, the domain name of certain Messaging API endpoints has been changed from api.line.me to api-data.line.me.

The initial plan was to complete the transition by April 30, 2020, but we extended the transition period to October 30, 2020, based on the usage situation.

# Target endpoint

# Influence

If you are using the above endpoints, please change your domain during the transition period.

Once the transition period ends, accessing an endpoint of the old domain name will return a 404 status code.

We apologize for any inconvenience this may cause. Thank you for your understanding.

# Transition period

November 8, 2019 - October 30, 2020 14:00

The endpoint to get statistics is now available in Indonesia (ID)

The endpoint of the Messaging API to get statistics is now available in Indonesia (ID).

Before, LINE Official Accounts created by Indonesian (ID) users weren't able to obtain this statistic. This update has removed this restriction.

[Updated] Messaging API update for August 2020

We've added new webhook events and an API endpoint to the Messaging API.

These are the features added in this update:

# Unsend event has been added

In addition to existing webhook events, such as join, leave, and send messages, a new "Unsend event" has been added, which indicates that the message has been cancelled.

# Video viewing complete event has been added

A new "Video viewing complete event" has been added. This event occurs when a user finishes watching a video with a trackingId property for video identification.

# The audiences property is now optional instead of required for a certain endpoint

The audiences property has been changed from required to optional for the following endpoint.

This spec change allows you to prepare an audience by creating an audience with no recipient specified first, and then adding user IDs or IFAs to the audience later.

# Recipients of an audience can be now specified by file

You can now specify the recipients of an audience by file.

Get all valid channel access tokens v2.1 endpoint and content removed

As announced on July 01, 2020, the Get all valid channel access tokens v2.1 API endpoint for Messaging API has been removed. We've also removed all content related to this endpoint from this site.

When Issuing the channel access token v2.1, a unique key ID (key_id) paired with the channel access token is also returned. You can use the newly added Get all valid channel access token key IDs v2.1 endpoint to get an array of key IDs paired with the currently valid channel access tokens. You can verify the validity of channel access tokens by comparing the returned key IDs with pairs of channel access tokens and their IDs stored in a database.

Learn more about Issue channel access token v2.1 in the Messaging API documentation.

Notice of failure of some analytics APIs (Partially resolved)

These problems occurred in the Messaging API, but it has been partially resolved. We apologize for any inconvenience caused to our customers.

# Date and time of outage

Issue 1: July 21, 2020 around 7:00 - 17:00 (GMT+9)

Issue 2: July 16, 2020 onwards (GMT+9)

# Situation

# (Resolved) Issue 1

When premium and verified account users called the Get number of followers API endpoint, the endpoint returned an incorrect number of followers for July 21, 2020.

This issue is now resolved and you can get the correct number for July 21, 2020.

# (Limitation) Issue 2

Some LINE Official Accounts (less than 0.5%) that used the Get number of followers API endpoint from July 16, 2020 to July 20, 2020 may have gotten incorrect numbers returned for followers, targetedReaches, and blocks.

The affected LINE Official Accounts may have had these issues:

  • If you added friends during this period, they aren't added to the total amount of friends.

  • The number of followers during this period is returned with less than the actual value.

For issue 2, the correct value can't be restored.

Note

Neither issue has any effect on the total message delivery count.

We will continue to improve the quality of the services we provide to our developers and we greatly appreciate your understanding.

Notice about service outage for sending webhook events (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved but we sincerely apologize for any inconvenience that this may have caused.

# Date and time of outage

June 29, 2020 13:20 JST (GMT+9) - July 14, 2020 17:42 JST (GMT+9)

# Cause of the outage

Due to the detection of unauthorized communications in our network, we've blocked some communications as a preventive measure.

# Details

During the date and time stated above, webhook events couldn't be sent to some bot servers (Webhook URLs) using ngrok.

We will continue to improve the quality of the services we provide to our developers and we greatly appreciate your understanding.

Improved Messaging API reference and side menu

The LINE Developers site's Messaging API reference page, due to the large amount of endpoints, was long and difficult to navigate.

We received feedback about the navigation pain points developers faced while navigating the Messaging API reference page. In response, we've made these improvements to provide a better user experience.

# You only see the categories you select

All endpoints are divided into categories such as Webhooks and OAuth.

You can see the overview for each category and select Show to display the category's endpoints.

Messaging API Webhooks overview

# Side menu shows current page location

When you scroll through the page, the highlighted location on the side menu automatically reflects your current location in green.

For example, when you scroll through the page and see the "response" section under the "Webhooks" category, "response" under "Webhooks" is also highlighted in the side menu.

Webhook location on page is reflected in side menu

If you're lost on the page, you can now refer to the side menu to find your location.

Developers who use the browser's in-page search should use the built-in search function to find the endpoint. You can search endpoints by title search or full-text search.

Search for an endpoint

# Tell us your thoughts about the LINE Developers site

If you use the new Messaging API Reference and notice issues or find it difficult to use, select "Was this page helpful?" in the bottom right corner and let us know.

Feedback form title

Thanks to everyone for their valuable feedback. We read each message we receive.

We will continue to improve the quality of the services we provide to our developers. Thank you for your understanding.

Get all valid channel access tokens 2.1 is deprecated

As announced on June 22, 2020, the Get all valid channel access tokens v2.1 API endpoint is now deprecated and will be permanently removed on July 29, 2020.

If you're using this endpoint, change your bot to use the newly added Get all valid channel access token key IDs v2.1 endpoint by the specified EOL date.

Learn more about Issue channel access token v2.1 in the Messaging API documentation.

LINE's APIs now support TLS 1.3

Added July 30, 2020

For access to the APIs from outside Japan, TLS 1.3 will be available after August 4, 2020. For more information, see the news on July 30, 2020, LINE's APIs will support HTTP/2.

LINE's APIs now support TLS 1.3.

# Domain names subject to the update

  • api.line.me
  • api-data.line.me
  • access.line.me

# SSL/TLS supported protocol versions

See this table for the differences before and after the update:

Protocol version Before update After update
TLS 1.3
TLS 1.2
TLS 1.1
TLS 1.0
SSL 3.0
SSL 2.0

# Impact

If you are using any of the above APIs, please confirm that your app can communicate using the updated supported protocol versions.

# Transition period

  • For access from Japan: TLS 1.3 is available after July 1, 2020.
  • For access from outside Japan: TLS 1.3 is available after August 4, 2020.

Support for TLS 1.0 and TLS 1.1 will be discontinued in the future. The discontinuation schedule is undecided. We will make an announcement as soon as it is decided.

We will continue to improve the quality of the services we provide to our developers and we greatly appreciate your understanding.

Beacon Leave Event to be deprecated at the end of 2020

July 8, 2020

We clarified the contact information. We apologize for any inconvenience this may have caused you.

As announced previously, the leave event of Beacon Event, will be deprecated. Please refer to the following schedule:

Schedule Description
End of 2020 Leave event will be deprecated.
Early January of 2021 Webhook transmission will cease
Tip

We will continue supporting other Beacon events (enterevent, bannerevent, or stayevent).

# Impact

Please adjust your service to use the stay event instead of the leave event for detecting when users exit the reception range of Beacon.

beacon.type Description
leave [To be deprecated at the end of 2020] User left the reception range of Beacon.
stay User is currently within the reception range of Beacon.
This event is sent repeatedly at a minimum interval of 10 seconds.

If you wish you use the stay event, contact your sales representative or contact our Sales partners (opens new window).

We apologize for any inconvenience the deprecation of the leave event may have caused. LINE will continue to improve the quality of its services to its customers. Thank you for your understanding.

已新增識別 Channel Access Token 的 Key ID

基於資安的原因,Get all valid channel access tokens v2.1 的 Endpoint 會回傳重新加密後的 channel access tokens。

藉由這次的更新,在產生 channel access token v2.1 時會回傳一個對應 token 的 unique key ID (key_id)。您可以使用新的 Get all valid channel access token key IDs v2.1 的 Endpoint 來識別對應的 channel access tokens。

預計會棄用的 Endpoint

由於此次的更新,我們預計於七月上旬建議勿用 Get all valid channel access tokens v2.1 的 Endpoint。如果您正在使用此 Endpoint,請將您的 Bot 修改為新的 Get all valid channel access token key IDs v2.1 的 Endpoint。

更多關於發行channel access token v2.1的內容,請參考Messaging API技術文件。

Messaging API更新(2020年6月)

Messaging API 追加了新的 endpoint。以下為本次更新的功能:

Endpoint

新功能的敘述如下。若需了解更多細節,請查閱 Messaging API reference 中各個新功能的說明。

# 取得群組的資訊

當你的 LINE 官方帳號是群組的其中一員時,可取得的群組 ID、群組名稱以及群組圖示連結。

關於更多資訊,請查看Messaging API reference中的取得群組的資訊

# 取得群組裡的成員總數

取得群組中的成員總數。即使其中的成員尚未將LINE官方帳號加為好友,或是已將LINE官方帳號封鎖,您都可以取得群組成員的總數。

關於更多資訊,請查看Messaging API reference中的取得群組裡的成員總數

# 取得聊天室的成員總數

取得聊天室的成員總數。即使其中的成員未將LINE官方帳號加為好友,或是已將LINE官方帳號封鎖,您都可以取得聊天室成員的總數。

關於更多資訊,請查看Messaging API reference中的取得聊天室的成員總數

Flex Message Simulator 的教學指南

我們發布了第一個關於使用Flex Message Simulator (opens new window)的教學指南。

遵循教學指南,您將能獲得關於使用Flex Message Simulator的實際操作經驗與知識。並且,在教學指南的最後,您將會使用Flex Message製作出如下方的出數位名片:

Final Output

我們鼓勵您把握這次機會去學習如何使用Flex Message Simulator並創造出屬於您獨特的 Flex Message。

Messaging API更新(2020年5月)

我們對Messaging API做了幾項改善。

# 訊息的字數限制與影音檔案使用條件的調整

目前已調整針對文字訊息的字數限制以及影音檔案使用條件。請參考下方表格比對變更前後的差異。

  • 文字訊息

    項目 變更前 變更後
    最大字數 2000 5000
  • 圖文選單(Richmenu)物件 (圖片)

    項目 變更前 變更後
    圖片尺寸
    (寬度 x 高度)
    2500px × 1686px
    2500px × 843px
    1200px × 810px
    1200px × 405px
    800px × 540px
    800px × 270px
    800px以上 x 2500px以下 *

    * 寬度/長度的比例應至少為1.45。

  • 圖片訊息 (圖片)

    項目 變更前 變更後
    檔案格式 JPEG JPG, JPEG, PNG
    圖片尺寸上限 4096px × 4096px 無限制
    檔案大小上限 1MB 10MB
  • 影片訊息 (影片)

    項目 變更前 變更後
    長度上限 1分鐘 無限制
    檔案大小上限 10MB 200MB
  • 語音訊息 (語音)

    項目 變更前 變更後
    長度上限 1分鐘 無限制
    檔案大小上限 10MB 200MB
  • Imagemap訊息 (圖片)

    項目 變更前 變更後
    檔案大小上限 1MB 10MB
  • Imagemap訊息 (影片)

    項目 變更前 變更後
    長度上限 1分鐘 無限制
    檔案大小上限 10MB 200MB
  • 圖片訊息 / 影片訊息 / Imagemap訊息 (預覽圖片)

    項目 變更前 變更後
    檔案格式 JPEG JPEG, PNG
    圖片尺寸上限 240px x 240px 無限制

# 從webhook event的message物件中取得LINE表情貼資訊

如果使用者傳送的文字中包含LINE表情貼,則在webhook接收到文字訊息物件時會包含emojis的屬性,相關資訊被歸納在LINE emoji物件當中。

LINE表情貼種類是由productIdemojiId來識別:

{
  "replyToken": "nHuyWiB7yP5Zw52FIkcQobQuGDXCTA",
  "type": "message",
  "mode": "active",
  "timestamp": 1462629479859,
  "source": {
    "type": "user",
    "userId": "U4af4980629..."
  },
  "message": {
    "id": "325708",
    "type": "text",
    "text": "Hello, world! (love)",
    "emojis": [
      {
        "index": 14,
        "length": 6,
        "productId": "5ac1bfd5040ab15980c9b435",
        "emojiId": "001"
      }
    ]
  }
}

更多細節請參考Messaging API reference中的Text部分。

# 安全地重新呼叫已失敗的API請求

如果在使用Messaging API傳送訊息時出現錯誤,或是請求超時,您將無法得知訊息是否有正確地傳給使用者。而重新發送相同請求時,若第一次的請求已成功傳送,將可能導致使用者接收到同樣的訊息兩次。

您可以將retry key(X-Line-Retry-Key)追加至HTTP Header來安全地重新發送相同的請求。

Retry key的值是由十六進制隨機產生的UUID(例如: 123e4567-e89b-12d3-a456-426614174000)。無論API請求時使用多少次含有相同UUID的retry key,終將只會有一次請求被接受,避免重複執行相同請求。而透過retry key,能使API請求在retry時能夠更安全地執行。

curl -v -X POST https://api.line.me/v2/bot/message/push \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer {CHANNEL_ACCESS_TOKEN}' \
-H 'X-Line-Retry-Key: {UUID}' \
-d '{
    "messages": [
        {
            "type": "text",
            "text": "Hello, user"
        }
    ]
}'

更多資訊請參考重新嘗試失敗的API請求

「受眾群體」(Audience)與「分析」(Insight)的部分API恢復通知

我們在2020年4月22日發布了[更新] 關於Audience和Insight在一些集成式API中服務故障的問題。上述API現已可在受限制的狀況下使用。

請留意相關訊息的傳送日期與時間,關於建立曝光再行銷的受眾群可能會受限制,以及統計資料可能會有相關回傳值。

  • 訊息發送的時間(JST): ~2020年3月29日,23:59:59
    狀態:現已無限制。

    • 受眾群體已可以創建。
    • 統計資料已可正常回傳。

  • 訊息發送的時間(JST): 2020年3月30日 00:00:00~2020年4月29日23:59:59
    狀態:有限制。

    • 受眾群體無法創建。
    • 統計資料中的 overview.uniqueImpressionmessages[].impression會有相關回傳值。

  • 訊息發送的時間(JST): 2020年4月30日 00:00:00~
    狀態:有限制。

    • 受眾群體已可以創建。但是,如果有使用者在這段時間內使用受限制的LINE版本開啟訊息,該使用者將無法接收到使用受眾群體所送出的新訊息。
    • 統計資料已可正常回傳。但是,統計資料中將不包含使用者在這段時間內利用受限制的LINE版本開啟訊息的次數。

關於更多資訊,請參考下方頁面:

我們將會持續改善我們向各位發開者提供的服務品質,並對於您的理解致上真誠的感謝。

Messaging API服務中斷通知 (已修復)

我們必須通知您關於Messaging API近期發生的服務中斷問題。 所有由Messaging API提供的功能皆有可能受到影響。

這項問題目前已解決。Messaging API自下方的發生時間後已恢復正常運作。對於遲來的通知與此問題所造成的不便,我們致上誠摯的歉意。

# 發生時間

日期: 2020年4月24日

時間: 14:41-17:46 (GMT+9)

# 原因

網路故障

# 影響範圍

所有由Messaging API提供的功能皆有可能受到此問題影響。

LINE將會持續改善我們的服務品質以避免未來發生相關問題。感謝您的諒解。

[更新] 關於 Audience 和 Insight 在一些集成式 API 中服務故障的問題

2020年5月1日更新

在 2020 年 4 月 22 日我們回報了此 API,目前已可在有限制的狀況下使用它。

關於更多訊息,請參考下方頁面:

Messaging API 發生了下列故障的問題。對此造成您的不便,我們致上誠摯的歉意。

# 發生時間

日期: 2020 年 4 月 13 日

時間:約 15:30~ (GMT+9) (持續中)

# 細節

在上述時間發生之後,無法準確計算出曝光再行銷的受眾群的曝光量。

因此我們暫時限制了部分功能的使用。整體來說,我們將會採取以下行動:

我們正積極的調查與修復此問題。

LINE 將會持續改善我們的服務品質以避免未來發生相關問題。感謝您的諒解。

【更新】Messaging API升級(2020年4月)

2020年4月16日更新

2020年4月14日通知的下列Property名稱已變更。

變更前 變更後
sticon emojis
sticon.sticonId emojis.emojiId

Messaging API進行了下列改善。

# 利用文字訊息傳送LINE表情貼

利用Messaging API傳送文字訊息之際,可傳送Unicode定義的表情貼、LINE獨家定義的表情貼(不建議),現在更可傳送LINE表情貼了。

LINE表情貼以productIdemojiId指定。

// 含有LINE表情貼的文字訊息示例
{
    "type": "text",
    "text": "Look at this: $ It's a LINE emoji!",
    "emojis": [
        {
            "index": 14,
            "productId": "5ac1bfd5040ab15980c9b435",
            "emojiId": "001"
        }
    ]
}

詳情請參閱《Messaging API reference》的「文字訊息」。

# 取得用戶語言

取得個人資料端點,既存的用戶個人資料資訊會和languageProperty一起退回。

languageProperty僅會在下列任一情況下退回。

  • 用戶使用在日本建立的LINE帳號,且同意LINE 8.0.0版本之後的隱私權政策
  • 用戶使用在台灣、泰國,或印尼建立的LINE帳號,且同意LINE 8.9.0版本之後的隱私權政策

# Multicast的收訊人數限制已刪除

傳送Multicast訊息 端點原本有限制1分鐘的收訊人數,此限制已在今天刪除。其他速度限制將繼續適用。關於變更前的限制和變更後的差異,請參閱下表。

Bot種類 變更前 變更後
LINE官方帳號綁定的Bot 100,000 Request/分
1,700 Request/秒(※)
2,000,000 收訊人/分
100,000 Request/分
1,700 Request/秒(※)
LINE@帳號綁定的Bot 10,000 Request/分
170 Request/秒(※)
200,000 收訊人/分
10,000 Request/分
170 Request/秒(※)

※1秒單位的速度限制為大量傳送時的大概速度。

不僅如此,傳送Multicast訊息時,最多可指定500筆用戶ID(原為150筆,增加至500筆)。

詳情請參閱《Messaging API reference》的「速度制限」。

Channel Access Token v2.1已上線

Channel Access Token的最新版本已上線。新版本除了能指定Token的有效期限之外,亦可用JSON Web Token(JWT)來取代Channel Secret強化安全性。

建議您使用Channel Access Token最新版本。

JWT的生成方法

可使用任意的JWT函式庫 (opens new window),亦可自己寫Code 由Assertion Signing Key生成JWT。生成JWT是發行Channel Access Token v2.1必要的手續。

# 新追加的API

關於現在可利用的Channel Access Token種類及其不同,請參閱《Messaging API Document》的「Channel Access Token」。

新「訊息貼圖」的資源型態已新增至貼圖訊息的webhook事件

隨著LINE訊息貼圖 (可輸入客製化文字的貼圖)的推出,對用於通知貼圖訊息傳送的webhook事件,我們在其stickerResourceType屬性中新增了PER_STICKER_TEXT

如果一位LINE使用者向您的LINE官方帳號傳送了訊息貼圖,您將會收到一則包含PER_STICKER_TEXT stickerResourceType的webhook事件物件。

更多資訊請查看『Messaging API參考資料』中的貼圖

LINE Beacon已中止於多個版本的服務

March 10, 2020所通知,LINE Beacon已不再適用於LINE的下列版本:

  • 日本: LINE 8.17.0之前的任何版本
  • 台灣: LINE 9.14.0之前的任何版本
  • 泰國: LINE 9.8.0之前的任何版本
  • 印尼: LINE 9.8.0之前的任何版本 (無異動)

# 影響

以上版本的使用者無論是進入或離開LINE Beacon的發送範圍,都將無法被偵測到。

  • Webhook Beacon事件將不會傳送給bot app。
  • 該當使用者將無法看到Beacon橫幅廣告。

更多關於LINE Beacon的資訊,請查看使用Beacons

對於這項改變可能造成的不便,我們致上誠摯的歉意。我們將會持續改善LINE的服務品質。感謝您的諒解。

不建議使用LINE URL scheme 'line://'

由於LINE URL scheme line://可能會產生接管攻擊,因此不建議使用。請改用https://line.me/R/https://liff.line.me/

line://接管攻擊是指使用者在點擊line://時,其他非LINE的app可能會不顧使用者的意願自動開始執行。這項攻擊僅會在特定的情況下發生。

line://將來有可能會受到中止。如有進一步的決定,我們會在此通知。

更多關於LINE URL scheme的資訊,請查看『透過LINE URL scheme使用LINE功能』。

提醒: Endpoint 網域名稱變更通知

如同 2019 年 11 月 8 日新聞所述,部分 Messaging API endpoint 的網域名稱 (domain name) 由 api.line.me 變更為 api-data.line.me.

# 變更網域名稱的 endpoint:

# 影響

使用以上 endpoint 的開發者,請於轉換期限前變更網域名稱。

轉換期結束後,使用以上 endpoint 的舊網域名稱將會顯示 404 錯誤訊息。

如造成任何不便,敬請見諒,感謝配合。

# 轉換期間

2019 年 11 月 8 日 起至 2020 年 4 月 30 日

You can now change the icon and display name of your LINE Official Account

The push/reply API request extension of the Messaging API to change icon and display name of LINE Official Account is now generally available. This was previously an optional feature for corporate users.

As shown by a green frame, you can specify icon or display name when sending a message from LINE Official Account.

Change icon and display name

For more information, see Change icon and display name.

# Properties added to Messaging API

sender.iconUrl for specifying icon and sender.name for specifying display name have been added to Messaging API. The properties can be specified in all the message objects.

For more information about each property, see “Change icon and display name” section of the Messaging API reference documentation.

LINE Beacon no longer supported on several LINE versions from March 25, 2020

LINE Beacon will no longer be supported on the following LINE versions:

  • Japan: Any version before LINE 8.17.0
  • Taiwan: Any version before LINE 9.14.0
  • Thailand: Any version before LINE 9.8.0
  • Indonesia: Any version before LINE 9.8.0 (no change)

This change will take effect from March 25, 2020 to March 26, 2020.

# Influence

Users that use these versions of LINE will not be detected when they enter or exit the reception area of a beacon.

  • Webhook beacon events are not sent to bot apps.
  • The beacon banner is not displayed for the corresponding user.

For more information about LINE Beacon, see Using Beacons.

We apologize for any inconvenience this may have caused. LINE will continue to improve the quality of its services to its customers. Thank you for your understanding.

所有 Narrowcast 及 Audience Management 英文技術文件正式上線

介紹如何透過 Messaging API 發送 Narrowcast 訊息、管理受眾的英文技術文件,已全數上線。

最新英文文件:

之前翻譯為英文的文件 (請見新聞 2020 年 2 月 19 日):

上述 Narrowcast 及 Audience Management 功能的相關新聞:

Messaging API narrowcast 英文技術文件正式上線

介紹如何透過 Messaging API 發送 narrowcast 訊息、管理受眾的 (部分) 英文技術文件正式上線:

部份文件仍為日文,近期內將翻譯為英文:

欲查看上述 Messaging API 功能的相關新聞,請至:

受眾群體分享功能正式上線

現在,開發者可於 LINE Official Account Manager 和 LINE Ad,使用以 Messaging API 建立的受眾群體 (Audience)。

受眾群體協助更精準地將廣告訊息發送給真正感興趣的用戶,透過使用受眾群體,開發者可將訊息傳送給之前曾開啟訊息,或點擊訊息連結的用戶。

之前建立過的受眾群體,將自動顯示於 LINE Official Account Manager 和 LINE Ad 中,開發者不須更改任何設定。

如欲取得更多受眾群體相關訊息,請查看 Messaging API 技術文件中的 Using audiences

New Messaging API endpoint for sending narrowcast messages

An endpoint for sending narrowcast messages has been added to the Messaging API.

This endpoint lets you send push messages to multiple users at any time.

You can specify the recipient using certain attributes (gender, age, OS type, region, etc.) and retargeting (audience).

For more information, see Send messages to multiple users using attribute information and retargeting.

Documentation available in Japanese only. English coming soon.

[Updated] 請確認 provider 名稱正確

2020 年 1 月 9 日追加說明

本功能原訂於 2020 年 1 月 9 日上線,但因故改於 2020 年 1 月 16 日上線。

自 2020 年 1 月 16 日起,使用 Messaging API 的 LINE 官方帳號,將於用戶資料下方顯示開發者註冊的 provider 名稱。

企業 LINE 官方帳號亦可能將個人名稱註冊為 provider 名稱,請確認所註冊的名稱正確無誤。Provider 可於 LINE Developers Console 進行更改。

用戶資料

*Provider 名稱如紅框中所示

Messaging API webhook event 新增屬性 "mode"

Messaging API webhook event 新增屬性 mode

modechannel multiplexing 功能的必要屬性 (開發中)。目前,所有 webhook event 皆包含 "mode": "active"

mode 的值不會自動切換為 standby。若 channel 管理者開始使用 channel multiplexing 功能,可選擇將 mode 的值更改為 standby

如欲取得更多 mode 屬性相關訊息,請查看 Messaging API reference - webhook events 中的 Common properties 內容。

LINE Developers Console - channel statistics 資料顯示問題 (已解決)

之前由於不同系統的時差設定有異,LINE Developers Console 中 Messaging API channel Statistics 表單所顯示的部份日期,與 TSV 檔案中所顯示的不一致 (TSV 檔案可透過點選 Download as TSV 按鍵產生)。

當時此狀況僅影響日本標準時間 (JST) 以外時區的資料顯示,且不會刪除或損毀資料。

# 發生時間

2019/11/26~2019/12/18

目前,此問題已排除,開發者可重新取得正常顯示的資料。之前所造成的不便,敬請包涵!

Beacon event 新增 stay event

Messaging API beacon event 新增 stay event,可指出用戶目前位於 beacon 所涵蓋的範圍內。

如欲使用 stay event,歡迎與 LINE for Business (opens new window) 團隊聯繫。

Webhook event 新增屬性"貼圖訊息"

Webhook event 新增 stickerResourceType 屬性,開發者在收到貼圖訊息後,將可於訊息通知中取得此屬性。

開發者可透過此屬性,查看接收到的貼圖類型 (靜態貼圖、動態貼圖、動態有聲貼圖,或其他類型貼圖)。

如欲取得更多資訊,請至 Messaging API reference - Sticker 介紹。

Endpoint 網域名稱變更通知

部分 Messaging API endpoint 的網域名稱 (domain name) 由 api.line.me 變更為 api-data.line.me,本次變更不包含任何 maintenance。

# 變更網域名稱的 endpoint:

# 影響

使用以上 endpoint 的開發者,請於轉換期限前變更網域名稱。如造成任何不便,敬請見諒,感謝配合。

轉換期結束後,使用以上 endpoint 的舊網域名稱將會顯示 404 錯誤訊息。

# 轉換期間

即日起至 2020 年 4 月 30 日

Endpoint for obtaining user statistics now available in Thailand (TH)

Previously, the following Messaging API endpoint didn't allow LINE Official Accounts created in Thailand (TH) to get user activity statistics. Today, we've made it available.

This endpoint returns the same data as on the Insight tab in the LINE Official Account manager (opens new window).

最新 Messaging API endpoint 提供互動數據資料

最新 Messaging API endpoint 正式上線,提供詳細數據資料,協助開發者了解用戶與 LINE 官方帳號 (OA) 發送的訊息進行哪些互動。

此 endpoint 提供的數據資料,與 LINE Official Account manager (opens new window)Insight 表單所顯示的數據資料相同。

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved. We apologize for any inconvenience that this may have caused.

# Date and time of outage

Date: October 4, 2019

Time:

9:00-9:02 JST (GMT+9)

10:04 JST (GMT+9)

11:00-11:08 JST (GMT+9)

12:02-12:08 JST (GMT+9)

# Cause

Issue with our servers.

# Affected services

All Messaging API endpoints (https://api.line.me/v2/bot/*).

# Details

The API returned status code 500 for some requests.

LINE will continue to improve the quality of its services to prevent future outages. Thank you for your understanding.

Notice about system maintenance

We're performing system maintenance at the below time. We apologize for any inconvenience.

# Scheduled maintenance time

September 26, 2019 16:20-16:50 JST (+9 GMT)

The maintenance will only last a few seconds and will take place somewhere in this time window.

# Impact

Messaging API, LINE Login, and LIFF operations may result in errors. Specifically, the following events can occur:

  • Messaging API (https://api.line.me/v2/bot/*) returns an error with status code 500.
  • An error with status code 500 is returned when a user logs in with LINE Login or starts a LIFF app.

Try out Messaging API calls in your browser

We've added a Try button to these sections of the Messaging API reference documentation:

Clicking Try reveals a form that enables you to test the API call right then and there. You'll need to enter some required information, such as your channel access token (found in the LINE Developers Console). Depending on the call, there are also other fields to fill in.

For now, this feature is only enabled for a small number of operations. We plan to increase the number in future releases to cover more Messaging API functionality.

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved. We apologize for any inconvenience that this may have caused.

# Date and time of outage

Date: September 11, 2019 Time: 17:00–18:30 JST (GMT+9)

Date: September 12, 2019 Time: 13:00–13:30 JST (GMT+9)

# Cause

Server outage due to heavy load.

# Affected services

All Messaging API endpoints (https://api.line.me/v2/bot/*).

# Details

The API returned status code 500 for some requests. Also, the "Send reply message" endpoint (https://api.line.me/v2/bot/message/reply) returned error codes in the 400 range, even for correct requests.

LINE will continue to improve the quality of its services to prevent future outages. Thank you for your understanding.

Flex Message Simulator Update 1 (β) released

We released Flex Message Simulator Update 1 (β). This version contains sample Flex Messages with more sophisticated layouts based on the new features of Flex Message Update 1.

Limitations

We can't guarantee that the appearance of a Flex Message in Flex Message Simulator Update 1 (β) exactly matches the rendering on a target device. A single Flex Message may be rendered differently from device to device. Factors that affect rendering include OS, LINE version, screen resolution, language setting, and fonts.

Flex Message Simulator Update 1 (β)

Flex Message Update 1 examples

Flex Message Update 1 released

We've added new Flex Message properties. As a result, you can use the rich expressive power of HTML and CSS in Flex Messages. For details, see Sending Flex Messages.

Flex Message example

New Messaging API endpoints for friend statistics

We're happy to announce that we've added 3 new Messaging API endpoints that enable you to get detailed information about the friends of your LINE Official Account:

The data returned by these endpoints is the same data displayed on the Insight tab in the LINE Official Account Manager (opens new window).

We encountered problems during the planned migration of accounts from the deprecated Developer Trial plan to the new free plan, which started on June 11, 2019. The problems have now been resolved. We sincerely apologize for the inconvenience this caused.

# Date and time of outage

From: June 11, 2019
Until: June 18, 2019 14:33 JST (GMT+9)

# Cause

In Japan and Thailand, accounts that were migrated from the old Developer Trial plan to the new free plan incorrectly retained their old limit on number of friends (50).

# Details

When a user tried to befriend an account that had reached the limit of 50 friends, this error was displayed:

Sorry, the account you are trying to add cannot accept any more friends.

We have now removed the limit on the number of friends.

LINE will continue improve the quality of its services to prevent future outages. Thank you for your understanding.

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved. We apologize for any inconvenience that this may have caused.

# Date and time of outage

Date: June 14, 2019 Time: 10:35–12:19 JST (GMT+9)

# Cause

Issue with our servers.

# Affected services

All Messaging API endpoints (https://api.line.me/v2/bot/*).

# Details

The API returned status code 500 for some requests.

LINE will continue to improve the quality of its services to prevent future outages. Thank you for your understanding.

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the LINE Developers site. The issue has now been resolved. We apologize for any inconvenience that this may have caused.

# Date and time of outage

Date: June 5, 2019 Time: 14:41–15:05 JST (GMT+9)

(Most errors were solved by 14:55.)

# Cause

Issue with our servers.

# Affected services

All Messaging API endpoints (https://api.line.me/v2/bot/*) and webhook.

# Details

The API returned status code 403 or 500 error for some requests. Also, webhook events were not successfully sent.

We will continue to improve the quality of our services. Thank you for your understanding.

Changes associated with the integration of LINE@ accounts into LINE Official Accounts

With the consolidation of LINE@ account plans into LINE official plans (opens new window), we changed the functionality of the LINE Developers Console and the Messaging API as follows:

# Changes in the LINE Developers Console

# Type of created accounts

When you create a Messaging API channel in the LINE Developers Console, a LINE Official Account is created instead of a LINE@ account.

For more information, see Migration of LINE@ accounts. Existing LINE@ accounts will be migrated to LINE Official Accounts sequentially.

# Privacy policy and terms of use

Now you can set your own privacy policy and terms of use for your app in your LINE Login and Messaging API channels.

In the future, we will add links to your privacy policy and terms of use for your app in the user consent screen of LINE Login or your LINE Official Account.

# Enhanced Messaging API features

Bots associated with new or migrated LINE Official Accounts can use the following features regardless of applied plans:

Bots associated with LINE@ accounts cannot use these features depending on applied plans.

For more information, see the Messaging API reference.

Migrating your LINE@ account under the Developer Trial plan

We will consolidate the LINE@ account plans into the new LINE Official Account plans.

From April 18, 2019, when you create a Messaging API channel in the LINE Developers Console, a LINE Official Account will be created instead of a LINE@ account.

After mid-June, 2019, we will migrate the existing LINE@ accounts under the Developer Trial plan to LINE Official Accounts. The free plan will be applied to the migrated LINE Official Accounts.

Learn more from Migration of LINE Developer Trial plan (opens new window) on the LINE Engineering Blog.

Messaging API: You can configure the rich menu setting for multiple users at a time

We added endpoints for the following rich menu operations:

For more information on how to use the rich menu features, see the following pages.

Notice about service outage for Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved but we sincerely apologize for any inconvenience that this may have caused.

# Date and time of outage

  • Date: February 26, 2019
  • Time: Approximately 11:15-13:00 (GMT+9)

# Cause of the outage

Issue with our servers.

# Details

HTTP status code 500 was sometimes returned when the following API endpoints were accessed:

  • Get content API: https://api.line.me/v2/bot/message/{messageId}/content
  • Rich menu API: https://api.line.me/v2/bot/richmenu/*

We will continue to improve the quality of the services we provide to our developers and we greatly appreciate your understanding.

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved but we sincerely apologize for any inconvenience that this may have caused.

# Date and time of outage

  • Date: February 20, 2019
  • Time: Approximately 18:45-19:02 and 19:10-19:26 (GMT+9)

# Cause of the outage

Issue with our servers.

# Details

The Messaging API experienced errors with error code 403 or 500 during the outage.

We will continue to improve the quality of the services we provide to our developers and we greatly appreciate your understanding.

LINE Developers Console: We changed how to check the number of your bot's friends

We moved information related to the number of your bot's friends from the LINE Developers Console to the LINE Official Account Manager. We removed this information from the "Number of friends" tab on the "Statistics" tab of the Messaging API channels.

To view the number of your bot's friends, click the Account Manager Official Site button in the "Number of friends" tab. LINE Official Account Manager or LINE@ Manager will open according to your account plan.

To use the LINE Official Account Manager, you need separate access permission. If you cannot access these tools, please contact the tool administrators of your organization.

We will remove the "Number of friends" tab from the LINE Developers Console on March 26, 2019.

New endpoints added to Messaging API

We added new endpoints to the Messaging API. Use these endpoints to get the number of messages sent from your channel.

Learn more from these sections of the Messaging API reference:

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved but we sincerely apologize for any inconvenience that this may have caused.

# Date and time of outage

  • Date: January 12, 2019
  • Time: 16:59-18:30 (GMT+9)

# Cause of the outage

Issue with our servers.

# Details

The Messaging API experienced errors with status code 5xx for approximately one minute around 17:00 on January 12, 2019. Also, webhook events were not successfully sent until 18:30 on the same day.

We will continue to improve the quality of the services we provide to our developers and we greatly appreciate your understanding.

Specification change for the Messaging API

# The image and icon

Now you can specify any aspect ratio of images and icons within a certain range.

For more information, see the updated reference documentation below.

# URI action

Now you can set different action URLs for PC users (LINE for macOS and Windows) and smartphone users (LINE for iOS and Android).

For more information, see URI action.

[Update] Change to the imagemap message

We decided not to make the specification change of the imagemap message that we announced on November 14, 2018, for compatibility. We apologize for any inconveniences caused and appreciate your understanding.

You can continue to send imagemap messages even if you set actions in the area that does not fit the width and height of the image specified by the baseSize property.

However, the layout of such imagemap messages might be broken on the user device. We recommend setting actions within the area that fits the width and height of the image specified by the baseSize property.

New webhook events are added for the Messaging API

We have added two webhook events: Member join event and member leave event.

For more information, see the following sections:

Change to the imagemap message is scheduled

We'd like to inform you that we will change the specification of the imagemap message.

After the specification change, if the method of setting actions in imagemap messages is incorrect as below, an error occurs and you cannot send imagemap messages.

The current specification: You can send imagemap messages even if actions are set in the area that does not fit the width and height of the image specified by the baseSize property.

In this case, the layout of the imagemap displayed on the user device might be broken.

The new specification: You cannot send imagemap messages because the API request fails if actions are set in the area that does not fit the width and height of the image specified by the baseSize property.

This specification change will be released on November 27th.

Correction to documentation

There were errors in the description of the new destination property added to webhook events released yesterday. We correct it as below:

【Incorrect】The destination property includes the MID of a bot that should reeive the webhook events. The property value is a string that matches the regular expression, "u[0-9a-f]{32}".

【Correct】The destination property includes the user ID of a bot that should reeive the webhook events. The property value is a string that matches the regular expression, "U[0-9a-f]{32}".

For more information, see Request body.

Specification change for the Messaging API

# You can play videos in imagemap messages

Now you can play videos in imagemap messages.

For more information, see Imagemap message.

Note that this change doesn't include the validation of action areas of imagemap messages announced on October 24. We will inform you once we decide on our schedule.

# New properties are added to webhook events

  • The body of webhook events now includes the user ID (destination) of a bot that should receive the webhook events. For more information, see Request body.
  • New information is available in message objects for image, video, and audio messages. For more information, see Image, Video, and Audio.

Correction on November 9, 2018 : MID -> user ID

# Flex Messages can now be multicast

Now you can send Flex Messages with the /v2/bot/message/multicast endpoint.

For the /v2/bot/message/multicast endpoint, see Send multicast message in the Messaging API reference.

Change to the imagemap message is scheduled

We'd like to inform you that we will change the specification of the imagemap message.

After the specification change, if the method of setting actions in imagemap messages is incorrect as below, an error occurs and you cannot send imagemap messages.

The current specification: You can send imagemap messages even if actions are set in the area that does not fit the width and height of the image specified by the baseSize property.

In this case, the layout of the imagemap displayed on the user device might be broken.

The new specification: You cannot send imagemap messages because the API request fails if actions are set in the area that does not fit the width and height of the image specified by the baseSize property.

This specification change will be released in the week starting November 5th.

The scheme of the picture URL returned when getting a user profile has been changed

Now we support https as the scheme of the pictureUrl property. The response to the GET https://api.line.me/v2/bot/profile/{userId} request includes this property.

[Update] Discontinuation of the long-lived channel access token

We'd like to inform you of the change in the discontinuation of the long-lived channel access token that we announced in August.

We have concluded that discontinuing the long-lived channel access token by November can cause difficulty to many developers. Therefore, we will continue to support the long-lived channel access token and find alternative ways in the future that will not affect our developers.

Default rich menu can now be configured with the Messaging API

Now you can configure the default rich menu with the Messaging API.

Both default rich menus created using LINE@ Manager (opens new window) and the Messaging API are supported and can be used at the same time.

For more information on how to use the rich menu features, see the following pages.

More stickers are available for your bot

We have increased the number of sticker types available for bots from 342 to 462. You can create a smarter, more expressive bot with various new stickers.

For more information, see Sticker message and the sticker list.

Long-term channel access token to be discontinued

We'd like to inform you that we will discontinue the long-lived channel access token used with the Messaging API.

The discontinuation is scheduled in November 2018 with the removal of the endpoints of the Messaging API v1.

Note that the long-lived channel access token is issued only from the LINE Developers Console. This endpoint to issue a short-lived channel access token will not be affected.

https://api.line.me/v2/oauth/accessToken

We will provide further details for a replacement method soon.

Flex Message is now available on your desktop

Flex Message is now available on your desktop.

The feature is supported on LINE 5.9.0 for macOS and Windows.

In addition, we have added the following new Flex Message properties so that you can create messages in a more flexible way.

  • action property of the box
  • maxLines property of the text

For more information, see the following pages:

Quick reply released

We have released the quick reply feature for messages sent through the Messaging API. When a user receives a message that contains quick reply buttons, those buttons appear at the bottom of the chat screen. The user can simply tap one of the buttons to reply to your bot.

Quick reply sample

The quick reply feature is supported on LINE 8.11.0 and later for iOS and Android.

For more information, see Using quick replies.

An important message for our users in Thailand, Taiwan, and Indonesia

Important notice concerning LINE Official Accounts, LINE@ accounts, Business Connect accounts, and Customer Connect accounts The following message applies to our users in Thailand, Taiwan, and Indonesia. LINE Corporation will be collecting information from LINE Official Accounts, LINE@ accounts, Business Connect accounts, and Customer Connect accounts (OAs) in order to improve our services. You must agree to these terms by September 2, 2018.

Log in to LINE@ Manager (opens new window)

With these revised terms, we will work on improving services requested by OA users, such as visualization of delivery performance through message views, click counts, video views, etc. and targeting delivery based on user response logs to messages.

Notice about service outage for the Messaging API (resolved)

We'd like to inform you about a service outage regarding the Messaging API. The issue has now been resolved but we sincerely apologize for any inconvenience that this may have caused.

# Date of recovery

Date: June 27, 2018 JST (GMT+9)

# Cause of the outage

Issue with our servers.

# Details

When the Messaging API was called to unlink a rich menu from a user that was not in a chat with the bot, the rich menu was not unlinked from the user. This issue occured only to users with LINE 8.7.0 or later for iOS and rich menus configured at admin-official.line.me.

We will continue to improve the quality of the services we provide to our developers and we greatly appreciate your understanding.

Flex Message released

We have released Flex Message, a new message type for the Messaging API. Flex Messages are messages with a customizable layout. You can customize the layout freely by combining multiple elements.

Flex Message samples

Flex Messages are only supported on LINE 6.7.0 and later for iOS and Android.

For more information, see Sending Flex Messages.

The maximum number of rich menus has been increased

Now you can set up to 1000 rich menus for one bot with the Messaging API. The previous maximum number was was 10.

For more information about rich menus, see Using rich menus.

Account link feature released

You will now be able to securely link the user account for your existing service with the LINE account of the user if they have friended your bot. This will allow you to utilize the user information you already have and use LINE bots to provide even better services.

For more information, see Linking user accounts. We will let you know when English documents become available.

LINE Bot Designer released

LINE Bot Designer lets you prototype LINE bots faster and easier without any programming knowledge. You can freely design chatbots in a desired scenario.

LINE Bot Designer free for use. Download it now. Anyone with a LINE account can use it.

For more information, see the LINE Bot Designer page.

Property for accessibility released

Now you can specify text to be spoken using the label property for imagemap messages and rich menus when the accessibility feature is enabled on the client device. This feature is supported on LINE 8.2.0 and later for iOS.

For more information, see the updated reference documentation below.

New properties for template messages and postback actions released

# Default actions can now be set for template messages

The defaultAction property has been added to the column object for buttons and carousel template messages. As a result, you can indicate a single action to be executed when a user taps anywhere in the image, title, or text area.

For more information, see the updated reference documentation below.

# displayText property for postback actions released

We have released the displayText property and have deprecated the text property for postback actions. We recommend using displayText instead of the text property. Note that the dislayText and text properties cannot both be used at the same time.

For more information, see the Postback action reference documentation.

Community SDK section released

We have released a community SDK section to our Messaging API SDKs page with Messaging API SDKs developed by our developer community. We currently have a C# (.NET) SDK (opens new window) and are looking to add more resources.

If you have developed a SDK or library for the Messaging API, see our Community contribution guidelines for information on how to submit your project to us for review.

New article on sharing bots

We've added a new article on how you can gain more friends and expand the reach of your bot. For example, you can use a QR code, add an "Add friend" button, or link your bot with a LINE Login channel.

Check out the article at Sharing your bot with users.

New options for template message images

We have released imageAspectRatio, imageSize, and imageBackgroundColor fields for Buttons and Carousel template messages. Using these fields, you can configure the aspect ratio, size, and background color for images used in template messages. For more information, see the reference documentation below.

LINE URL scheme information released

We've added an article about the LINE URL scheme to our LINE Login and Messaging API documentation. You can use the URL schemes to help your users navigate to specific content such as the camera, location, or settings screens in LINE. The LINE URL scheme can be used in your bot (Messaging API) from within LINE or in your native or web apps to automatically open LINE.

See the new articles below.

Link your bot to your LINE Login channel

We've added an option to display a prompt to let you display an option for users to add your bot as a friend when logging in to your app with LINE Login. To do this, first, link a bot to your LINE Login account from the new "Bot linked to this channel" item in the LINE Developers Console, then include the bot_prompt query parameter in the authorization URL for LINE Login.

For more information on this feature, see Linking a bot with your LINE Login channel.

In addition, we've released a new resource for the Social API which lets you get the friendship status between your bot and a user. Send a GET request to https://api.line.me/friendship/v1/status to see if the user has added your bot as a friend or not.

To see the API reference for this resource, go to Get friendship status.

Note: This feature is not currently available to enterprise users. If you are an enterprise user and would like to use this feature, please contact your LINE representative.

LINE Login and Messaging API glossaries

To help you better understand the terms and concepts used in our documentation, we've added glossaries for both LINE Login and Messaging API.

Check them out using the links below.

Specification change for rich menu resources

We've made changes to the response of the rich menu resources of the Messaging API listed below. When sending a request to delete or upload a rich menu or to link or unlink a rich menu for a user, the LINE Platform will now return a 200 status code and an empty JSON object on success instead of returning only a 200 status code.

See the updated API reference documentation below.

Column objects for template messages increased

We've increased the number of column objects that you can include in your carousel and image carousel template messages from 5 to 10 objects.

For more information, see the updated reference documentation below.

Rich menu features for Messaging API released

We've released rich menu features for the Messaging API which lets you display different rich menus to different users. By using the newly released rich menu endpoints, you can create, link, and manage your rich menus programmatically via the API instead of using LINE@ Manager (opens new window). The rich menu endpoints provide greater freedom in designing rich menus and the ability to set postback actions to specified areas.

In addition to the current rich menu size of 2500x1686 on LINE@ Manager, you can now create smaller rich menus that are 2500x843 with the Messaging API. This smaller rich menu size lets you display more of the chat screen while still providing an interactive menu for the user.

Both rich menus created using LINE@ Manager and the Messaging API are supported and can be used at the same time.

Note: These rich menu features are only supported on LINE 7.14.0 and later for Android and iOS.

For more information on how to use the new rich menu features, see the following pages.

Changes to the user consent process and data retrieved in webhooks

The user consent process and the data included in certain webhooks will change from LINE version 7.5.0 (iOS and Android). The details of the changes are shown below.

  1. Changes to the user consent process

    The way that users give consent to bots (LINE@ accounts and LINE Official Accounts) will change with the release of LINE version 7.5.0. Instead of requiring users to agree to a consent screen for every bot they want to add as a friend or start a chat with, from version 7.5.0, users will provide consent to all bots at once through a new consent screen (called the “Official Accounts Terms of Use”). After users have agreed to this screen once, they will be able to add other bots as friends and add them to chats in a single action.

    For more information on the user consent process, see User consent

  2. Changes to the Messaging API specifications

    Webhooks will include the user ID of users who send messages in a group or a room if the user has agreed to the “Official Accounts Terms of Use”. Note that the user ID will not be included in the webhook if the user is using a version of LINE below 7.5.0.

Messaging API SDK for Node.js released

We have released the Messaging API SDK for Node.js. This makes it easier for you to to build a bot on LINE with Node.js using the Messaging API.

See the Messaging API SDK repository below.

For more information on how to use the Messaging API SDK for Node.js, see the documentation (opens new window).

Multicast feature released

We've released the multicast feature which lets you send messages to multiple users at any time.

See the updated documentation in the API reference below.

We will continue to provide improvements so that developers can code more easily.

Messaging API released and LINE Developers documentation updated

We've made some updates to the LINE Developers website. We've added new documentation together with the release of the Messaging API. Our API reference documentation has also been updated and redesigned. And we've made a couple of branding changes as well.

For more detailed information about the changes, see below:

  • Added "Overview", "Getting started", and API reference documentation for the Messaging API. For more information, see Messaging API.
  • Changed the look of the API reference documentation. See the new documentation here: API reference.
  • Made the following branding changes:
    • Web API includes the APIs used for integrating Web Login with your websites.
    • Social REST API includes REST APIs that you can call from your applications.
    • LINE Login, LINE SDK for Android, LINE SDK for iOS, Web API, and Social REST API are included in Social API
  • Added information on LINE Official Accounts and LINE@ accounts in "Account types".

Sending rich messages section updated

The "Sending rich messages" section of the LINE Developers site has been updated to include information about the "sendMessage" feature of rich messages.

For more information, go to https://developers.line.me/bot-api/api-reference.

Useful links have been added for BOT API Trial

We have added useful links to accelerate your development on BOT API Trial.

See all the links added from below.

Messaging API links

List of stickers updated

Sticker images have been added to the sticker list which will allow developers to easily recognize the sticker ID.

Method for calling APIs for BOT API Trial changed

You are no longer required to register the IP address of your server to call APIs for BOT API Trial. If you register an IP address on the whitelist, API calls will be limited to that IP address. You can use the whitelist for security purposes.

Let's Encrypt and StartSSL CA has been added

SSL CA root certificates for Let's Encrypt and StartSSL have been added for BOT API callback URL.

See the "Note" in the Registering a callback URL section to find a link to the full list of authorized CAs.