vonage 7.26.0 → 7.27.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5d3865caa299175327806358dbe9a66e59abefa41240a5d9a847e5e73a37ea50
4
- data.tar.gz: 861a7ae004b3908083af43cae0809330732dc07aa7be22a3cc362dc8b538fdab
3
+ metadata.gz: 882867135989a3281df945f45ee52c5f8ccd01f60878e0987570f43d5802b384
4
+ data.tar.gz: 805db1a403bdbe6ceae3adb90b7e1cf8afdc25215b947e5a41a010b5050e4836
5
5
  SHA512:
6
- metadata.gz: 336c7b033206cf204f41e513a2dc8a4c56b57750660e17b37aede3d200aedcced48352ab18ffa3d44f7924df34548f767f19c9189dc385d9f2557a584d399bd7
7
- data.tar.gz: da28e64d300d4f70c789e670c10f60beb9fbb058c1da3af8f2f995a8a61541d5b73cea93342f0a5f3b1b0a620dbba5c277fe5b8617259a52446bbbbeed09042e
6
+ metadata.gz: 14edb2c22f6e54e58bd17a26290944ec5d963706436b3b41d1f5598f094e57a7fdd09fa6ece3d4885a575c567eddaeb16bf8ebf2bd52a5fdd107a4404e7d20ce
7
+ data.tar.gz: 284099e63365b6e08bbcb6ec3a03213ba9f812963841470b83e35b8f03e040611f75bdba1d6c35d5e4982604dcc1e9803e96fc5a290ed5677474537837687a38
data/README.md CHANGED
@@ -14,6 +14,7 @@ need a Vonage account. Sign up [for free at vonage.com][signup].
14
14
  * [Logging](#logging)
15
15
  * [Exceptions](#exceptions)
16
16
  * [Overriding the default hosts](#overriding-the-default-hosts)
17
+ * [HTTP Client Configuration](#http-client-configuration)
17
18
  * [JWT authentication](#jwt-authentication)
18
19
  * [Webhook signatures](#webhook-signatures)
19
20
  * [Pagination](#pagination)
@@ -83,7 +84,7 @@ client = Vonage::Client.new(application_id: application_id, private_key: private
83
84
  ```
84
85
 
85
86
  Both arguments should have string values corresponding to the `id` and `private_key`
86
- values returned in a ["create an application"](https://developer.nexmo.com/api/application.v2#createApplication)
87
+ values returned in a ["create an application"](https://developer.vonage.com/api/application.v2#createApplication)
87
88
  response. These credentials can be stored in a datastore, in environment variables,
88
89
  on disk outside of source control, or in some kind of key management infrastructure.
89
90
 
@@ -104,8 +105,8 @@ token = Vonage::JWT.generate(claims)
104
105
  client = Vonage::Client.new(token: token)
105
106
  ```
106
107
 
107
- Documentation for the Vonage Ruby JWT generator gem can be found at
108
- [https://www.rubydoc.info/github/nexmo/nexmo-jwt-ruby](https://www.rubydoc.info/github/nexmo/nexmo-jwt-ruby).
108
+ Documentation for the Vonage Ruby JWT generator gem can be found at: https://www.rubydoc.info/gems/vonage-jwt
109
+
109
110
  The documentation outlines all the possible parameters you can use to customize and build a token with.
110
111
 
111
112
  ### Logging
@@ -179,8 +180,32 @@ client = Vonage::Client.new(
179
180
 
180
181
  By default the hosts are set to `api.nexmo.com` and `rest.nexmo.com`, respectively.
181
182
 
183
+ ### HTTP Client Configuration
184
+
185
+ It is possible to set configuration options on the HTTP client. This can be don in a couple of ways.
186
+
187
+ 1. Using an `:http` key during `Vonage::Client` instantiation, for example:
188
+ ```ruby
189
+ client = Vonage::Client.new(
190
+ api_key: 'YOUR-API-KEY',
191
+ api_secret: 'YOUR-API-SECRET',
192
+ http: {
193
+ max_retries: 1
194
+ }
195
+ )
196
+ ```
197
+
198
+ 2. By using the `http=` setter on the `Vonage::Config` object, for example:
199
+ ```ruby
200
+ client = Vonage::Client.new(
201
+ api_key: 'YOUR-API-KEY',
202
+ api_secret: 'YOUR-API-SECRET'
203
+ )
182
204
 
205
+ client.config.http = { max_retries: 1 }
206
+ ```
183
207
 
208
+ The Vonage Ruby SDK uses the [`Net::HTTP::Persistent` library](https://github.com/drbrain/net-http-persistent) as an HTTP client. For available configuration options see [the documentation for that library](https://www.rubydoc.info/gems/net-http-persistent/3.0.0/Net/HTTP/Persistent).
184
209
 
185
210
  ### Webhook signatures
186
211
 
@@ -300,10 +325,10 @@ Vonage APIs paginate list requests. This means that if a collection is requested
300
325
 
301
326
  The `auto_advance` parameter is set to a default of `true` for the following APIs:
302
327
 
303
- * [Account API](https://developer.nexmo.com/api/developer/account)
304
- * [Application API](https://developer.nexmo.com/api/application.v2)
305
- * [Conversation API](https://developer.nexmo.com/api/conversation)
306
- * [Voice API](https://developer.nexmo.com/api/voice)
328
+ * [Account API](https://developer.vonage.com/api/developer/account)
329
+ * [Application API](https://developer.vonage.com/api/application.v2)
330
+ * [Conversation API](https://developer.vonage.com/api/conversation)
331
+ * [Voice API](https://developer.vonage.com/api/voice)
307
332
 
308
333
  To modify the `auto_advance` behavior you can specify it in your method:
309
334
 
@@ -314,7 +339,7 @@ client.applications.list(auto_advance: false)
314
339
 
315
340
  ## Messages API
316
341
 
317
- The [Vonage Messages API](https://developer.vonage.com/messages/overview) allows you to send messages over a number of different channels, and various message types within each channel. See the Vonage Developer Documentation for a [complete API reference](https://developer.vonage.com/api/messages-olympus) listing all the channel and message type combinations.
342
+ The [Vonage Messages API](https://developer.vonage.com/messages/overview) allows you to send messages over a number of different channels, and various message types within each channel. See the Vonage Developer Documentation for a [complete API reference](https://developer.vonage.com/en/api/messages) listing all the channel and message type combinations.
318
343
 
319
344
  The Ruby SDK allows you to construct message data for specific messaging channels. Other than SMS (which has only one type -- text), you need to pass the message `:type` as well as the `:message` itself as arguments to the appropriate messages method, along with any optional properties if needed.
320
345
 
@@ -513,11 +538,11 @@ response = client.voice.create({
513
538
 
514
539
  ## Documentation
515
540
 
516
- Vonage Ruby SDK documentation: https://www.rubydoc.info/github/Vonage/vonage-ruby-sdk
541
+ Vonage Ruby SDK documentation: https://www.rubydoc.info/gems/vonage
517
542
 
518
543
  Vonage Ruby SDK code examples: https://github.com/Vonage/vonage-ruby-code-snippets
519
544
 
520
- Vonage APIs API reference: https://developer.nexmo.com/api
545
+ Vonage APIs API reference: https://developer.vonage.com/api
521
546
 
522
547
  ## Supported APIs
523
548
 
data/lib/vonage/http.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  # typed: strict
2
2
  # frozen_string_literal: true
3
- require 'net/http'
3
+ require 'net/http/persistent'
4
4
 
5
5
  module Vonage
6
6
  module HTTP
@@ -21,7 +21,7 @@ module Vonage
21
21
  end
22
22
  end
23
23
 
24
- sig { params(http: Net::HTTP).returns(T::Hash[Symbol, T.untyped]) }
24
+ sig { params(http: Net::HTTP::Persistent).returns(T::Hash[Symbol, T.untyped]) }
25
25
  def set(http)
26
26
  @hash.each do |name, value|
27
27
  http.public_send(defined_options.fetch(name), value)
@@ -34,7 +34,7 @@ module Vonage
34
34
  def defined_options
35
35
  @defined_options = T.let(@defined_options, T.nilable(T::Hash[Symbol, T.untyped]))
36
36
 
37
- @defined_options ||= Net::HTTP.instance_methods.grep(/\w=\z/).each_with_object({}) do |name, hash|
37
+ @defined_options ||= Net::HTTP::Persistent.instance_methods.grep(/\w=\z/).each_with_object({}) do |name, hash|
38
38
  hash[name.to_s.chomp('=').to_sym] = name
39
39
  end
40
40
  end
@@ -13,12 +13,15 @@ module Vonage
13
13
 
14
14
  # Update an existing application.
15
15
  #
16
+ # @deprecated
17
+ #
16
18
  # @param [required, String] :default_theme_id The id of the theme to set as application default theme
17
19
  #
18
20
  # @return [Response]
19
21
  #
20
22
  # @see https://developer.vonage.com/en/api/meetings#updateApplication
21
23
  def update(default_theme_id:)
24
+ logger.info('This method is deprecated and will be removed in a future release.')
22
25
  request("/v1/meetings/applications", params: {update_details: {default_theme_id: default_theme_id}}, type: Patch)
23
26
  end
24
27
  end
@@ -13,10 +13,13 @@ module Vonage
13
13
 
14
14
  # Get numbers that can be used to dial into a meeting.
15
15
  #
16
+ # @deprecated
17
+ #
16
18
  # @return [ListResponse]
17
19
  #
18
20
  # @see https://developer.vonage.com/en/api/meetings#getDialInNumbers
19
21
  def list
22
+ logger.info('This method is deprecated and will be removed in a future release.')
20
23
  request("/v1/meetings/dial-in-numbers", response_class: ListResponse)
21
24
  end
22
25
  end
@@ -13,23 +13,29 @@ module Vonage
13
13
 
14
14
  # Return information for specified recording.
15
15
  #
16
+ # @deprecated
17
+ #
16
18
  # @param [required, String] recording_id The id of the recoring for which the info should be returned
17
19
  #
18
20
  # @return [Response]
19
21
  #
20
22
  # @see https://developer.vonage.com/en/api/meetings#getRecording
21
23
  def info(recording_id:)
24
+ logger.info('This method is deprecated and will be removed in a future release.')
22
25
  request("/v1/meetings/recordings/" + recording_id)
23
26
  end
24
27
 
25
28
  # Delete a specified recording.
26
29
  #
30
+ # @deprecated
31
+ #
27
32
  # @param [required, String] recording_id The id of the recoring to be deleted
28
33
  #
29
34
  # @return [Response]
30
35
  #
31
36
  # @see https://developer.vonage.com/en/api/meetings#deleteRecording
32
37
  def delete(recording_id:)
38
+ logger.info('This method is deprecated and will be removed in a future release.')
33
39
  request("/v1/meetings/recordings/" + recording_id, type: Delete)
34
40
  end
35
41
  end
@@ -13,6 +13,8 @@ module Vonage
13
13
 
14
14
  # Get a list of rooms associated with the Vonage application.
15
15
  #
16
+ # @deprecated
17
+ #
16
18
  # @param [optional, Integer] :start_id
17
19
  #
18
20
  # @param [optional, Integer] :end_id
@@ -23,6 +25,7 @@ module Vonage
23
25
  #
24
26
  # @see https://developer.vonage.com/en/api/meetings#getRooms
25
27
  def list(**params)
28
+ logger.info('This method is deprecated and will be removed in a future release.')
26
29
  path = "/v1/meetings/rooms"
27
30
  path += "?#{Params.encode(params)}" unless params.empty?
28
31
 
@@ -31,6 +34,8 @@ module Vonage
31
34
 
32
35
  # Return information for specified room.
33
36
  #
37
+ # @deprecated
38
+ #
34
39
  # @param [required, String] room_id
35
40
  # The id of the room for which the info should be returned
36
41
  #
@@ -38,11 +43,14 @@ module Vonage
38
43
  #
39
44
  # @see https://developer.vonage.com/en/api/meetings#getRoom
40
45
  def info(room_id:)
46
+ logger.info('This method is deprecated and will be removed in a future release.')
41
47
  request("/v1/meetings/rooms/" + room_id)
42
48
  end
43
49
 
44
50
  # Create a new room.
45
51
  #
52
+ # @deprecated
53
+ #
46
54
  # @param [required, String] :display_name
47
55
  #
48
56
  # @param [optional, String] :metadata
@@ -95,6 +103,7 @@ module Vonage
95
103
  #
96
104
  # @see https://developer.vonage.com/en/api/meetings#createRoom
97
105
  def create(display_name:, **params)
106
+ logger.info('This method is deprecated and will be removed in a future release.')
98
107
  request(
99
108
  "/v1/meetings/rooms",
100
109
  params: params.merge({ display_name: display_name }),
@@ -106,6 +115,8 @@ module Vonage
106
115
  # Although paramaters (other than `room_id`) are optional, at least one other parameter must be provided or an error
107
116
  # response will be received.
108
117
  #
118
+ # @deprecated
119
+ #
109
120
  # @param [required, String] room_id The ID of the Room to be updated
110
121
  #
111
122
  # @param [optional, String(date)] :expires_at
@@ -142,6 +153,7 @@ module Vonage
142
153
  #
143
154
  # @see https://developer.vonage.com/en/api/meetings#updateRoom
144
155
  def update(room_id:, **params)
156
+ logger.info('This method is deprecated and will be removed in a future release.')
145
157
  raise ArgumentError, 'must provide at least one other param in addition to :room_id' if params.empty?
146
158
  request(
147
159
  "/v1/meetings/rooms/" + room_id,
@@ -13,12 +13,15 @@ module Vonage
13
13
 
14
14
  # Return a list of recordings for a specified session.
15
15
  #
16
+ # @deprecated
17
+ #
16
18
  # @param [required, String] session_id The id of the session for which the recordings list should be returned
17
19
  #
18
20
  # @return [ListResponse]
19
21
  #
20
22
  # @see https://developer.vonage.com/en/api/meetings#getSessionRecordings
21
23
  def list_recordings(session_id:)
24
+ logger.info('This method is deprecated and will be removed in a future release.')
22
25
  request(
23
26
  "/v1/meetings/sessions/" + session_id + "/recordings",
24
27
  response_class: ListResponse
@@ -13,26 +13,34 @@ module Vonage
13
13
 
14
14
  # Get a list of themes associated with the Vonage application.
15
15
  #
16
+ # @deprecated
17
+ #
16
18
  # @return [ListResponse]
17
19
  #
18
20
  # @see https://developer.vonage.com/en/api/meetings#getThemes
19
21
  def list
22
+ logger.info('This method is deprecated and will be removed in a future release.')
20
23
  request("/v1/meetings/themes", response_class: ListResponse)
21
24
  end
22
25
 
23
26
  # Return information for specified theme.
24
27
  #
28
+ # @deprecated
29
+ #
25
30
  # @param [required, String] theme_id The id of the theme for which the info should be returned
26
31
  #
27
32
  # @return [Response]
28
33
  #
29
34
  # @see https://developer.vonage.com/en/api/meetings#getThemeById
30
35
  def info(theme_id:)
36
+ logger.info('This method is deprecated and will be removed in a future release.')
31
37
  request("/v1/meetings/themes/" + theme_id)
32
38
  end
33
39
 
34
40
  # Create a new theme.
35
41
  #
42
+ # @deprecated
43
+ #
36
44
  # @param [required, String] :main_color
37
45
  # The main color that will be used for the meeting room.
38
46
  #
@@ -49,6 +57,7 @@ module Vonage
49
57
  #
50
58
  # @see https://developer.vonage.com/en/api/meetings#createTheme
51
59
  def create(main_color:, brand_text:, **params)
60
+ logger.info('This method is deprecated and will be removed in a future release.')
52
61
  request(
53
62
  "/v1/meetings/themes",
54
63
  params: params.merge(main_color: main_color, brand_text: brand_text),
@@ -58,6 +67,8 @@ module Vonage
58
67
 
59
68
  # Update an existing theme.
60
69
  #
70
+ # @deprecated
71
+ #
61
72
  # @param [required, String] theme_id The id of the theme to be updated
62
73
  #
63
74
  # @param [required, String] :main_color
@@ -76,6 +87,7 @@ module Vonage
76
87
  #
77
88
  # @see https://developer.vonage.com/en/api/meetings#updateTheme
78
89
  def update(theme_id:, **params)
90
+ logger.info('This method is deprecated and will be removed in a future release.')
79
91
  request(
80
92
  "/v1/meetings/themes/" + theme_id,
81
93
  params: {
@@ -87,6 +99,8 @@ module Vonage
87
99
 
88
100
  # Delete an existing theme.
89
101
  #
102
+ # @deprecated
103
+ #
90
104
  # @param [required, String] :theme_id The id of the theme to be deleted
91
105
  #
92
106
  # @param [optional, Boolean] :force. Set to `true` to force delete a theme currently being used for a room, or as
@@ -96,6 +110,7 @@ module Vonage
96
110
  #
97
111
  # @see https://developer.vonage.com/en/api/meetings#deleteTheme
98
112
  def delete(theme_id:, force: false)
113
+ logger.info('This method is deprecated and will be removed in a future release.')
99
114
  request(
100
115
  "/v1/meetings/themes/" + theme_id + "?force=#{force}",
101
116
  type: Delete
@@ -104,6 +119,8 @@ module Vonage
104
119
 
105
120
  # Get a list of rooms that are associated with a theme id.
106
121
  #
122
+ # @deprecated
123
+ #
107
124
  # @param [required, String] theme_id THe ID of the theme to search for rooms associated with.
108
125
  #
109
126
  # @param [optional, Integer] :start_id
@@ -116,6 +133,7 @@ module Vonage
116
133
  #
117
134
  # @see https://developer.vonage.com/en/api/meetings#getRoomsByThemeId
118
135
  def list_rooms(theme_id:, **params)
136
+ logger.info('This method is deprecated and will be removed in a future release.')
119
137
  path = "/v1/meetings/themes/" + theme_id + "/rooms"
120
138
  path += "?#{Params.encode(params)}" unless params.empty?
121
139
 
@@ -124,6 +142,8 @@ module Vonage
124
142
 
125
143
  # Set a logo for a theme.
126
144
  #
145
+ # @deprecated
146
+ #
127
147
  # @param [required, String] :theme_id The ID of the theme for which the logo should be set
128
148
  #
129
149
  # @param [required, String] :filepath
@@ -146,6 +166,7 @@ module Vonage
146
166
  #
147
167
  # TODO: add type signature
148
168
  def set_logo(theme_id:, filepath:, logo_type:)
169
+ logger.info('This method is deprecated and will be removed in a future release.')
149
170
  pn = Pathname.new(filepath)
150
171
  valid_logo_types = ['white', 'colored', 'favicon']
151
172
  raise ArgumentError, ':filepath not for a file' unless pn.file?
@@ -5,33 +5,45 @@ module Vonage
5
5
  class Meetings < Namespace
6
6
  extend T::Sig
7
7
 
8
+ # @deprecated
8
9
  sig { returns(T.nilable(Vonage::Meetings::Rooms)) }
9
10
  def rooms
11
+ logger.info('This method is deprecated and will be removed in a future release.')
10
12
  @rooms ||= Rooms.new(@config)
11
13
  end
12
14
 
15
+ # @deprecated
13
16
  sig { returns(T.nilable(Vonage::Meetings::Recordings)) }
14
17
  def recordings
18
+ logger.info('This method is deprecated and will be removed in a future release.')
15
19
  @recordings ||= Recordings.new(@config)
16
20
  end
17
21
 
22
+ # @deprecated
18
23
  sig { returns(T.nilable(Vonage::Meetings::Sessions)) }
19
24
  def sessions
25
+ logger.info('This method is deprecated and will be removed in a future release.')
20
26
  @sessions ||= Sessions.new(@config)
21
27
  end
22
28
 
29
+ # @deprecated
23
30
  sig { returns(T.nilable(Vonage::Meetings::Themes)) }
24
31
  def themes
32
+ logger.info('This method is deprecated and will be removed in a future release.')
25
33
  @themes ||= Themes.new(@config)
26
34
  end
27
35
 
36
+ # @deprecated
28
37
  sig { returns(T.nilable(Vonage::Meetings::Applications)) }
29
38
  def applications
39
+ logger.info('This method is deprecated and will be removed in a future release.')
30
40
  @applications ||= Applications.new(@config)
31
41
  end
32
42
 
43
+ # @deprecated
33
44
  sig { returns(T.nilable(Vonage::Meetings::DialInNumbers)) }
34
45
  def dial_in_numbers
46
+ logger.info('This method is deprecated and will be removed in a future release.')
35
47
  @dial_in_numbers ||= DialInNumbers.new(@config)
36
48
  end
37
49
  end
@@ -0,0 +1,42 @@
1
+ # typed: true
2
+
3
+ module Vonage
4
+ class Messaging::Channels::RCS < Messaging::Message
5
+ MESSAGE_TYPES = ['text', 'image', 'video', 'file', 'custom']
6
+
7
+ attr_reader :data
8
+
9
+ def initialize(attributes = {})
10
+ @type = attributes.fetch(:type, nil)
11
+ @message = attributes.fetch(:message, nil)
12
+ @opts = attributes.fetch(:opts, {})
13
+ @data = {}
14
+
15
+ after_initialize!
16
+ end
17
+
18
+ private
19
+
20
+ def build
21
+ data[:channel] = 'rcs'
22
+ super
23
+ end
24
+
25
+ def verify_type
26
+ raise ClientError.new("Invalid message type") unless MESSAGE_TYPES.include?(type)
27
+ end
28
+
29
+ def verify_message
30
+ case type
31
+ when 'text'
32
+ raise Vonage::ClientError.new("Invalid parameter type. `:message` must be a String") unless message.is_a? String
33
+ when 'custom'
34
+ raise Vonage::ClientError.new("Invalid parameter type. `:message` must be a Hash") unless message.is_a? Hash
35
+ raise Vonage::ClientError.new("Invalid parameter content. `:message` must not be empty") if message.empty?
36
+ else
37
+ raise Vonage::ClientError.new("Invalid parameter type. `:message` must be a Hash") unless message.is_a? Hash
38
+ raise Vonage::ClientError.new("Missing parameter. `:message` must contain a `:url` key") unless message[:url]
39
+ end
40
+ end
41
+ end
42
+ end
@@ -5,6 +5,7 @@ module Vonage
5
5
  CHANNELS = {
6
6
  sms: Vonage::Messaging::Channels::SMS,
7
7
  mms: Vonage::Messaging::Channels::MMS,
8
+ rcs: Vonage::Messaging::Channels::RCS,
8
9
  whatsapp: Vonage::Messaging::Channels::WhatsApp,
9
10
  messenger: Vonage::Messaging::Channels::Messenger,
10
11
  viber: Vonage::Messaging::Channels::Viber
@@ -25,12 +25,26 @@ module Vonage
25
25
  # @option params [required, Hash] **message
26
26
  # The Vonage Message object to use for this message.
27
27
  #
28
- # @see https://developer.vonage.com/api/messages-olympus#SendMessage
28
+ # @see https://developer.vonage.com/api/messages#SendMessage
29
29
  #
30
30
  def send(to:, from:, **message)
31
31
  request('/v1/messages', params: {to: to, from: from, **message}, type: Post)
32
32
  end
33
33
 
34
+ # Update a Message Object.
35
+ #
36
+ # @example
37
+ # message = client.messaging.update(message_uuid: "aaaaaaaa-bbbb-4ccc-8ddd-0123456789ab", status: "read")
38
+ #
39
+ # @option params [required, String] :message_uuid. the UUID of the message to update.
40
+ #
41
+ # `:message_uuid` is always required. Other parameters will depend on the message channel and the specific action being performed.
42
+ # @see https://developer.vonage.com/api/messages#UpdateMessage
43
+ #
44
+ def update(message_uuid:, **params)
45
+ request("/v1/messages/#{message_uuid}", params: params, type: Patch)
46
+ end
47
+
34
48
  # Validate a JSON Web Token from a Messages API Webhook.
35
49
  #
36
50
  # @param [String, required] :token The JWT from the Webhook's Authorization header
@@ -17,6 +17,8 @@ module Vonage
17
17
  # puts "#{item.msisdn} #{item.country} #{item.type}"
18
18
  # end
19
19
  #
20
+ # @param [Hash] params
21
+ #
20
22
  # @option params [String] :application_id
21
23
  # The application that you want to return the numbers for.
22
24
  #
@@ -47,8 +49,6 @@ module Vonage
47
49
  # Set this to `true` to auto-advance through all the pages in the record
48
50
  # and collect all the data. The default is `false`.
49
51
  #
50
- # @param [Hash] params
51
- #
52
52
  # @return [ListResponse]
53
53
  #
54
54
  # @see https://developer.nexmo.com/api/developer/numbers#getOwnedNumbers
@@ -65,6 +65,8 @@ module Vonage
65
65
  # puts "#{item.msisdn} #{item.type} #{item.cost}"
66
66
  # end
67
67
  #
68
+ # @param [Hash] params
69
+ #
68
70
  # @option params [required, String] :country
69
71
  # The two character country code in ISO 3166-1 alpha-2 format.
70
72
  #
@@ -82,7 +84,7 @@ module Vonage
82
84
  # - `2` - Search for numbers that end with **:pattern**
83
85
  #
84
86
  # @option params [String] :features
85
- # Available features are `SMS` and `VOICE`.
87
+ # Available features are `SMS`, `MMS`, and `VOICE`.
86
88
  # To look for numbers that support both, use a comma-separated value: `SMS,VOICE`.
87
89
  #
88
90
  # @option params [Integer] :size
@@ -95,8 +97,6 @@ module Vonage
95
97
  # Set this to `true` to auto-advance through all the pages in the record
96
98
  # and collect all the data. The default is `false`.
97
99
  #
98
- # @param [Hash] params
99
- #
100
100
  # @return [ListResponse]
101
101
  #
102
102
  # @see https://developer.nexmo.com/api/developer/numbers#getAvailableNumbers
@@ -110,6 +110,8 @@ module Vonage
110
110
  # @example
111
111
  # response = client.numbers.buy(country: 'GB', msisdn: '447700900000')
112
112
  #
113
+ # @param [Hash] params
114
+ #
113
115
  # @option params [required, String] :country
114
116
  # The two character country code in ISO 3166-1 alpha-2 format.
115
117
  #
@@ -120,8 +122,6 @@ module Vonage
120
122
  # If you'd like to perform an action on a subaccount, provide the `api_key` of that account here.
121
123
  # If you'd like to perform an action on your own account, you do not need to provide this field.
122
124
  #
123
- # @param [Hash] params
124
- #
125
125
  # @return [Response]
126
126
  #
127
127
  # @see https://developer.nexmo.com/api/developer/numbers#buyANumber
@@ -140,6 +140,8 @@ module Vonage
140
140
  # @example
141
141
  # response = client.numbers.cancel(country: 'GB', msisdn: '447700900000')
142
142
  #
143
+ # @param [Hash] params
144
+ #
143
145
  # @option params [required, String] :country
144
146
  # The two character country code in ISO 3166-1 alpha-2 format.
145
147
  #
@@ -150,8 +152,6 @@ module Vonage
150
152
  # If you'd like to perform an action on a subaccount, provide the `api_key` of that account here.
151
153
  # If you'd like to perform an action on your own account, you do not need to provide this field.
152
154
  #
153
- # @param [Hash] params
154
- #
155
155
  # @return [Response]
156
156
  #
157
157
  # @see https://developer.nexmo.com/api/developer/numbers#cancelANumber
@@ -177,6 +177,8 @@ module Vonage
177
177
  #
178
178
  # response = client.numbers.update(params)
179
179
  #
180
+ # @param [Hash] params
181
+ #
180
182
  # @option params [required, String] :country
181
183
  # The two character country code in ISO 3166-1 alpha-2 format.
182
184
  #
@@ -203,8 +205,6 @@ module Vonage
203
205
  # @option params [String] :voice_status_callback
204
206
  # A webhook URI for Vonage to send a request to when a call ends.
205
207
  #
206
- # @param [Hash] params
207
- #
208
208
  # @return [Response]
209
209
  #
210
210
  # @see https://developer.nexmo.com/api/developer/numbers#updateANumber
@@ -11,6 +11,8 @@ module Vonage
11
11
 
12
12
  # Find all events
13
13
  #
14
+ # @deprecated
15
+ #
14
16
  # @example
15
17
  # response = proactive_connect.events.list
16
18
  #
@@ -59,6 +61,7 @@ module Vonage
59
61
  # @see https://developer.vonage.com/en/api/proactive-connect#eventsFindAll
60
62
  #
61
63
  def list(**params)
64
+ logger.info('This method is deprecated and will be removed in a future release.')
62
65
  path = "/v0.1/bulk/events"
63
66
  path += "?#{Params.encode(params)}" unless params.empty?
64
67