bandwidth-sdk 18.3.1 → 19.0.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/Gemfile.lock +13 -13
- data/README.md +1 -10
- data/Rakefile +1 -1
- data/bandwidth.yml +285 -109
- data/coverage/.last_run.json +1 -1
- data/coverage/.resultset.json +1400 -1051
- data/coverage/index.html +20186 -16225
- data/custom_templates/api_client.mustache +3 -1
- data/custom_templates/configuration.mustache +18 -12
- data/custom_templates/gem.mustache +2 -2
- data/docs/Callback.md +1 -0
- data/docs/CallsApi.md +5 -25
- data/docs/ConferencesApi.md +9 -45
- data/docs/DisconnectCallback.md +6 -2
- data/docs/EndpointsApi.md +5 -25
- data/docs/InboundCallback.md +1 -1
- data/docs/InboundCallbackMessage.md +2 -0
- data/docs/InitiateCallback.md +1 -1
- data/docs/LookupResult.md +2 -2
- data/docs/MFAApi.md +3 -15
- data/docs/MediaApi.md +4 -20
- data/docs/Message.md +1 -1
- data/docs/MessagesApi.md +2 -10
- data/docs/MultiChannelAction.md +3 -3
- data/docs/MultiChannelActionCalendarEvent.md +3 -3
- data/docs/MultiChannelApi.md +1 -5
- data/docs/PhoneNumberLookupApi.md +3 -15
- data/docs/RbmActionBase.md +3 -3
- data/docs/RbmActionDial.md +3 -3
- data/docs/RbmActionOpenUrl.md +3 -3
- data/docs/RbmActionViewLocation.md +3 -3
- data/docs/RbmSession.md +26 -0
- data/docs/RbmSuggestionResponse.md +4 -4
- data/docs/RecordingsApi.md +10 -50
- data/docs/StatisticsApi.md +1 -5
- data/docs/StatusCallback.md +2 -2
- data/docs/StatusCallbackMessage.md +3 -1
- data/docs/TollFreeVerificationApi.md +9 -45
- data/docs/TranscriptionsApi.md +3 -15
- data/docs/TransferDisconnectCallback.md +7 -1
- data/lib/bandwidth-sdk/api/calls_api.rb +5 -5
- data/lib/bandwidth-sdk/api/conferences_api.rb +9 -9
- data/lib/bandwidth-sdk/api/endpoints_api.rb +5 -5
- data/lib/bandwidth-sdk/api/media_api.rb +4 -4
- data/lib/bandwidth-sdk/api/messages_api.rb +2 -2
- data/lib/bandwidth-sdk/api/mfa_api.rb +3 -3
- data/lib/bandwidth-sdk/api/multi_channel_api.rb +1 -1
- data/lib/bandwidth-sdk/api/phone_number_lookup_api.rb +3 -3
- data/lib/bandwidth-sdk/api/recordings_api.rb +10 -10
- data/lib/bandwidth-sdk/api/statistics_api.rb +1 -1
- data/lib/bandwidth-sdk/api/toll_free_verification_api.rb +9 -9
- data/lib/bandwidth-sdk/api/transcriptions_api.rb +3 -3
- data/lib/bandwidth-sdk/api_client.rb +3 -1
- data/lib/bandwidth-sdk/configuration.rb +18 -19
- data/lib/bandwidth-sdk/models/callback.rb +1 -0
- data/lib/bandwidth-sdk/models/disconnect_callback.rb +27 -5
- data/lib/bandwidth-sdk/models/inbound_callback_message.rb +10 -1
- data/lib/bandwidth-sdk/models/initiate_callback.rb +1 -1
- data/lib/bandwidth-sdk/models/list_message_item.rb +1 -0
- data/lib/bandwidth-sdk/models/multi_channel_action_calendar_event.rb +1 -1
- data/lib/bandwidth-sdk/models/rbm_action_base.rb +1 -1
- data/lib/bandwidth-sdk/models/rbm_action_dial.rb +1 -1
- data/lib/bandwidth-sdk/models/rbm_action_open_url.rb +1 -1
- data/lib/bandwidth-sdk/models/rbm_action_view_location.rb +1 -1
- data/lib/bandwidth-sdk/models/rbm_session.rb +208 -0
- data/lib/bandwidth-sdk/models/rbm_suggestion_response.rb +2 -2
- data/lib/bandwidth-sdk/models/status_callback_message.rb +13 -4
- data/lib/bandwidth-sdk/models/status_callback_type_enum.rb +2 -1
- data/lib/bandwidth-sdk/models/transfer_disconnect_callback.rb +37 -5
- data/lib/bandwidth-sdk/version.rb +1 -1
- data/lib/bandwidth-sdk.rb +3 -2
- data/spec/smoke/calls_api_spec.rb +46 -46
- data/spec/smoke/conferences_api_spec.rb +1 -1
- data/spec/smoke/endpoints_api_spec.rb +2 -31
- data/spec/smoke/media_api_spec.rb +2 -0
- data/spec/smoke/messages_api_spec.rb +2 -24
- data/spec/smoke/mfa_api_spec.rb +4 -27
- data/spec/smoke/multi_channel_api_spec.rb +4 -2
- data/spec/smoke/phone_number_lookup_api_spec.rb +2 -0
- data/spec/smoke/recordings_api_spec.rb +1 -1
- data/spec/smoke/smoke_helper.rb +41 -0
- data/spec/smoke/statistics_api_spec.rb +2 -37
- data/spec/smoke/toll_free_verification_api_spec.rb +2 -0
- data/spec/smoke/transcriptions_api_spec.rb +1 -1
- data/spec/spec_helper.rb +0 -48
- data/spec/unit/api/calls_api_spec.rb +3 -1
- data/spec/unit/api/conferences_api_spec.rb +2 -0
- data/spec/unit/api/endpoints_api_spec.rb +2 -0
- data/spec/unit/api/media_api_spec.rb +2 -0
- data/spec/unit/api/messages_api_spec.rb +2 -0
- data/spec/unit/api/mfa_api_spec.rb +2 -0
- data/spec/unit/api/multi_channel_api_spec.rb +2 -0
- data/spec/unit/api/phone_number_lookup_api_spec.rb +2 -0
- data/spec/unit/api/recordings_api_spec.rb +2 -0
- data/spec/unit/api/statistics_api_spec.rb +2 -0
- data/spec/unit/api/toll_free_verification_api_spec.rb +2 -0
- data/spec/unit/api/transcriptions_api_spec.rb +2 -0
- data/spec/unit/client/api_client_spec.rb +70 -206
- data/spec/unit/client/configuration_spec.rb +22 -17
- data/spec/unit/constants.rb +6 -0
- data/spec/unit/models/callback_spec.rb +1 -0
- data/spec/unit/models/disconnect_callback_spec.rb +10 -2
- data/spec/unit/models/inbound_callback_message_spec.rb +20 -5
- data/spec/unit/models/list_message_item_spec.rb +1 -0
- data/spec/unit/models/rbm_session_spec.rb +95 -0
- data/spec/unit/models/status_callback_message_spec.rb +20 -5
- data/spec/unit/models/status_callback_type_enum_spec.rb +7 -1
- data/spec/unit/models/transfer_disconnect_callback_spec.rb +16 -4
- metadata +9 -1
|
@@ -166,8 +166,10 @@ module {{moduleName}}
|
|
|
166
166
|
# @param [Hash] query_params Query parameters
|
|
167
167
|
# @param [String] auth_names Authentication scheme name
|
|
168
168
|
def update_params_for_auth!(header_params, query_params, auth_names)
|
|
169
|
+
auth_settings = nil
|
|
169
170
|
Array(auth_names).each do |auth_name|
|
|
170
|
-
|
|
171
|
+
auth_settings ||= @config.auth_settings
|
|
172
|
+
auth_setting = auth_settings[auth_name]
|
|
171
173
|
next unless auth_setting
|
|
172
174
|
case auth_setting[:in]
|
|
173
175
|
when 'header' then header_params[auth_setting[:key]] = auth_setting[:value] unless auth_setting[:value].nil?
|
|
@@ -42,15 +42,25 @@ module {{moduleName}}
|
|
|
42
42
|
# config.api_key_prefix['api_key'] = 'Token'
|
|
43
43
|
attr_accessor :api_key_prefix
|
|
44
44
|
|
|
45
|
-
#
|
|
45
|
+
# HTTP basic authentication is no longer supported. Always nil.
|
|
46
46
|
#
|
|
47
|
-
# @return [
|
|
48
|
-
|
|
47
|
+
# @return [nil]
|
|
48
|
+
attr_reader :username
|
|
49
49
|
|
|
50
|
-
#
|
|
50
|
+
# HTTP basic authentication is no longer supported. Always nil.
|
|
51
51
|
#
|
|
52
|
-
# @return [
|
|
53
|
-
|
|
52
|
+
# @return [nil]
|
|
53
|
+
attr_reader :password
|
|
54
|
+
|
|
55
|
+
# @raise [ArgumentError] HTTP basic authentication is no longer supported
|
|
56
|
+
def username=(_username)
|
|
57
|
+
raise ArgumentError, 'HTTP basic authentication is no longer supported. Use client_id and client_secret instead.'
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
# @raise [ArgumentError] HTTP basic authentication is no longer supported
|
|
61
|
+
def password=(_password)
|
|
62
|
+
raise ArgumentError, 'HTTP basic authentication is no longer supported. Use client_id and client_secret instead.'
|
|
63
|
+
end
|
|
54
64
|
|
|
55
65
|
# Defines the client ID used with OAuth2.
|
|
56
66
|
#
|
|
@@ -265,16 +275,12 @@ module {{moduleName}}
|
|
|
265
275
|
access_token_getter.call
|
|
266
276
|
end
|
|
267
277
|
|
|
268
|
-
# Gets Basic Auth token string
|
|
269
|
-
def basic_auth_token
|
|
270
|
-
'Basic ' + ["#{username}:#{password}"].pack('m').delete("\r\n")
|
|
271
|
-
end
|
|
272
|
-
|
|
273
278
|
{{#authMethods}}
|
|
274
279
|
{{#isOAuth}}
|
|
275
280
|
# Gets Bearer auth token string
|
|
276
281
|
def oauth_bearer_token
|
|
277
|
-
|
|
282
|
+
token = access_token_with_refresh
|
|
283
|
+
"Bearer #{token}" unless token.nil?
|
|
278
284
|
end
|
|
279
285
|
|
|
280
286
|
{{/isOAuth}}
|
|
@@ -89,8 +89,8 @@ module {{moduleName}}
|
|
|
89
89
|
class << self
|
|
90
90
|
# Customize default settings for the SDK using block.
|
|
91
91
|
# {{moduleName}}.configure do |config|
|
|
92
|
-
# config.
|
|
93
|
-
# config.
|
|
92
|
+
# config.client_id = "xxx"
|
|
93
|
+
# config.client_secret = "xxx"
|
|
94
94
|
# end
|
|
95
95
|
# If no block given, return the default Configuration object.
|
|
96
96
|
def configure
|
data/docs/Callback.md
CHANGED
|
@@ -51,6 +51,7 @@ Bandwidth::Callback.openapi_discriminator_mapping
|
|
|
51
51
|
# :'message-sending' => :'StatusCallback',
|
|
52
52
|
# :'message-sent' => :'StatusCallback',
|
|
53
53
|
# :'requested-location-response' => :'InboundCallback',
|
|
54
|
+
# :'session-started' => :'StatusCallback',
|
|
54
55
|
# :'suggestion-response' => :'InboundCallback'
|
|
55
56
|
# }
|
|
56
57
|
```
|
data/docs/CallsApi.md
CHANGED
|
@@ -26,10 +26,6 @@ require 'time'
|
|
|
26
26
|
require 'bandwidth-sdk'
|
|
27
27
|
# setup authorization
|
|
28
28
|
Bandwidth.configure do |config|
|
|
29
|
-
# Configure HTTP basic authorization: Basic
|
|
30
|
-
config.username = 'YOUR USERNAME'
|
|
31
|
-
config.password = 'YOUR PASSWORD'
|
|
32
|
-
|
|
33
29
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
34
30
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
35
31
|
end
|
|
@@ -78,7 +74,7 @@ end
|
|
|
78
74
|
|
|
79
75
|
### Authorization
|
|
80
76
|
|
|
81
|
-
[
|
|
77
|
+
[OAuth2](../README.md#OAuth2)
|
|
82
78
|
|
|
83
79
|
### HTTP request headers
|
|
84
80
|
|
|
@@ -101,10 +97,6 @@ require 'time'
|
|
|
101
97
|
require 'bandwidth-sdk'
|
|
102
98
|
# setup authorization
|
|
103
99
|
Bandwidth.configure do |config|
|
|
104
|
-
# Configure HTTP basic authorization: Basic
|
|
105
|
-
config.username = 'YOUR USERNAME'
|
|
106
|
-
config.password = 'YOUR PASSWORD'
|
|
107
|
-
|
|
108
100
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
109
101
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
110
102
|
end
|
|
@@ -153,7 +145,7 @@ end
|
|
|
153
145
|
|
|
154
146
|
### Authorization
|
|
155
147
|
|
|
156
|
-
[
|
|
148
|
+
[OAuth2](../README.md#OAuth2)
|
|
157
149
|
|
|
158
150
|
### HTTP request headers
|
|
159
151
|
|
|
@@ -176,10 +168,6 @@ require 'time'
|
|
|
176
168
|
require 'bandwidth-sdk'
|
|
177
169
|
# setup authorization
|
|
178
170
|
Bandwidth.configure do |config|
|
|
179
|
-
# Configure HTTP basic authorization: Basic
|
|
180
|
-
config.username = 'YOUR USERNAME'
|
|
181
|
-
config.password = 'YOUR PASSWORD'
|
|
182
|
-
|
|
183
171
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
184
172
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
185
173
|
end
|
|
@@ -242,7 +230,7 @@ end
|
|
|
242
230
|
|
|
243
231
|
### Authorization
|
|
244
232
|
|
|
245
|
-
[
|
|
233
|
+
[OAuth2](../README.md#OAuth2)
|
|
246
234
|
|
|
247
235
|
### HTTP request headers
|
|
248
236
|
|
|
@@ -265,10 +253,6 @@ require 'time'
|
|
|
265
253
|
require 'bandwidth-sdk'
|
|
266
254
|
# setup authorization
|
|
267
255
|
Bandwidth.configure do |config|
|
|
268
|
-
# Configure HTTP basic authorization: Basic
|
|
269
|
-
config.username = 'YOUR USERNAME'
|
|
270
|
-
config.password = 'YOUR PASSWORD'
|
|
271
|
-
|
|
272
256
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
273
257
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
274
258
|
end
|
|
@@ -318,7 +302,7 @@ nil (empty response body)
|
|
|
318
302
|
|
|
319
303
|
### Authorization
|
|
320
304
|
|
|
321
|
-
[
|
|
305
|
+
[OAuth2](../README.md#OAuth2)
|
|
322
306
|
|
|
323
307
|
### HTTP request headers
|
|
324
308
|
|
|
@@ -341,10 +325,6 @@ require 'time'
|
|
|
341
325
|
require 'bandwidth-sdk'
|
|
342
326
|
# setup authorization
|
|
343
327
|
Bandwidth.configure do |config|
|
|
344
|
-
# Configure HTTP basic authorization: Basic
|
|
345
|
-
config.username = 'YOUR USERNAME'
|
|
346
|
-
config.password = 'YOUR PASSWORD'
|
|
347
|
-
|
|
348
328
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
349
329
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
350
330
|
end
|
|
@@ -397,7 +377,7 @@ nil (empty response body)
|
|
|
397
377
|
|
|
398
378
|
### Authorization
|
|
399
379
|
|
|
400
|
-
[
|
|
380
|
+
[OAuth2](../README.md#OAuth2)
|
|
401
381
|
|
|
402
382
|
### HTTP request headers
|
|
403
383
|
|
data/docs/ConferencesApi.md
CHANGED
|
@@ -30,10 +30,6 @@ require 'time'
|
|
|
30
30
|
require 'bandwidth-sdk'
|
|
31
31
|
# setup authorization
|
|
32
32
|
Bandwidth.configure do |config|
|
|
33
|
-
# Configure HTTP basic authorization: Basic
|
|
34
|
-
config.username = 'YOUR USERNAME'
|
|
35
|
-
config.password = 'YOUR PASSWORD'
|
|
36
|
-
|
|
37
33
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
38
34
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
39
35
|
end
|
|
@@ -84,7 +80,7 @@ end
|
|
|
84
80
|
|
|
85
81
|
### Authorization
|
|
86
82
|
|
|
87
|
-
[
|
|
83
|
+
[OAuth2](../README.md#OAuth2)
|
|
88
84
|
|
|
89
85
|
### HTTP request headers
|
|
90
86
|
|
|
@@ -107,10 +103,6 @@ require 'time'
|
|
|
107
103
|
require 'bandwidth-sdk'
|
|
108
104
|
# setup authorization
|
|
109
105
|
Bandwidth.configure do |config|
|
|
110
|
-
# Configure HTTP basic authorization: Basic
|
|
111
|
-
config.username = 'YOUR USERNAME'
|
|
112
|
-
config.password = 'YOUR PASSWORD'
|
|
113
|
-
|
|
114
106
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
115
107
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
116
108
|
end
|
|
@@ -159,7 +151,7 @@ end
|
|
|
159
151
|
|
|
160
152
|
### Authorization
|
|
161
153
|
|
|
162
|
-
[
|
|
154
|
+
[OAuth2](../README.md#OAuth2)
|
|
163
155
|
|
|
164
156
|
### HTTP request headers
|
|
165
157
|
|
|
@@ -182,10 +174,6 @@ require 'time'
|
|
|
182
174
|
require 'bandwidth-sdk'
|
|
183
175
|
# setup authorization
|
|
184
176
|
Bandwidth.configure do |config|
|
|
185
|
-
# Configure HTTP basic authorization: Basic
|
|
186
|
-
config.username = 'YOUR USERNAME'
|
|
187
|
-
config.password = 'YOUR PASSWORD'
|
|
188
|
-
|
|
189
177
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
190
178
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
191
179
|
end
|
|
@@ -236,7 +224,7 @@ end
|
|
|
236
224
|
|
|
237
225
|
### Authorization
|
|
238
226
|
|
|
239
|
-
[
|
|
227
|
+
[OAuth2](../README.md#OAuth2)
|
|
240
228
|
|
|
241
229
|
### HTTP request headers
|
|
242
230
|
|
|
@@ -259,10 +247,6 @@ require 'time'
|
|
|
259
247
|
require 'bandwidth-sdk'
|
|
260
248
|
# setup authorization
|
|
261
249
|
Bandwidth.configure do |config|
|
|
262
|
-
# Configure HTTP basic authorization: Basic
|
|
263
|
-
config.username = 'YOUR USERNAME'
|
|
264
|
-
config.password = 'YOUR PASSWORD'
|
|
265
|
-
|
|
266
250
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
267
251
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
268
252
|
end
|
|
@@ -313,7 +297,7 @@ end
|
|
|
313
297
|
|
|
314
298
|
### Authorization
|
|
315
299
|
|
|
316
|
-
[
|
|
300
|
+
[OAuth2](../README.md#OAuth2)
|
|
317
301
|
|
|
318
302
|
### HTTP request headers
|
|
319
303
|
|
|
@@ -336,10 +320,6 @@ require 'time'
|
|
|
336
320
|
require 'bandwidth-sdk'
|
|
337
321
|
# setup authorization
|
|
338
322
|
Bandwidth.configure do |config|
|
|
339
|
-
# Configure HTTP basic authorization: Basic
|
|
340
|
-
config.username = 'YOUR USERNAME'
|
|
341
|
-
config.password = 'YOUR PASSWORD'
|
|
342
|
-
|
|
343
323
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
344
324
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
345
325
|
end
|
|
@@ -388,7 +368,7 @@ end
|
|
|
388
368
|
|
|
389
369
|
### Authorization
|
|
390
370
|
|
|
391
|
-
[
|
|
371
|
+
[OAuth2](../README.md#OAuth2)
|
|
392
372
|
|
|
393
373
|
### HTTP request headers
|
|
394
374
|
|
|
@@ -411,10 +391,6 @@ require 'time'
|
|
|
411
391
|
require 'bandwidth-sdk'
|
|
412
392
|
# setup authorization
|
|
413
393
|
Bandwidth.configure do |config|
|
|
414
|
-
# Configure HTTP basic authorization: Basic
|
|
415
|
-
config.username = 'YOUR USERNAME'
|
|
416
|
-
config.password = 'YOUR PASSWORD'
|
|
417
|
-
|
|
418
394
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
419
395
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
420
396
|
end
|
|
@@ -473,7 +449,7 @@ end
|
|
|
473
449
|
|
|
474
450
|
### Authorization
|
|
475
451
|
|
|
476
|
-
[
|
|
452
|
+
[OAuth2](../README.md#OAuth2)
|
|
477
453
|
|
|
478
454
|
### HTTP request headers
|
|
479
455
|
|
|
@@ -496,10 +472,6 @@ require 'time'
|
|
|
496
472
|
require 'bandwidth-sdk'
|
|
497
473
|
# setup authorization
|
|
498
474
|
Bandwidth.configure do |config|
|
|
499
|
-
# Configure HTTP basic authorization: Basic
|
|
500
|
-
config.username = 'YOUR USERNAME'
|
|
501
|
-
config.password = 'YOUR PASSWORD'
|
|
502
|
-
|
|
503
475
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
504
476
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
505
477
|
end
|
|
@@ -549,7 +521,7 @@ nil (empty response body)
|
|
|
549
521
|
|
|
550
522
|
### Authorization
|
|
551
523
|
|
|
552
|
-
[
|
|
524
|
+
[OAuth2](../README.md#OAuth2)
|
|
553
525
|
|
|
554
526
|
### HTTP request headers
|
|
555
527
|
|
|
@@ -572,10 +544,6 @@ require 'time'
|
|
|
572
544
|
require 'bandwidth-sdk'
|
|
573
545
|
# setup authorization
|
|
574
546
|
Bandwidth.configure do |config|
|
|
575
|
-
# Configure HTTP basic authorization: Basic
|
|
576
|
-
config.username = 'YOUR USERNAME'
|
|
577
|
-
config.password = 'YOUR PASSWORD'
|
|
578
|
-
|
|
579
547
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
580
548
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
581
549
|
end
|
|
@@ -628,7 +596,7 @@ nil (empty response body)
|
|
|
628
596
|
|
|
629
597
|
### Authorization
|
|
630
598
|
|
|
631
|
-
[
|
|
599
|
+
[OAuth2](../README.md#OAuth2)
|
|
632
600
|
|
|
633
601
|
### HTTP request headers
|
|
634
602
|
|
|
@@ -651,10 +619,6 @@ require 'time'
|
|
|
651
619
|
require 'bandwidth-sdk'
|
|
652
620
|
# setup authorization
|
|
653
621
|
Bandwidth.configure do |config|
|
|
654
|
-
# Configure HTTP basic authorization: Basic
|
|
655
|
-
config.username = 'YOUR USERNAME'
|
|
656
|
-
config.password = 'YOUR PASSWORD'
|
|
657
|
-
|
|
658
622
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
659
623
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
660
624
|
end
|
|
@@ -706,7 +670,7 @@ nil (empty response body)
|
|
|
706
670
|
|
|
707
671
|
### Authorization
|
|
708
672
|
|
|
709
|
-
[
|
|
673
|
+
[OAuth2](../README.md#OAuth2)
|
|
710
674
|
|
|
711
675
|
### HTTP request headers
|
|
712
676
|
|
data/docs/DisconnectCallback.md
CHANGED
|
@@ -22,7 +22,9 @@
|
|
|
22
22
|
| **error_id** | **String** | Bandwidth's internal id that references the error event. | [optional] |
|
|
23
23
|
| **tag** | **String** | (optional) The tag specified on call creation. If no tag was specified or it was previously cleared, this field will not be present. | [optional] |
|
|
24
24
|
| **sip_call_id** | **String** | (optional) The SIP Call-ID of the call's current SIP dialog with Bandwidth's SBC. Used to correlate dialogs and trace calls. Present on any call, inbound or outbound, once that dialog has been established; may be absent very early in a call before the dialog exists. | [optional] |
|
|
25
|
-
| **sip_response_code** | **Integer** | (optional) The SIP status code
|
|
25
|
+
| **sip_response_code** | **Integer** | (optional) The SIP status code of the final response that rejected an outbound call's (or transferred leg's) INVITE (e.g. 486 for busy, 603 for decline). Present only when the call was rejected with a SIP response. | [optional] |
|
|
26
|
+
| **sip_status_line** | **String** | (optional) The full SIP status line, exactly as received, of the final response that rejected an outbound call's INVITE. The reason phrase can help distinguish outcomes that share a status code, such as `603 Network Blocked` and `603 Decline`. Present only when an outbound call was rejected with a SIP response. | [optional] |
|
|
27
|
+
| **sip_headers** | **Hash<String, String>** | (optional) Map of SIP headers, with lowercase keys (SIP headers are case-insensitive). On the Initiate callback, contains the customer-supplied X-* headers from the original INVITE; present only for inbound SIP URI calls with custom headers. On the Disconnect and Transfer Disconnect callbacks, contains a single `reason` key holding the raw, unmodified `Reason` header value from the final SIP response that rejected an outbound call (or transferred leg); present only when that response included a `Reason` header (for example, `v=analytics1` call-analytics block information from a terminating carrier). If the response carries more than one `Reason` header, all values are returned in the order received, separated by `, `. Note - on the Initiate callback, keys preserve the original SIP header name in lowercase rather than Bandwidth's usual camelCase JSON convention, since these are passthrough values from the caller's SIP INVITE, not Bandwidth-defined fields. If the same header name is sent more than once in the INVITE, only the last value is kept. The example shown is for the Initiate callback; on the Disconnect and Transfer Disconnect callbacks the only key is `reason`. | [optional] |
|
|
26
28
|
|
|
27
29
|
## Example
|
|
28
30
|
|
|
@@ -48,7 +50,9 @@ instance = Bandwidth::DisconnectCallback.new(
|
|
|
48
50
|
error_id: 4642074b-7b58-478b-96e4-3a60955c6765,
|
|
49
51
|
tag: exampleTag,
|
|
50
52
|
sip_call_id: c95ac8d6e1a31c52eb38f419893c151633ec68f8d@sbc.bandwidth.com,
|
|
51
|
-
sip_response_code: 486
|
|
53
|
+
sip_response_code: 486,
|
|
54
|
+
sip_status_line: SIP/2.0 603 Network Blocked,
|
|
55
|
+
sip_headers: {"x-custom-header":"customer-value","x-session-id":"sess-12345"}
|
|
52
56
|
)
|
|
53
57
|
```
|
|
54
58
|
|
data/docs/EndpointsApi.md
CHANGED
|
@@ -26,10 +26,6 @@ require 'time'
|
|
|
26
26
|
require 'bandwidth-sdk'
|
|
27
27
|
# setup authorization
|
|
28
28
|
Bandwidth.configure do |config|
|
|
29
|
-
# Configure HTTP basic authorization: Basic
|
|
30
|
-
config.username = 'YOUR USERNAME'
|
|
31
|
-
config.password = 'YOUR PASSWORD'
|
|
32
|
-
|
|
33
29
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
34
30
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
35
31
|
end
|
|
@@ -78,7 +74,7 @@ end
|
|
|
78
74
|
|
|
79
75
|
### Authorization
|
|
80
76
|
|
|
81
|
-
[
|
|
77
|
+
[OAuth2](../README.md#OAuth2)
|
|
82
78
|
|
|
83
79
|
### HTTP request headers
|
|
84
80
|
|
|
@@ -101,10 +97,6 @@ require 'time'
|
|
|
101
97
|
require 'bandwidth-sdk'
|
|
102
98
|
# setup authorization
|
|
103
99
|
Bandwidth.configure do |config|
|
|
104
|
-
# Configure HTTP basic authorization: Basic
|
|
105
|
-
config.username = 'YOUR USERNAME'
|
|
106
|
-
config.password = 'YOUR PASSWORD'
|
|
107
|
-
|
|
108
100
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
109
101
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
110
102
|
end
|
|
@@ -152,7 +144,7 @@ nil (empty response body)
|
|
|
152
144
|
|
|
153
145
|
### Authorization
|
|
154
146
|
|
|
155
|
-
[
|
|
147
|
+
[OAuth2](../README.md#OAuth2)
|
|
156
148
|
|
|
157
149
|
### HTTP request headers
|
|
158
150
|
|
|
@@ -175,10 +167,6 @@ require 'time'
|
|
|
175
167
|
require 'bandwidth-sdk'
|
|
176
168
|
# setup authorization
|
|
177
169
|
Bandwidth.configure do |config|
|
|
178
|
-
# Configure HTTP basic authorization: Basic
|
|
179
|
-
config.username = 'YOUR USERNAME'
|
|
180
|
-
config.password = 'YOUR PASSWORD'
|
|
181
|
-
|
|
182
170
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
183
171
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
184
172
|
end
|
|
@@ -227,7 +215,7 @@ end
|
|
|
227
215
|
|
|
228
216
|
### Authorization
|
|
229
217
|
|
|
230
|
-
[
|
|
218
|
+
[OAuth2](../README.md#OAuth2)
|
|
231
219
|
|
|
232
220
|
### HTTP request headers
|
|
233
221
|
|
|
@@ -250,10 +238,6 @@ require 'time'
|
|
|
250
238
|
require 'bandwidth-sdk'
|
|
251
239
|
# setup authorization
|
|
252
240
|
Bandwidth.configure do |config|
|
|
253
|
-
# Configure HTTP basic authorization: Basic
|
|
254
|
-
config.username = 'YOUR USERNAME'
|
|
255
|
-
config.password = 'YOUR PASSWORD'
|
|
256
|
-
|
|
257
241
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
258
242
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
259
243
|
end
|
|
@@ -310,7 +294,7 @@ end
|
|
|
310
294
|
|
|
311
295
|
### Authorization
|
|
312
296
|
|
|
313
|
-
[
|
|
297
|
+
[OAuth2](../README.md#OAuth2)
|
|
314
298
|
|
|
315
299
|
### HTTP request headers
|
|
316
300
|
|
|
@@ -333,10 +317,6 @@ require 'time'
|
|
|
333
317
|
require 'bandwidth-sdk'
|
|
334
318
|
# setup authorization
|
|
335
319
|
Bandwidth.configure do |config|
|
|
336
|
-
# Configure HTTP basic authorization: Basic
|
|
337
|
-
config.username = 'YOUR USERNAME'
|
|
338
|
-
config.password = 'YOUR PASSWORD'
|
|
339
|
-
|
|
340
320
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
341
321
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
342
322
|
end
|
|
@@ -386,7 +366,7 @@ nil (empty response body)
|
|
|
386
366
|
|
|
387
367
|
### Authorization
|
|
388
368
|
|
|
389
|
-
[
|
|
369
|
+
[OAuth2](../README.md#OAuth2)
|
|
390
370
|
|
|
391
371
|
### HTTP request headers
|
|
392
372
|
|
data/docs/InboundCallback.md
CHANGED
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
| **media** | **Array<String>** | Optional media, not applicable for sms | [optional] |
|
|
18
18
|
| **priority** | [**PriorityEnum**](PriorityEnum.md) | | [optional] |
|
|
19
19
|
| **channel** | [**MultiChannelMessageChannelEnum**](MultiChannelMessageChannelEnum.md) | | [optional] |
|
|
20
|
+
| **session** | [**RbmSession**](RbmSession.md) | | [optional] |
|
|
20
21
|
| **content** | [**MultiChannelMessageContent**](MultiChannelMessageContent.md) | | [optional] |
|
|
21
22
|
| **suggestion_response** | [**RbmSuggestionResponse**](RbmSuggestionResponse.md) | | [optional] |
|
|
22
23
|
| **location_response** | [**RbmLocationResponse**](RbmLocationResponse.md) | | [optional] |
|
|
@@ -40,6 +41,7 @@ instance = Bandwidth::InboundCallbackMessage.new(
|
|
|
40
41
|
media: [https://dev.bandwidth.com/images/bandwidth-logo.png, https://dev.bandwidth.com/images/github_logo.png],
|
|
41
42
|
priority: null,
|
|
42
43
|
channel: null,
|
|
44
|
+
session: null,
|
|
43
45
|
content: null,
|
|
44
46
|
suggestion_response: null,
|
|
45
47
|
location_response: null
|
data/docs/InitiateCallback.md
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
| **stir_shaken** | [**StirShaken**](StirShaken.md) | | [optional] |
|
|
19
19
|
| **uui** | **String** | The value of the `User-To-User` header to send within the initial `INVITE`. Must include the encoding parameter as specified in RFC 7433. Only `base64`, `jwt` and `hex` encoding are currently allowed. This value, including the encoding specifier, may not exceed 256 characters. | [optional] |
|
|
20
20
|
| **sip_call_id** | **String** | (optional) The SIP Call-ID of the call's current SIP dialog with Bandwidth's SBC. Used to correlate dialogs and trace calls. Present on any call, inbound or outbound, once that dialog has been established; may be absent very early in a call before the dialog exists. | [optional] |
|
|
21
|
-
| **sip_headers** | **Hash<String, String>** | (optional) Map of customer-supplied X-* headers from the original INVITE
|
|
21
|
+
| **sip_headers** | **Hash<String, String>** | (optional) Map of SIP headers, with lowercase keys (SIP headers are case-insensitive). On the Initiate callback, contains the customer-supplied X-* headers from the original INVITE; present only for inbound SIP URI calls with custom headers. On the Disconnect and Transfer Disconnect callbacks, contains a single `reason` key holding the raw, unmodified `Reason` header value from the final SIP response that rejected an outbound call (or transferred leg); present only when that response included a `Reason` header (for example, `v=analytics1` call-analytics block information from a terminating carrier). If the response carries more than one `Reason` header, all values are returned in the order received, separated by `, `. Note - on the Initiate callback, keys preserve the original SIP header name in lowercase rather than Bandwidth's usual camelCase JSON convention, since these are passthrough values from the caller's SIP INVITE, not Bandwidth-defined fields. If the same header name is sent more than once in the INVITE, only the last value is kept. The example shown is for the Initiate callback; on the Disconnect and Transfer Disconnect callbacks the only key is `reason`. | [optional] |
|
|
22
22
|
|
|
23
23
|
## Example
|
|
24
24
|
|
data/docs/LookupResult.md
CHANGED
|
@@ -32,8 +32,8 @@ instance = Bandwidth::LookupResult.new(
|
|
|
32
32
|
deactivation_date: 2025-06-20 18:35,
|
|
33
33
|
deactivation_event: null,
|
|
34
34
|
latest_message_delivery_status: null,
|
|
35
|
-
initial_message_delivery_status_date:
|
|
36
|
-
latest_message_delivery_status_date:
|
|
35
|
+
initial_message_delivery_status_date: Thu Jun 19 20:00:00 EDT 2025,
|
|
36
|
+
latest_message_delivery_status_date: Fri Jun 20 20:00:00 EDT 2025,
|
|
37
37
|
rcs_enabled: true
|
|
38
38
|
)
|
|
39
39
|
```
|
data/docs/MFAApi.md
CHANGED
|
@@ -24,10 +24,6 @@ require 'time'
|
|
|
24
24
|
require 'bandwidth-sdk'
|
|
25
25
|
# setup authorization
|
|
26
26
|
Bandwidth.configure do |config|
|
|
27
|
-
# Configure HTTP basic authorization: Basic
|
|
28
|
-
config.username = 'YOUR USERNAME'
|
|
29
|
-
config.password = 'YOUR PASSWORD'
|
|
30
|
-
|
|
31
27
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
32
28
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
33
29
|
end
|
|
@@ -76,7 +72,7 @@ end
|
|
|
76
72
|
|
|
77
73
|
### Authorization
|
|
78
74
|
|
|
79
|
-
[
|
|
75
|
+
[OAuth2](../README.md#OAuth2)
|
|
80
76
|
|
|
81
77
|
### HTTP request headers
|
|
82
78
|
|
|
@@ -99,10 +95,6 @@ require 'time'
|
|
|
99
95
|
require 'bandwidth-sdk'
|
|
100
96
|
# setup authorization
|
|
101
97
|
Bandwidth.configure do |config|
|
|
102
|
-
# Configure HTTP basic authorization: Basic
|
|
103
|
-
config.username = 'YOUR USERNAME'
|
|
104
|
-
config.password = 'YOUR PASSWORD'
|
|
105
|
-
|
|
106
98
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
107
99
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
108
100
|
end
|
|
@@ -151,7 +143,7 @@ end
|
|
|
151
143
|
|
|
152
144
|
### Authorization
|
|
153
145
|
|
|
154
|
-
[
|
|
146
|
+
[OAuth2](../README.md#OAuth2)
|
|
155
147
|
|
|
156
148
|
### HTTP request headers
|
|
157
149
|
|
|
@@ -174,10 +166,6 @@ require 'time'
|
|
|
174
166
|
require 'bandwidth-sdk'
|
|
175
167
|
# setup authorization
|
|
176
168
|
Bandwidth.configure do |config|
|
|
177
|
-
# Configure HTTP basic authorization: Basic
|
|
178
|
-
config.username = 'YOUR USERNAME'
|
|
179
|
-
config.password = 'YOUR PASSWORD'
|
|
180
|
-
|
|
181
169
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
182
170
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
183
171
|
end
|
|
@@ -226,7 +214,7 @@ end
|
|
|
226
214
|
|
|
227
215
|
### Authorization
|
|
228
216
|
|
|
229
|
-
[
|
|
217
|
+
[OAuth2](../README.md#OAuth2)
|
|
230
218
|
|
|
231
219
|
### HTTP request headers
|
|
232
220
|
|
data/docs/MediaApi.md
CHANGED
|
@@ -25,10 +25,6 @@ require 'time'
|
|
|
25
25
|
require 'bandwidth-sdk'
|
|
26
26
|
# setup authorization
|
|
27
27
|
Bandwidth.configure do |config|
|
|
28
|
-
# Configure HTTP basic authorization: Basic
|
|
29
|
-
config.username = 'YOUR USERNAME'
|
|
30
|
-
config.password = 'YOUR PASSWORD'
|
|
31
|
-
|
|
32
28
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
33
29
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
34
30
|
end
|
|
@@ -76,7 +72,7 @@ nil (empty response body)
|
|
|
76
72
|
|
|
77
73
|
### Authorization
|
|
78
74
|
|
|
79
|
-
[
|
|
75
|
+
[OAuth2](../README.md#OAuth2)
|
|
80
76
|
|
|
81
77
|
### HTTP request headers
|
|
82
78
|
|
|
@@ -99,10 +95,6 @@ require 'time'
|
|
|
99
95
|
require 'bandwidth-sdk'
|
|
100
96
|
# setup authorization
|
|
101
97
|
Bandwidth.configure do |config|
|
|
102
|
-
# Configure HTTP basic authorization: Basic
|
|
103
|
-
config.username = 'YOUR USERNAME'
|
|
104
|
-
config.password = 'YOUR PASSWORD'
|
|
105
|
-
|
|
106
98
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
107
99
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
108
100
|
end
|
|
@@ -151,7 +143,7 @@ end
|
|
|
151
143
|
|
|
152
144
|
### Authorization
|
|
153
145
|
|
|
154
|
-
[
|
|
146
|
+
[OAuth2](../README.md#OAuth2)
|
|
155
147
|
|
|
156
148
|
### HTTP request headers
|
|
157
149
|
|
|
@@ -174,10 +166,6 @@ require 'time'
|
|
|
174
166
|
require 'bandwidth-sdk'
|
|
175
167
|
# setup authorization
|
|
176
168
|
Bandwidth.configure do |config|
|
|
177
|
-
# Configure HTTP basic authorization: Basic
|
|
178
|
-
config.username = 'YOUR USERNAME'
|
|
179
|
-
config.password = 'YOUR PASSWORD'
|
|
180
|
-
|
|
181
169
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
182
170
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
183
171
|
end
|
|
@@ -228,7 +216,7 @@ end
|
|
|
228
216
|
|
|
229
217
|
### Authorization
|
|
230
218
|
|
|
231
|
-
[
|
|
219
|
+
[OAuth2](../README.md#OAuth2)
|
|
232
220
|
|
|
233
221
|
### HTTP request headers
|
|
234
222
|
|
|
@@ -251,10 +239,6 @@ require 'time'
|
|
|
251
239
|
require 'bandwidth-sdk'
|
|
252
240
|
# setup authorization
|
|
253
241
|
Bandwidth.configure do |config|
|
|
254
|
-
# Configure HTTP basic authorization: Basic
|
|
255
|
-
config.username = 'YOUR USERNAME'
|
|
256
|
-
config.password = 'YOUR PASSWORD'
|
|
257
|
-
|
|
258
242
|
# Configure OAuth2 access token for authorization: OAuth2
|
|
259
243
|
config.access_token = 'YOUR ACCESS TOKEN'
|
|
260
244
|
end
|
|
@@ -310,7 +294,7 @@ nil (empty response body)
|
|
|
310
294
|
|
|
311
295
|
### Authorization
|
|
312
296
|
|
|
313
|
-
[
|
|
297
|
+
[OAuth2](../README.md#OAuth2)
|
|
314
298
|
|
|
315
299
|
### HTTP request headers
|
|
316
300
|
|
data/docs/Message.md
CHANGED
|
@@ -27,7 +27,7 @@ instance = Bandwidth::Message.new(
|
|
|
27
27
|
id: 1589228074636lm4k2je7j7jklbn2,
|
|
28
28
|
owner: +15554443333,
|
|
29
29
|
application_id: 93de2206-9669-4e07-948d-329f4b722ee2,
|
|
30
|
-
time: 2024-12-02T20:15:57.
|
|
30
|
+
time: 2024-12-02T20:15:57.278201Z,
|
|
31
31
|
segment_count: 1,
|
|
32
32
|
direction: null,
|
|
33
33
|
to: ["+15552223333"],
|