line-bot-api 1.28.0 → 1.29.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3d5c002bd9571e6dc16472a7a6fe465aaf52d3c1fa4964637ce195cde0dae426
4
- data.tar.gz: c3a007fa7ca316560612cfef6f7b97a44e6b9d4bbe203516273f9bae6b40cc7c
3
+ metadata.gz: 10292429dbd89bc3ecce7eb32bd7112013680cf96a4dc6abc3c7984181247598
4
+ data.tar.gz: 8094eee0946c394c9fcaf0b74da4cbc8240de6063904bd4a08b6fc23634261bd
5
5
  SHA512:
6
- metadata.gz: f0598b48094499f88f6ca3fe3007de5468a578df0a4207c3aa254c2452674fbd93bcbbb866b146cf20c0b7b21fd0701b41709f7671e621cf950196cc8b8ff075
7
- data.tar.gz: 3a6406575a5cec9a7d9e9f04582d0af9be9a83fb998336fa563d0b95f0720f8a28df34c6d48e529dd51b8cf96101a3ef0fb8adac500f7b638c7e2cf12cc7d831
6
+ metadata.gz: b670c31ba6bf4c11cf3faa02b82b74c22e0e3fccb230433d7a1bd6607f77a93b0fc27d7a396d689f5ad94707cd89c59d0be05e386f6d12834ddb428c57355b8a
7
+ data.tar.gz: ef168567d1c273d0e8d05a35227e4433d0d7d0312c5719316ab7e35a9113522193058916c942f4fa65dea8b6f725109736e68b3e12f294afda78abda35c88ca9
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # LINE Messaging API SDK for Ruby
2
2
 
3
- [![Gem-version](https://img.shields.io/gem/v/line-bot-api.svg)](https://rubygems.org/gems/line-bot-api) [![Build Status](https://travis-ci.org/line/line-bot-sdk-ruby.svg?branch=master)](https://travis-ci.org/line/line-bot-sdk-ruby)
3
+ [![Gem-version](https://img.shields.io/gem/v/line-bot-api.svg)](https://rubygems.org/gems/line-bot-api)
4
4
 
5
5
 
6
6
  ## Introduction
@@ -17,6 +17,9 @@ Also, generated documentation by YARD is available.
17
17
 
18
18
  - https://rubydoc.info/gems/line-bot-api
19
19
 
20
+ ## Requirements
21
+ This library requires Ruby 3.1 or later.
22
+
20
23
  ## Installation
21
24
 
22
25
  Add this line to your application's Gemfile:
@@ -89,12 +92,8 @@ end
89
92
  ## Help and media
90
93
  FAQ: https://developers.line.biz/en/faq/
91
94
 
92
- Community Q&A: https://www.line-community.me/questions
93
-
94
95
  News: https://developers.line.biz/en/news/
95
96
 
96
- Twitter: @LINE_DEV
97
-
98
97
  ## Versioning
99
98
  This project respects semantic versioning.
100
99
 
@@ -15,7 +15,7 @@
15
15
  module Line
16
16
  module Bot
17
17
  module API
18
- VERSION = "1.28.0"
18
+ VERSION = "1.29.0"
19
19
  end
20
20
  end
21
21
  end
@@ -1207,6 +1207,36 @@ module Line
1207
1207
  get(endpoint, endpoint_path, credentials)
1208
1208
  end
1209
1209
 
1210
+ # Send a LINE notification message by specifying the user's phone number.
1211
+ #
1212
+ # @param hashed_phone_number [String] Phone number that has been normalized.
1213
+ # @param messages [Hash, Array] Message Objects.
1214
+ # @param headers [Hash] HTTP Headers.
1215
+ # @param payload [Hash] Additional request body.
1216
+ #
1217
+ # @return [Net::HTTPResponse]
1218
+ def push_pnp(hashed_phone_number, messages, headers: {}, payload: {})
1219
+ channel_token_required
1220
+
1221
+ messages = [messages] if messages.is_a?(Hash)
1222
+
1223
+ endpoint_path = '/bot/pnp/push'
1224
+ payload = payload.merge({ to: hashed_phone_number, messages: messages }).to_json
1225
+ post(oauth_endpoint, endpoint_path, payload, credentials.merge(headers))
1226
+ end
1227
+
1228
+ # Get the number of LINE notification messages sent using the /bot/pnp/push endpoint.
1229
+ #
1230
+ # @param date [String] Date the messages were sent (format: yyyyMMdd).
1231
+ #
1232
+ # @return [Net::HTTPResponse]
1233
+ def get_message_delivery_pnp(date)
1234
+ channel_token_required
1235
+
1236
+ endpoint_path = "/bot/message/delivery/pnp?date=#{date}"
1237
+ get(endpoint, endpoint_path, credentials)
1238
+ end
1239
+
1210
1240
  # Fetch data, get content of specified URL.
1211
1241
  #
1212
1242
  # @param endpoint_base [String]
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.28.0
4
+ version: 1.29.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: 2023-03-14 00:00:00.000000000 Z
11
+ date: 2024-06-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable