twilio-ruby 5.0.0.rc9 → 5.0.0.rc10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (132) hide show
  1. checksums.yaml +4 -4
  2. data/lib/twilio-ruby/rest/api/v2010/account/address/dependent_phone_number.rb +2 -9
  3. data/lib/twilio-ruby/rest/api/v2010/account/address.rb +13 -24
  4. data/lib/twilio-ruby/rest/api/v2010/account/application.rb +12 -23
  5. data/lib/twilio-ruby/rest/api/v2010/account/authorized_connect_app.rb +6 -15
  6. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/local.rb +2 -9
  7. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/mobile.rb +2 -9
  8. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number/toll_free.rb +2 -9
  9. data/lib/twilio-ruby/rest/api/v2010/account/available_phone_number.rb +9 -18
  10. data/lib/twilio-ruby/rest/api/v2010/account/call/feedback.rb +15 -23
  11. data/lib/twilio-ruby/rest/api/v2010/account/call/feedback_summary.rb +8 -15
  12. data/lib/twilio-ruby/rest/api/v2010/account/call/notification.rb +9 -18
  13. data/lib/twilio-ruby/rest/api/v2010/account/call/recording.rb +9 -18
  14. data/lib/twilio-ruby/rest/api/v2010/account/call.rb +20 -28
  15. data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +15 -24
  16. data/lib/twilio-ruby/rest/api/v2010/account/conference.rb +7 -16
  17. data/lib/twilio-ruby/rest/api/v2010/account/connect_app.rb +10 -20
  18. data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/local.rb +2 -10
  19. data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/mobile.rb +2 -10
  20. data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number/toll_free.rb +2 -10
  21. data/lib/twilio-ruby/rest/api/v2010/account/incoming_phone_number.rb +12 -23
  22. data/lib/twilio-ruby/rest/api/v2010/account/key.rb +324 -0
  23. data/lib/twilio-ruby/rest/api/v2010/account/message/feedback.rb +4 -9
  24. data/lib/twilio-ruby/rest/api/v2010/account/message/media.rb +9 -18
  25. data/lib/twilio-ruby/rest/api/v2010/account/message.rb +23 -29
  26. data/lib/twilio-ruby/rest/api/v2010/account/new_key.rb +145 -0
  27. data/lib/twilio-ruby/rest/api/v2010/account/new_signing_key.rb +145 -0
  28. data/lib/twilio-ruby/rest/api/v2010/account/notification.rb +7 -16
  29. data/lib/twilio-ruby/rest/api/v2010/account/outgoing_caller_id.rb +12 -21
  30. data/lib/twilio-ruby/rest/api/v2010/account/queue/member.rb +13 -23
  31. data/lib/twilio-ruby/rest/api/v2010/account/queue.rb +13 -24
  32. data/lib/twilio-ruby/rest/api/v2010/account/recording/transcription.rb +9 -18
  33. data/lib/twilio-ruby/rest/api/v2010/account/recording.rb +8 -17
  34. data/lib/twilio-ruby/rest/api/v2010/account/sandbox.rb +8 -15
  35. data/lib/twilio-ruby/rest/api/v2010/account/signing_key.rb +324 -0
  36. data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list/credential.rb +16 -27
  37. data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list.rb +14 -24
  38. data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/credential_list_mapping.rb +11 -21
  39. data/lib/twilio-ruby/rest/api/v2010/account/sip/domain/ip_access_control_list_mapping.rb +11 -21
  40. data/lib/twilio-ruby/rest/api/v2010/account/sip/domain.rb +23 -31
  41. data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list/ip_address.rb +16 -27
  42. data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list.rb +14 -24
  43. data/lib/twilio-ruby/rest/api/v2010/account/sip.rb +1 -8
  44. data/lib/twilio-ruby/rest/api/v2010/account/sms/short_code.rb +10 -20
  45. data/lib/twilio-ruby/rest/api/v2010/account/sms/sms_message.rb +13 -23
  46. data/lib/twilio-ruby/rest/api/v2010/account/sms.rb +1 -7
  47. data/lib/twilio-ruby/rest/api/v2010/account/token.rb +2 -7
  48. data/lib/twilio-ruby/rest/api/v2010/account/transcription.rb +7 -16
  49. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/all_time.rb +1 -8
  50. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/daily.rb +1 -8
  51. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/last_month.rb +1 -8
  52. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/monthly.rb +1 -8
  53. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/this_month.rb +1 -8
  54. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/today.rb +1 -8
  55. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yearly.rb +1 -8
  56. data/lib/twilio-ruby/rest/api/v2010/account/usage/record/yesterday.rb +1 -8
  57. data/lib/twilio-ruby/rest/api/v2010/account/usage/record.rb +1 -8
  58. data/lib/twilio-ruby/rest/api/v2010/account/usage/trigger.rb +12 -23
  59. data/lib/twilio-ruby/rest/api/v2010/account/usage.rb +1 -6
  60. data/lib/twilio-ruby/rest/api/v2010/account/validation_request.rb +2 -7
  61. data/lib/twilio-ruby/rest/api/v2010/account.rb +131 -38
  62. data/lib/twilio-ruby/rest/api/v2010.rb +17 -1
  63. data/lib/twilio-ruby/rest/api.rb +16 -0
  64. data/lib/twilio-ruby/rest/client.rb +16 -0
  65. data/lib/twilio-ruby/rest/ip_messaging/v1/credential.rb +13 -28
  66. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/member.rb +11 -21
  67. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel/message.rb +62 -20
  68. data/lib/twilio-ruby/rest/ip_messaging/v1/service/channel.rb +17 -28
  69. data/lib/twilio-ruby/rest/ip_messaging/v1/service/role.rb +12 -23
  70. data/lib/twilio-ruby/rest/ip_messaging/v1/service/user.rb +23 -25
  71. data/lib/twilio-ruby/rest/ip_messaging/v1/service.rb +13 -24
  72. data/lib/twilio-ruby/rest/ip_messaging/v1.rb +1 -1
  73. data/lib/twilio-ruby/rest/lookups/v1/phone_number.rb +5 -12
  74. data/lib/twilio-ruby/rest/lookups/v1.rb +1 -1
  75. data/lib/twilio-ruby/rest/monitor/v1/alert.rb +5 -14
  76. data/lib/twilio-ruby/rest/monitor/v1/event.rb +4 -13
  77. data/lib/twilio-ruby/rest/monitor/v1.rb +1 -1
  78. data/lib/twilio-ruby/rest/notifications/v1/credential.rb +13 -28
  79. data/lib/twilio-ruby/rest/notifications/v1/service/binding.rb +8 -18
  80. data/lib/twilio-ruby/rest/notifications/v1/service/notification.rb +8 -8
  81. data/lib/twilio-ruby/rest/notifications/v1/service.rb +10 -21
  82. data/lib/twilio-ruby/rest/notifications/v1.rb +1 -1
  83. data/lib/twilio-ruby/rest/preview/wireless/command.rb +4 -14
  84. data/lib/twilio-ruby/rest/preview/wireless/device/usage.rb +6 -13
  85. data/lib/twilio-ruby/rest/preview/wireless/device.rb +8 -19
  86. data/lib/twilio-ruby/rest/preview/wireless/rate_plan.rb +4 -13
  87. data/lib/twilio-ruby/rest/preview/wireless.rb +1 -1
  88. data/lib/twilio-ruby/rest/pricing/v1/messaging/country.rb +4 -13
  89. data/lib/twilio-ruby/rest/pricing/v1/messaging.rb +0 -5
  90. data/lib/twilio-ruby/rest/pricing/v1/phone_number/country.rb +4 -13
  91. data/lib/twilio-ruby/rest/pricing/v1/phone_number.rb +0 -5
  92. data/lib/twilio-ruby/rest/pricing/v1/voice/country.rb +4 -13
  93. data/lib/twilio-ruby/rest/pricing/v1/voice/number.rb +4 -10
  94. data/lib/twilio-ruby/rest/pricing/v1/voice.rb +0 -6
  95. data/lib/twilio-ruby/rest/pricing/v1.rb +1 -1
  96. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/activity.rb +13 -23
  97. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb +6 -15
  98. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task/reservation.rb +13 -23
  99. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task.rb +13 -24
  100. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queue_statistics.rb +8 -15
  101. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue/task_queues_statistics.rb +1 -8
  102. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/task_queue.rb +13 -24
  103. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/worker_statistics.rb +8 -15
  104. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker/workers_statistics.rb +6 -13
  105. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/worker.rb +13 -24
  106. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow/workflow_statistics.rb +8 -15
  107. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workflow.rb +13 -24
  108. data/lib/twilio-ruby/rest/taskrouter/v1/workspace/workspace_statistics.rb +6 -13
  109. data/lib/twilio-ruby/rest/taskrouter/v1/workspace.rb +15 -26
  110. data/lib/twilio-ruby/rest/taskrouter/v1.rb +1 -1
  111. data/lib/twilio-ruby/rest/trunking/v1/trunk/credential_list.rb +8 -18
  112. data/lib/twilio-ruby/rest/trunking/v1/trunk/ip_access_control_list.rb +8 -18
  113. data/lib/twilio-ruby/rest/trunking/v1/trunk/origination_url.rb +12 -23
  114. data/lib/twilio-ruby/rest/trunking/v1/trunk/phone_number.rb +8 -18
  115. data/lib/twilio-ruby/rest/trunking/v1/trunk.rb +12 -23
  116. data/lib/twilio-ruby/rest/trunking/v1.rb +1 -1
  117. data/lib/twilio-ruby/version.rb +1 -1
  118. data/spec/integration/api/v2010/account/key_spec.rb +178 -0
  119. data/spec/integration/api/v2010/account/message_spec.rb +2 -3
  120. data/spec/integration/api/v2010/account/new_key_spec.rb +45 -0
  121. data/spec/integration/api/v2010/account/new_signing_key_spec.rb +45 -0
  122. data/spec/integration/api/v2010/account/signing_key_spec.rb +178 -0
  123. data/spec/integration/api/v2010/account/sip/ip_access_control_list/ip_address_spec.rb +3 -7
  124. data/spec/integration/ip_messaging/v1/credential_spec.rb +5 -10
  125. data/spec/integration/ip_messaging/v1/service/channel/message_spec.rb +37 -0
  126. data/spec/integration/ip_messaging/v1/service/channel_spec.rb +3 -7
  127. data/spec/integration/ip_messaging/v1/service/user_spec.rb +3 -6
  128. data/spec/integration/notifications/v1/credential_spec.rb +5 -10
  129. data/spec/integration/notifications/v1/service/notification_spec.rb +1 -0
  130. data/spec/integration/preview/wireless/device_spec.rb +4 -4
  131. data/spec/integration/taskrouter/v1/workspace/task/reservation_spec.rb +3 -6
  132. metadata +15 -3
