Skip to content

LINE Message API Multicast Message Node

Jatuphum Tungsilsukchai edited this page Mar 29, 2022 · 22 revisions

multicast-node

NODE-RED node for multicast message to LINE Messaging API channel. You can use LINE Messaging API, multicast message, through this Node.

Usage

  1. Create LINE Messaging API Channel in LINE Developer console. Use this official document Getting started with the Messaging API to create your own LINE Messaging API.

  2. Obtain a Channel Access Token and Channel Secret from your created LINE Messaging API Channel (Actually, LINE Message API Multicast Message Node use only Channel Access Token, but LINE Messaging API Configuration Node requires both Channel Access Token and Channel Secret for configuration).

  3. Add Messaging API Channel to LINE application.

  4. Find User IDs or Group IDs for multicast message. Go to How to find User Id or Group Id for testing Messaging API for easy finding.

  5. Add LINE Message API Multicast Message Node in Node-RED workspace.

  6. Configure LINE Messaging API Channel Access Token and Channel Secret in Multicast Message Node. See using LINE Messaging API Configuration Node

multicast-config

  1. Setup Node values
  • Use/Don't use ID list from wired node. If use ID list from wired node, it does not use destinatin ID list from Node Input.

  • Desitnation IDs. Specified destination ID list for multicast message.

multicast-destination

  • Use/Don't use message data from wired node. If use message data from wired node, it does not use message type and message content from Node Input.
  • Message Type, Normal Text (string) or Custom Message Format (JSON)
  • Message, message for broadcast.
  • Disabled Push Notification, the user does/doesn't receive push notification when the message is sent.

multicast-message-notification

  1. Setup other notify options

  2. Run workflow

  3. Check result.

Input

Using msg object.

Property Mandatory Type Description
destinations No (Yes, if select 'Use ID list from wired node') String [] Specified destination ID list for multicast message to
messageType No (Yes, if select 'Use Message data from wired node') int 0 : for normal text message for multicast message.
1 : for custom message format for multicast message.
payload No (Yes, if select 'Use Message data from wired node') string or JSON Type string for normal text message
Type JSON for custom message format
Node multicast message check payload type at runtime

Output

Using msg object.

Output success - status = 0, payload = Multicast message success: {"x-line-request-id":"xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx"}

Output Fail - status = <Error Number>, payload = <Error message>

Property Type Description
status number Result status code
payload string Result status message

More details

Obtain LINE Messaging API Channel Access Token at your LINE Messaging API Channel.

See more details at LINE Messaging API (Multicast Message) Document.

Custom message format can see more details at LINE Message Types.

For more information, see List of available LINE emojis.

Node has paste function data from clipboard, so allow paste permmision in browser to able to work paste function.

Clone this wiki locally