line-bot-api 1.21.0 → 1.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/line/bot/api/version.rb +1 -1
- data/lib/line/bot/client.rb +35 -6
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a36da29494cce63f76dcb86eeb598ee138cdac97c3e8d1b9a3cd630de77f969e
|
4
|
+
data.tar.gz: e44f44089b1047692f57a95733a7fe73aa6362f45838280eedb8e14286d832ee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d1f110ae8342f09be0d07bc335ce8f982868d10e26b9bc3eef0c0a60b77b0c1a06dde346eab279250b0c521888978db673a50c6db17d070d1650608fc2fb080a
|
7
|
+
data.tar.gz: 7ab72e341fb0db004519df79eb2ef95e802f54da19fa90087d193c7bd493523fbb1069a70fd1c8b6be07ba7249491f1c4775fca298d8e6c4a97530ce9046279f
|
data/lib/line/bot/api/version.rb
CHANGED
data/lib/line/bot/client.rb
CHANGED
@@ -116,9 +116,6 @@ module Line
|
|
116
116
|
#
|
117
117
|
# @return [Net::HTTPResponse]
|
118
118
|
def issue_channel_access_token_jwt(jwt)
|
119
|
-
channel_id_required
|
120
|
-
channel_secret_required
|
121
|
-
|
122
119
|
endpoint_path = '/oauth2/v2.1/token'
|
123
120
|
payload = URI.encode_www_form(
|
124
121
|
grant_type: 'client_credentials',
|
@@ -154,9 +151,6 @@ module Line
|
|
154
151
|
#
|
155
152
|
# @return [Net::HTTPResponse]
|
156
153
|
def get_channel_access_token_key_ids_jwt(jwt)
|
157
|
-
channel_id_required
|
158
|
-
channel_secret_required
|
159
|
-
|
160
154
|
payload = URI.encode_www_form(
|
161
155
|
client_assertion_type: 'urn:ietf:params:oauth:client-assertion-type:jwt-bearer',
|
162
156
|
client_assertion: jwt
|
@@ -578,6 +572,41 @@ module Line
|
|
578
572
|
delete(endpoint, endpoint_path, credentials)
|
579
573
|
end
|
580
574
|
|
575
|
+
# Update rich menu alias
|
576
|
+
#
|
577
|
+
# @param rich_menu_id [String] ID of an uploaded rich menu
|
578
|
+
# @param rich_menu_alias_id [String] string of alias words rich menu
|
579
|
+
#
|
580
|
+
# @return [Net::HTTPResponse]
|
581
|
+
def update_rich_menus_alias(rich_menu_id, rich_menu_alias_id)
|
582
|
+
channel_token_required
|
583
|
+
|
584
|
+
endpoint_path = "/bot/richmenu/alias/#{rich_menu_alias_id}"
|
585
|
+
post(endpoint, endpoint_path, { richMenuId: rich_menu_id }.to_json, credentials)
|
586
|
+
end
|
587
|
+
|
588
|
+
# Get a rich menu alias via a rich menu alias ID
|
589
|
+
#
|
590
|
+
# @param rich_menu_alias_id [String] string of alias words rich menu
|
591
|
+
#
|
592
|
+
# @return [Net::HTTPResponse]
|
593
|
+
def get_rich_menus_alias(rich_menu_alias_id)
|
594
|
+
channel_token_required
|
595
|
+
|
596
|
+
endpoint_path = "/bot/richmenu/alias/#{rich_menu_alias_id}"
|
597
|
+
get(endpoint, endpoint_path, credentials)
|
598
|
+
end
|
599
|
+
|
600
|
+
# Get a list of all uploaded rich menus alias
|
601
|
+
#
|
602
|
+
# @return [Net::HTTPResponse]
|
603
|
+
def get_rich_menus_alias_list
|
604
|
+
channel_token_required
|
605
|
+
|
606
|
+
endpoint_path = "/bot/richmenu/alias/list"
|
607
|
+
get(endpoint, endpoint_path, credentials)
|
608
|
+
end
|
609
|
+
|
581
610
|
# Link a rich menu to a user
|
582
611
|
#
|
583
612
|
# If you want to link a rich menu to multiple users,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: line-bot-api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.22.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- LINE Corporation
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-09-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|