@@ -36,7 +36,7 @@ module Twilio
36
36
  ##
37
37
  # Provide a user friendly representation
38
38
  def to_s
39
- #<Twilio::REST::Notifications::V1>
39
+ '<Twilio::REST::Notifications::V1>'
40
40
  end
41
41
  end
42
42
  end
@@ -12,7 +12,6 @@ module Twilio
12
12
  ##
13
13
  # Initialize the CommandList
14
14
  # @param [Version] version Version that contains the resource
15
-
16
15
  # @return [CommandList] CommandList
17
16
  def initialize(version)
18
17
  super(version)
@@ -35,7 +34,6 @@ module Twilio
35
34
  # the default value of 50 records. If no page_size is defined
36
35
  # but a limit is defined, stream() will attempt to read the
37
36
  # limit with the most efficient page size, i.e. min(limit, 1000)
38
-
39
37
  # @return [Array] Array of up to limit results
40
38
  def list(device: nil, status: nil, direction: nil, limit: nil, page_size: nil)
41
39
  self.stream(
@@ -60,7 +58,6 @@ module Twilio
60
58
  # the default value of 50 records. If no page_size is defined
61
59
  # but a limit is defined, stream() will attempt to read the
62
60
  # limit with the most efficient page size, i.e. min(limit, 1000)
63
-
64
61
  # @return [Enumerable] Enumerable that will yield up to limit results
65
62
  def stream(device: nil, status: nil, direction: nil, limit: nil, page_size: nil)
66
63
  limits = @version.read_limits(limit, page_size)
@@ -109,7 +106,6 @@ module Twilio
109
106
  # @param [String] page_token PageToken provided by the API
110
107
  # @param [Integer] page_number Page Number, this value is simply for client state
111
108
  # @param [Integer] page_size Number of records to return, defaults to 50
112
-
113
109
  # @return [Page] Page of CommandInstance
114
110
  def page(device: nil, status: nil, direction: nil, page_token: nil, page_number: nil, page_size: nil)
115
111
  params = {
@@ -135,7 +131,6 @@ module Twilio
135
131
  # @param [String] command The command
136
132
  # @param [String] callback_method The callback_method
137
133
  # @param [String] callback_url The callback_url
138
-
139
134
  # @return [CommandInstance] Newly created CommandInstance
140
135
  def create(device: nil, command: nil, callback_method: nil, callback_url: nil)
141
136
  data = {
@@ -170,7 +165,6 @@ module Twilio
170
165
  # @param [Version] version Version that contains the resource
171
166
  # @param [Response] response Response from the API
172
167
  # @param [Hash] solution Path solution for the resource
173
-
174
168
  # @return [CommandPage] CommandPage
175
169
  def initialize(version, response, solution)
176
170
  super(version, response)
@@ -182,7 +176,6 @@ module Twilio
182
176
  ##
183
177
  # Build an instance of CommandInstance
184
178
  # @param [Hash] payload Payload response from the API
185
-
186
179
  # @return [CommandInstance] CommandInstance
187
180
  def get_instance(payload)
188
181
  return CommandInstance.new(
@@ -203,7 +196,6 @@ module Twilio
203
196
  # Initialize the CommandContext
204
197
  # @param [Version] version Version that contains the resource
205
198
  # @param [String] sid The sid
206
-
207
199
  # @return [CommandContext] CommandContext
208
200
  def initialize(version, sid)
209
201
  super(version)
@@ -230,7 +222,7 @@ module Twilio
230
222
  return CommandInstance.new(
231
223
  @version,
232
224
  payload,
233
- sid: @solution['sid'],
225
+ sid: @solution[:sid],
234
226
  )
235
227
  end
236
228
 
@@ -248,7 +240,6 @@ module Twilio
248
240
  # @param [Version] version Version that contains the resource
249
241
  # @param [Hash] payload payload that contains response from Twilio
250
242
  # @param [String] sid The sid
251
-
252
243
  # @return [CommandInstance] CommandInstance
253
244
  def initialize(version, payload, sid: nil)
254
245
  super(version)
@@ -277,7 +268,6 @@ module Twilio
277
268
  # Generate an instance context for the instance, the context is capable of
278
269
  # performing various actions. All instance actions are proxied to the context
279
270
  # @param [Version] version Version that contains the resource
280
-
281
271
  # @return [CommandContext] CommandContext for this CommandInstance
282
272
  def context
283
273
  unless @instance_context
@@ -329,14 +319,14 @@ module Twilio
329
319
  # Fetch a CommandInstance
330
320
  # @return [CommandInstance] Fetched CommandInstance
331
321
  def fetch
332
- @context.fetch()
322
+ context.fetch
333
323
  end
334
324
 
335
325
  ##
336
326
  # Provide a user friendly representation
337
327
  def to_s
338
- context = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
339
- "<Twilio.Preview.Wireless.CommandInstance #{context}>"
328
+ values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
329
+ "<Twilio.Preview.Wireless.CommandInstance #{values}>"
340
330
  end
341
331
  end
342
332
  end
@@ -14,7 +14,6 @@ module Twilio
14
14
  # Initialize the UsageList
15
15
  # @param [Version] version Version that contains the resource
16
16
  # @param [String] device_sid The device_sid
17
-
18
17
  # @return [UsageList] UsageList
19
18
  def initialize(version, device_sid: nil)
20
19
  super(version)
@@ -39,7 +38,6 @@ module Twilio
39
38
  # @param [Response] response Response from the API
40
39
  # @param [Hash] solution Path solution for the resource
41
40
  # @param [String] device_sid The device_sid
42
-
43
41
  # @return [UsagePage] UsagePage
44
42
  def initialize(version, response, solution)
45
43
  super(version, response)
@@ -51,13 +49,12 @@ module Twilio
51
49
  ##
52
50
  # Build an instance of UsageInstance
53
51
  # @param [Hash] payload Payload response from the API
54
-
55
52
  # @return [UsageInstance] UsageInstance
56
53
  def get_instance(payload)
57
54
  return UsageInstance.new(
58
55
  @version,
59
56
  payload,
60
- device_sid: @solution['device_sid'],
57
+ device_sid: @solution[:device_sid],
61
58
  )
62
59
  end
63
60
 
@@ -73,7 +70,6 @@ module Twilio
73
70
  # Initialize the UsageContext
74
71
  # @param [Version] version Version that contains the resource
75
72
  # @param [String] device_sid The device_sid
76
-
77
73
  # @return [UsageContext] UsageContext
78
74
  def initialize(version, device_sid)
79
75
  super(version)
@@ -89,7 +85,6 @@ module Twilio
89
85
  # Fetch a UsageInstance
90
86
  # @param [String] end_ The end
91
87
  # @param [String] start The start
92
-
93
88
  # @return [UsageInstance] Fetched UsageInstance
94
89
  def fetch(end_: nil, start: nil)
95
90
  params = {
@@ -106,7 +101,7 @@ module Twilio
106
101
  return UsageInstance.new(
107
102
  @version,
108
103
  payload,
109
- device_sid: @solution['device_sid'],
104
+ device_sid: @solution[:device_sid],
110
105
  )
111
106
  end
112
107
 
@@ -124,7 +119,6 @@ module Twilio
124
119
  # @param [Version] version Version that contains the resource
125
120
  # @param [Hash] payload payload that contains response from Twilio
126
121
  # @param [String] device_sid The device_sid
127
-
128
122
  # @return [UsageInstance] UsageInstance
129
123
  def initialize(version, payload, device_sid: nil)
130
124
  super(version)
@@ -153,7 +147,6 @@ module Twilio
153
147
  # Generate an instance context for the instance, the context is capable of
154
148
  # performing various actions. All instance actions are proxied to the context
155
149
  # @param [Version] version Version that contains the resource
156
-
157
150
  # @return [UsageContext] UsageContext for this UsageInstance
158
151
  def context
159
152
  unless @instance_context
@@ -205,10 +198,10 @@ module Twilio
205
198
  # Fetch a UsageInstance
206
199
  # @param [String] end_ The end
207
200
  # @param [String] start The start
208
-
209
201
  # @return [UsageInstance] Fetched UsageInstance
210
202
  def fetch(end_: nil, start: nil)
211
- @context.fetch(
203
+ context.fetch(
204
+ end_: end_,
212
205
  start: start,
213
206
  )
214
207
  end
@@ -216,8 +209,8 @@ module Twilio
216
209
  ##
217
210
  # Provide a user friendly representation
218
211
  def to_s
219
- context = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
220
- "<Twilio.Preview.Wireless.UsageInstance #{context}>"
212
+ values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
213
+ "<Twilio.Preview.Wireless.UsageInstance #{values}>"
221
214
  end
222
215
  end
223
216
  end
@@ -12,7 +12,6 @@ module Twilio
12
12
  ##
13
13
  # Initialize the DeviceList
14
14
  # @param [Version] version Version that contains the resource
15
-
16
15
  # @return [DeviceList] DeviceList
17
16
  def initialize(version)
18
17
  super(version)
@@ -35,7 +34,6 @@ module Twilio
35
34
  # the default value of 50 records. If no page_size is defined
36
35
  # but a limit is defined, stream() will attempt to read the
37
36
  # limit with the most efficient page size, i.e. min(limit, 1000)
38
-
39
37
  # @return [Array] Array of up to limit results
40
38
  def list(status: nil, sim_identifier: nil, rate_plan: nil, limit: nil, page_size: nil)
41
39
  self.stream(
@@ -60,7 +58,6 @@ module Twilio
60
58
  # the default value of 50 records. If no page_size is defined
61
59
  # but a limit is defined, stream() will attempt to read the
62
60
  # limit with the most efficient page size, i.e. min(limit, 1000)
63
-
64
61
  # @return [Enumerable] Enumerable that will yield up to limit results
65
62
  def stream(status: nil, sim_identifier: nil, rate_plan: nil, limit: nil, page_size: nil)
66
63
  limits = @version.read_limits(limit, page_size)
@@ -109,7 +106,6 @@ module Twilio
109
106
  # @param [String] page_token PageToken provided by the API
110
107
  # @param [Integer] page_number Page Number, this value is simply for client state
111
108
  # @param [Integer] page_size Number of records to return, defaults to 50
112
-
113
109
  # @return [Page] Page of DeviceInstance
114
110
  def page(status: nil, sim_identifier: nil, rate_plan: nil, page_token: nil, page_number: nil, page_size: nil)
115
111
  params = {
@@ -140,7 +136,6 @@ module Twilio
140
136
  # @param [String] status The status
141
137
  # @param [String] commands_callback_method The commands_callback_method
142
138
  # @param [String] commands_callback_url The commands_callback_url
143
-
144
139
  # @return [DeviceInstance] Newly created DeviceInstance
145
140
  def create(rate_plan: nil, alias_: nil, callback_method: nil, callback_url: nil, friendly_name: nil, sim_identifier: nil, status: nil, commands_callback_method: nil, commands_callback_url: nil)
146
141
  data = {
@@ -180,7 +175,6 @@ module Twilio
180
175
  # @param [Version] version Version that contains the resource
181
176
  # @param [Response] response Response from the API
182
177
  # @param [Hash] solution Path solution for the resource
183
-
184
178
  # @return [DevicePage] DevicePage
185
179
  def initialize(version, response, solution)
186
180
  super(version, response)
@@ -192,7 +186,6 @@ module Twilio
192
186
  ##
193
187
  # Build an instance of DeviceInstance
194
188
  # @param [Hash] payload Payload response from the API
195
-
196
189
  # @return [DeviceInstance] DeviceInstance
197
190
  def get_instance(payload)
198
191
  return DeviceInstance.new(
@@ -213,7 +206,6 @@ module Twilio
213
206
  # Initialize the DeviceContext
214
207
  # @param [Version] version Version that contains the resource
215
208
  # @param [String] sid The sid
216
-
217
209
  # @return [DeviceContext] DeviceContext
218
210
  def initialize(version, sid)
219
211
  super(version)
@@ -243,7 +235,7 @@ module Twilio
243
235
  return DeviceInstance.new(
244
236
  @version,
245
237
  payload,
246
- sid: @solution['sid'],
238
+ sid: @solution[:sid],
247
239
  )
248
240
  end
249
241
 
@@ -257,7 +249,6 @@ module Twilio
257
249
  # @param [String] status The status
258
250
  # @param [String] commands_callback_method The commands_callback_method
259
251
  # @param [String] commands_callback_url The commands_callback_url
260
-
261
252
  # @return [DeviceInstance] Updated DeviceInstance
262
253
  def update(alias_: nil, callback_method: nil, callback_url: nil, friendly_name: nil, sim_identifier: nil, status: nil, commands_callback_method: nil, commands_callback_url: nil)
263
254
  data = {
@@ -280,7 +271,7 @@ module Twilio
280
271
  return DeviceInstance.new(
281
272
  @version,
282
273
  payload,
283
- sid: @solution['sid'],
274
+ sid: @solution[:sid],
284
275
  )
285
276
  end
286
277
 
@@ -308,7 +299,6 @@ module Twilio
308
299
  # @param [Version] version Version that contains the resource
309
300
  # @param [Hash] payload payload that contains response from Twilio
310
301
  # @param [String] sid The sid
311
-
312
302
  # @return [DeviceInstance] DeviceInstance
313
303
  def initialize(version, payload, sid: nil)
314
304
  super(version)
@@ -341,7 +331,6 @@ module Twilio
341
331
  # Generate an instance context for the instance, the context is capable of
342
332
  # performing various actions. All instance actions are proxied to the context
343
333
  # @param [Version] version Version that contains the resource
344
-
345
334
  # @return [DeviceContext] DeviceContext for this DeviceInstance
346
335
  def context
347
336
  unless @instance_context
@@ -409,7 +398,7 @@ module Twilio
409
398
  # Fetch a DeviceInstance
410
399
  # @return [DeviceInstance] Fetched DeviceInstance
411
400
  def fetch
412
- @context.fetch()
401
+ context.fetch
413
402
  end
414
403
 
415
404
  ##
@@ -422,10 +411,10 @@ module Twilio
422
411
  # @param [String] status The status
423
412
  # @param [String] commands_callback_method The commands_callback_method
424
413
  # @param [String] commands_callback_url The commands_callback_url
425
-
426
414
  # @return [DeviceInstance] Updated DeviceInstance
427
415
  def update(alias_: nil, callback_method: nil, callback_url: nil, friendly_name: nil, sim_identifier: nil, status: nil, commands_callback_method: nil, commands_callback_url: nil)
428
- @context.update(
416
+ context.update(
417
+ alias_: alias_,
429
418
  callback_method: callback_method,
430
419
  callback_url: callback_url,
431
420
  friendly_name: friendly_name,
@@ -440,14 +429,14 @@ module Twilio
440
429
  # Access the usage
441
430
  # @return [usage] usage
442
431
  def usage
443
- @context.usage
432
+ context.usage
444
433
  end
445
434
 
446
435
  ##
447
436
  # Provide a user friendly representation
448
437
  def to_s
449
- context = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
450
- "<Twilio.Preview.Wireless.DeviceInstance #{context}>"
438
+ values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
439
+ "<Twilio.Preview.Wireless.DeviceInstance #{values}>"
451
440
  end
452
441
  end
453
442
  end
@@ -12,7 +12,6 @@ module Twilio
12
12
  ##
13
13
  # Initialize the RatePlanList
14
14
  # @param [Version] version Version that contains the resource
15
-
16
15
  # @return [RatePlanList] RatePlanList
17
16
  def initialize(version)
18
17
  super(version)
@@ -32,7 +31,6 @@ module Twilio
32
31
  # the default value of 50 records. If no page_size is defined
33
32
  # but a limit is defined, stream() will attempt to read the
34
33
  # limit with the most efficient page size, i.e. min(limit, 1000)
35
-
36
34
  # @return [Array] Array of up to limit results
37
35
  def list(limit: nil, page_size: nil)
38
36
  self.stream(
@@ -51,7 +49,6 @@ module Twilio
51
49
  # the default value of 50 records. If no page_size is defined
52
50
  # but a limit is defined, stream() will attempt to read the
53
51
  # limit with the most efficient page size, i.e. min(limit, 1000)
54
-
55
52
  # @return [Enumerable] Enumerable that will yield up to limit results
56
53
  def stream(limit: nil, page_size: nil)
57
54
  limits = @version.read_limits(limit, page_size)
@@ -91,7 +88,6 @@ module Twilio
91
88
  # @param [String] page_token PageToken provided by the API
92
89
  # @param [Integer] page_number Page Number, this value is simply for client state
93
90
  # @param [Integer] page_size Number of records to return, defaults to 50
94
-
95
91
  # @return [Page] Page of RatePlanInstance
96
92
  def page(page_token: nil, page_number: nil, page_size: nil)
97
93
  params = {
@@ -120,7 +116,6 @@ module Twilio
120
116
  # @param [Version] version Version that contains the resource
121
117
  # @param [Response] response Response from the API
122
118
  # @param [Hash] solution Path solution for the resource
123
-
124
119
  # @return [RatePlanPage] RatePlanPage
125
120
  def initialize(version, response, solution)
126
121
  super(version, response)
@@ -132,7 +127,6 @@ module Twilio
132
127
  ##
133
128
  # Build an instance of RatePlanInstance
134
129
  # @param [Hash] payload Payload response from the API
135
-
136
130
  # @return [RatePlanInstance] RatePlanInstance
137
131
  def get_instance(payload)
138
132
  return RatePlanInstance.new(
@@ -153,7 +147,6 @@ module Twilio
153
147
  # Initialize the RatePlanContext
154
148
  # @param [Version] version Version that contains the resource
155
149
  # @param [String] sid The sid
156
-
157
150
  # @return [RatePlanContext] RatePlanContext
158
151
  def initialize(version, sid)
159
152
  super(version)
@@ -180,7 +173,7 @@ module Twilio
180
173
  return RatePlanInstance.new(
181
174
  @version,
182
175
  payload,
183
- sid: @solution['sid'],
176
+ sid: @solution[:sid],
184
177
  )
185
178
  end
186
179
 
@@ -198,7 +191,6 @@ module Twilio
198
191
  # @param [Version] version Version that contains the resource
199
192
  # @param [Hash] payload payload that contains response from Twilio
200
193
  # @param [String] sid The sid
201
-
202
194
  # @return [RatePlanInstance] RatePlanInstance
203
195
  def initialize(version, payload, sid: nil)
204
196
  super(version)
@@ -233,7 +225,6 @@ module Twilio
233
225
  # Generate an instance context for the instance, the context is capable of
234
226
  # performing various actions. All instance actions are proxied to the context
235
227
  # @param [Version] version Version that contains the resource
236
-
237
228
  # @return [RatePlanContext] RatePlanContext for this RatePlanInstance
238
229
  def context
239
230
  unless @instance_context
@@ -309,14 +300,14 @@ module Twilio
309
300
  # Fetch a RatePlanInstance
310
301
  # @return [RatePlanInstance] Fetched RatePlanInstance
311
302
  def fetch
312
- @context.fetch()
303
+ context.fetch
313
304
  end
314
305
 
315
306
  ##
316
307
  # Provide a user friendly representation
317
308
  def to_s
318
- context = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
319
- "<Twilio.Preview.Wireless.RatePlanInstance #{context}>"
309
+ values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
310
+ "<Twilio.Preview.Wireless.RatePlanInstance #{values}>"
320
311
  end
321
312
  end
322
313
  end
@@ -45,7 +45,7 @@ module Twilio
45
45
  ##
46
46
  # Provide a user friendly representation
47
47
  def to_s
48
- #<Twilio::REST::Preview::Wireless>
48
+ '<Twilio::REST::Preview::Wireless>'
49
49
  end
50
50
  end
51
51
  end
@@ -13,7 +13,6 @@ module Twilio
13
13
  ##
14
14
  # Initialize the CountryList
15
15
  # @param [Version] version Version that contains the resource
16
-
17
16
  # @return [CountryList] CountryList
18
17
  def initialize(version)
19
18
  super(version)
@@ -33,7 +32,6 @@ module Twilio
33
32
  # the default value of 50 records. If no page_size is defined
34
33
  # but a limit is defined, stream() will attempt to read the
35
34
  # limit with the most efficient page size, i.e. min(limit, 1000)
36
-
37
35
  # @return [Array] Array of up to limit results
38
36
  def list(limit: nil, page_size: nil)
39
37
  self.stream(
@@ -52,7 +50,6 @@ module Twilio
52
50
  # the default value of 50 records. If no page_size is defined
53
51
  # but a limit is defined, stream() will attempt to read the
54
52
  # limit with the most efficient page size, i.e. min(limit, 1000)
55
-
56
53
  # @return [Enumerable] Enumerable that will yield up to limit results
57
54
  def stream(limit: nil, page_size: nil)
58
55
  limits = @version.read_limits(limit, page_size)
@@ -92,7 +89,6 @@ module Twilio
92
89
  # @param [String] page_token PageToken provided by the API
93
90
  # @param [Integer] page_number Page Number, this value is simply for client state
94
91
  # @param [Integer] page_size Number of records to return, defaults to 50
95
-
96
92
  # @return [Page] Page of CountryInstance
97
93
  def page(page_token: nil, page_number: nil, page_size: nil)
98
94
  params = {
@@ -121,7 +117,6 @@ module Twilio
121
117
  # @param [Version] version Version that contains the resource
122
118
  # @param [Response] response Response from the API
123
119
  # @param [Hash] solution Path solution for the resource
124
-
125
120
  # @return [CountryPage] CountryPage
126
121
  def initialize(version, response, solution)
127
122
  super(version, response)
@@ -133,7 +128,6 @@ module Twilio
133
128
  ##
134
129
  # Build an instance of CountryInstance
135
130
  # @param [Hash] payload Payload response from the API
136
-
137
131
  # @return [CountryInstance] CountryInstance
138
132
  def get_instance(payload)
139
133
  return CountryInstance.new(
@@ -154,7 +148,6 @@ module Twilio
154
148
  # Initialize the CountryContext
155
149
  # @param [Version] version Version that contains the resource
156
150
  # @param [String] iso_country The iso_country
157
-
158
151
  # @return [CountryContext] CountryContext
159
152
  def initialize(version, iso_country)
160
153
  super(version)
@@ -181,7 +174,7 @@ module Twilio
181
174
  return CountryInstance.new(
182
175
  @version,
183
176
  payload,
184
- iso_country: @solution['iso_country'],
177
+ iso_country: @solution[:iso_country],
185
178
  )
186
179
  end
187
180
 
@@ -199,7 +192,6 @@ module Twilio
199
192
  # @param [Version] version Version that contains the resource
200
193
  # @param [Hash] payload payload that contains response from Twilio
201
194
  # @param [String] iso_country The iso_country
202
-
203
195
  # @return [CountryInstance] CountryInstance
204
196
  def initialize(version, payload, iso_country: nil)
205
197
  super(version)
@@ -225,7 +217,6 @@ module Twilio
225
217
  # Generate an instance context for the instance, the context is capable of
226
218
  # performing various actions. All instance actions are proxied to the context
227
219
  # @param [Version] version Version that contains the resource
228
-
229
220
  # @return [CountryContext] CountryContext for this CountryInstance
230
221
  def context
231
222
  unless @instance_context
@@ -265,14 +256,14 @@ module Twilio
265
256
  # Fetch a CountryInstance
266
257
  # @return [CountryInstance] Fetched CountryInstance
267
258
  def fetch
268
- @context.fetch()
259
+ context.fetch
269
260
  end
270
261
 
271
262
  ##
272
263
  # Provide a user friendly representation
273
264
  def to_s
274
- context = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
275
- "<Twilio.Pricing.V1.CountryInstance #{context}>"
265
+ values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
266
+ "<Twilio.Pricing.V1.CountryInstance #{values}>"
276
267
  end
277
268
  end
278
269
  end