Skip to content

Commit

Permalink
Merge pull request #20 from boybundit/develop
Browse files Browse the repository at this point in the history
1.3.0
  • Loading branch information
boybundit committed Mar 18, 2017
2 parents 8798757 + cf69081 commit bc69d82
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 7 deletions.
23 changes: 17 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,18 @@ A userId can be saved from `event.source.userId`
when added as a friend (follow event), or during the chat (message event).

`message` can be a string, an array of string,
a [Send message][send-message-url] object,
a [Send message][send-message-url] object,
or an array of [Send message][send-message-url] objects.

## LineBot.multicast(to, message)

Send push message to multiple users (Max: 150 users).
This is more efficient than `push` as it will make api call only once.

`to` is an array of userId.

`message` can be a string, an array of string,
a [Send message][send-message-url] object,
or an array of [Send message][send-message-url] objects.

## LineBot.leaveGroup(groupId)
Expand All @@ -123,7 +134,7 @@ Leave a room.
Respond to the event.

`message` can be a string, an array of string,
a [Send message][send-message-url] object,
a [Send message][send-message-url] object,
or an array of [Send message][send-message-url] objects.

Return a [Promise][promise-url] object from [`node-fetch`][node-fetch-url] module.
Expand Down Expand Up @@ -164,10 +175,10 @@ event.reply({

event.reply({
type: 'location',
title: 'my location',
address: '〒150-0002 東京都渋谷区渋谷2丁目21−1',
latitude: 35.65910807942215,
longitude: 139.70372892916203
title: 'my location',
address: '〒150-0002 東京都渋谷区渋谷2丁目21−1',
latitude: 35.65910807942215,
longitude: 139.70372892916203
});

event.reply({
Expand Down
3 changes: 3 additions & 0 deletions examples/demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ bot.on('message', function (event) {
case 'Push':
bot.push('U6350b7606935db981705282747c82ee1', ['Hey!', 'สวัสดี ' + String.fromCharCode(0xD83D, 0xDE01)]);
break;
case 'Push2':
bot.push(['U6350b7606935db981705282747c82ee1', 'U6350b7606935db981705282747c82ee1'], ['Hey!', 'สวัสดี ' + String.fromCharCode(0xD83D, 0xDE01)]);
break;
case 'Multicast':
bot.push(['U6350b7606935db981705282747c82ee1', 'U6350b7606935db981705282747c82ee1'], 'Multicast!');
break;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "linebot",
"version": "1.2.1",
"version": "1.3.0",
"description": "Node.js SDK for the LINE Messaging API",
"main": "index.js",
"files": [
Expand Down

0 comments on commit bc69d82

Please sign in to comment.