Lineで利用できる変数です。
Lineのリファレンス Messaging Object
を適宜参照してください。
また、管理画面には LINE説明用テンプレート
テンプレートがあるので、そちらも参考にして下さい。
共通の変数と、送信したいメッセージ(text, image, imagemap, buttons, confirm, carousel)ごとの変数を以下で説明します。
メッセージでは5個までが一度に送信可能です。
Common variables
Name | Type | Required | Description |
---|---|---|---|
app_name | String | ○ | line |
lineVersion | String | ○ | v2 |
Text Message
Name | Type | Required | Description |
---|---|---|---|
text | String | ○ | Text Max: 2000 characters |
テキスト内URLのクリック計測
現状テキスト内のURLはクリックの計測はされません。自動的な短縮化も行いません。
Image Message
Name | Type | Required | Description |
---|---|---|---|
image | String | ○ | Image URL Max: 1000 characters HTTPS JPEG Max: 1024 x 1024 Max: 1 MB |
imagemap Message
Name | Type | Required | Description |
---|---|---|---|
imagemap | Object (Folder) | ○ | |
imagemap.altText | String | ○ | Alternative text Max: 400 characters |
imagemap.baseUrl | String | ○ | Base URL of the image Max: 1000 characters HTTPS |
imagemap.baseSize | Object (Folder) | ○ | |
imagemap.baseSize.width | Number | ○ | Width of base image in pixels. Set to 1040. |
imagemap.baseSize.height | Number | ○ | Height of base image. Set to the height that corresponds to a width of 1040 pixels. |
imagemap.actions[] | Array (List) | ○ | Action when tapped Max: 50 |
imagemap.actions[].type | String | ○ | uri |
imagemap.actions[].linkUri | String | ○ | Webpage URL Max: 1000 characters Automatically convert this field into https://s.karte.io/xxx formats for click tracking. |
imagemap.actions[].area | Object (Folder) | ○ | Defined tappable area |
imagemap.actions[].area.x | Number | ○ | Horizontal position relative to the top-left corner of the area |
imagemap.actions[].area.y | Number | ○ | Vertical position relative to the top-left corner of the area |
imagemap.actions[].area.width | Number | ○ | Width of the tappable area |
imagemap.actions[].area.height | Number | ○ | Height of the tappable area |
buttons Message
Name | Type | Required | Description |
---|---|---|---|
buttons | Object (Folder) | ○ | |
buttons.altText | String | ○ | Alternative text. Max: 400 characters |
buttons.title | String | Title Max: 40 characters | |
buttons.text | String | ○ | Message text Max: 160 characters (no image or title) Max: 60 characters (message with an image or title) |
buttons.thumbnailImageUrl | String | Image URL (Max: 1000 characters) HTTPS JPEG or PNG Max width: 1024px Max: 1 MB | |
buttons.actions[] | Array (List) | ○ | Action when tapped Max: 4 See Action Object |
confirm Message
Name | Type | Required | Description |
---|---|---|---|
confirm | Object (Folder) | ○ | |
confirm.altText | String | ○ | Alternative text. Max: 400 characters |
confirm.text | String | ○ | Message text Max: 240 characters |
confirm.actions[] | Array (List) | ○ | Action when tapped Set 2 actions for the 2 buttons See Action Object |
carousel Message
Name | Type | Required | Description |
---|---|---|---|
carousel | Object (Folder) | ○ | |
carousel.altText | String | ○ | Alternative text. Max: 400 characters |
carousel.columns[] | Array (List) | ○ | Array of columns Max: 10 |
carousel.columns[].thumbnailImageUrl | String | Image URL (Max: 1000 characters) HTTPS JPEG or PNG Max width: 1024px Max: 1 MB | |
carousel.columns[].title | String | Title Max: 40 characters | |
carousel.columns[].text | String | ○ | Message text Max: 120 characters (no image or title) Max: 60 characters (message with an image or title) |
carousel.columns[].actions[] | Array (List) | ○ | Action when tapped Max: 3 See Action Object |
Action Object
Name | Type | Required | Description |
---|---|---|---|
type | String | ○ | message or uri |
label | String | ○ | Label for the action Required for templates other than image carousel. Max: 20 characters. Optional for image carousel templates. Max: 12 characters. Optional for rich menus. Spoken when the accessibility feature is enabled on the client device. Max: 20 characters. Supported on LINE 8.2.0 and later for iOS. Required for quick reply buttons. Max: 20 characters. Supported on LINE 8.11.0 and later for iOS and Android. Requird for the button component of Flex Message. This property can be specified for the box, image, and text components but its value is not displayed. Max: 20 characters. |
text | String | ○ (if type is message ) | Text sent when the action is performed Max: 300 characters |
uri | String | ○ (if type is uri ) | URI opened when the action is performed (Max: 1000 characters) The available schemes are http, https, line, and tel. Automatically convert this field into https://s.karte.io/xxx formats for click tracking. |