bandwidth-sdk 3.11.0 → 3.13.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9ee38371ece860ee70a08149297e79e58a0ca72a093168951ca8256c6a83e45c
4
- data.tar.gz: dc0ab4ad91c207356b662728a700079f2c1aeb965f8b34681463c5c28a4a649d
3
+ metadata.gz: 7336e9d451418630a0a7114a1f5e6d7ca929a7069afe71d5a81c96d3580f6ded
4
+ data.tar.gz: e4da49bb09e35ab947352c4d0b92ee6a970450ed9aec84b89bfcbf31b079791a
5
5
  SHA512:
6
- metadata.gz: e5823198c1684b55e3505e8439615cef32b6d71745795ad215710760ff58638a3b34db6afaa31a20d495d2a33e620689e8d3644813831f1cb7ad47376513ac07
7
- data.tar.gz: 8d4f8f124305b63102cfdb1908897ac521f14f4fcc133562f402dc28f4c9a69eb613765a6e5eb610a3ce0aaf49bcff078c575a2986cb065df750c4b429ab6536
6
+ metadata.gz: ea2a492118247060435f24d8d1fdc5421293b4abcb4d321495b25dc5be178eab4b5b58a22f49363f5b254719a357bbb8a2def4cb412f00ce9633ddb1be05e792
7
+ data.tar.gz: 79588ec737914f87a947b957b9e5a8f06335ba82d86fbe0eff55289df3109f21b6f55f33208cfe36fa6d491c63b31885fe910e98b21b72d5b37044cbf775ab9e
@@ -44,7 +44,6 @@ require_relative 'bandwidth/http/auth/web_rtc_basic_auth.rb'
44
44
 
45
45
  # External Files
46
46
  require_relative 'bandwidth/voice_lib/bxml/bxml.rb'
47
- require_relative 'bandwidth/web_rtc_lib/utils/web_rtc_transfer.rb'
48
47
  require_relative 'bandwidth/voice_lib/bxml/verbs/bridge.rb'
49
48
  require_relative 'bandwidth/voice_lib/bxml/verbs/conference.rb'
50
49
  require_relative 'bandwidth/voice_lib/bxml/verbs/forward.rb'
@@ -60,7 +59,10 @@ require_relative 'bandwidth/voice_lib/bxml/verbs/resume_recording.rb'
60
59
  require_relative 'bandwidth/voice_lib/bxml/verbs/ring.rb'
61
60
  require_relative 'bandwidth/voice_lib/bxml/verbs/send_dtmf.rb'
62
61
  require_relative 'bandwidth/voice_lib/bxml/verbs/speak_sentence.rb'
62
+ require_relative 'bandwidth/voice_lib/bxml/verbs/start_gather.rb'
63
63
  require_relative 'bandwidth/voice_lib/bxml/verbs/start_recording.rb'
64
+ require_relative 'bandwidth/voice_lib/bxml/verbs/stop_gather.rb'
64
65
  require_relative 'bandwidth/voice_lib/bxml/verbs/stop_recording.rb'
65
66
  require_relative 'bandwidth/voice_lib/bxml/verbs/transfer.rb'
66
67
  require_relative 'bandwidth/voice_lib/bxml/verbs/xml_verb.rb'
68
+ require_relative 'bandwidth/web_rtc_lib/utils/web_rtc_transfer.rb'
@@ -94,7 +94,7 @@ module Messaging
94
94
  _query_builder = APIHelper.append_url_with_template_parameters(
95
95
  _query_builder,
96
96
  'userId' => { 'value' => user_id, 'encode' => true },
97
- 'mediaId' => { 'value' => media_id, 'encode' => true }
97
+ 'mediaId' => { 'value' => media_id, 'encode' => false }
98
98
  )
99
99
  _query_url = APIHelper.clean_url _query_builder
100
100
 
@@ -166,7 +166,7 @@ module Messaging
166
166
  _query_builder = APIHelper.append_url_with_template_parameters(
167
167
  _query_builder,
168
168
  'userId' => { 'value' => user_id, 'encode' => true },
169
- 'mediaId' => { 'value' => media_id, 'encode' => true }
169
+ 'mediaId' => { 'value' => media_id, 'encode' => false }
170
170
  )
171
171
  _query_url = APIHelper.clean_url _query_builder
172
172
 
@@ -245,7 +245,7 @@ module Messaging
245
245
  _query_builder = APIHelper.append_url_with_template_parameters(
246
246
  _query_builder,
247
247
  'userId' => { 'value' => user_id, 'encode' => true },
248
- 'mediaId' => { 'value' => media_id, 'encode' => true }
248
+ 'mediaId' => { 'value' => media_id, 'encode' => false }
249
249
  )
250
250
  _query_url = APIHelper.clean_url _query_builder
251
251
 
@@ -13,7 +13,7 @@ module Bandwidth
13
13
  @http_call_back = http_call_back
14
14
 
15
15
  @global_headers = {
16
- 'user-agent' => 'ruby-sdk-refs/tags/ruby3.11.0'
16
+ 'user-agent' => 'ruby-sdk-refs/tags/ruby3.12.1'
17
17
  }
18
18
  end
19
19
 
@@ -13,7 +13,7 @@ module Bandwidth
13
13
  @http_call_back = http_call_back
14
14
 
15
15
  @global_headers = {
16
- 'user-agent' => 'ruby-sdk-refs/tags/ruby3.11.0'
16
+ 'user-agent' => 'ruby-sdk-refs/tags/ruby3.12.1'
17
17
  }
18
18
  end
19
19
 
@@ -0,0 +1,25 @@
1
+ require_relative 'xml_verb'
2
+
3
+ module Bandwidth
4
+ module Voice
5
+ class SipUri
6
+ include XmlVerb
7
+ def to_bxml(xml)
8
+ xml.SipUri(uri, compact_hash({
9
+ 'transferAnswerUrl' => transfer_answer_url,
10
+ 'transferAnswerMethod' => transfer_answer_method,
11
+ 'transferDisconnectUrl' => transfer_disconnect_url,
12
+ 'transferDisconnectMethod' => transfer_disconnect_method,
13
+ 'username' => username,
14
+ 'password' => password,
15
+ 'tag' => tag,
16
+ 'uui' => uui,
17
+ 'transferAnswerFallbackUrl' => transfer_answer_fallback_url,
18
+ 'transferAnswerFallbackMethod' => transfer_answer_fallback_method,
19
+ 'fallbackUsername' => fallback_username,
20
+ 'fallbackPassword' => fallback_password
21
+ }))
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,20 @@
1
+ require_relative 'xml_verb'
2
+
3
+ module Bandwidth
4
+ module Voice
5
+ # The StartGather verb is used to start a gather
6
+ class StartGather
7
+ include XmlVerb
8
+
9
+ def to_bxml(xml)
10
+ xml.StartGather(compact_hash({
11
+ 'username' => username,
12
+ 'password' => password,
13
+ 'tag' => tag,
14
+ 'dtmfUrl' => dtmf_url,
15
+ 'dtmfMethod' => dtmf_method,
16
+ }))
17
+ end
18
+ end
19
+ end
20
+ end
@@ -0,0 +1,14 @@
1
+ require_relative 'xml_verb'
2
+
3
+ module Bandwidth
4
+ module Voice
5
+ # The StopGather verb is used to complete a gather
6
+ class StopGather
7
+ include XmlVerb
8
+
9
+ def to_bxml(xml)
10
+ xml.StopGather()
11
+ end
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,13 @@
1
+ require_relative 'xml_verb'
2
+
3
+ module Bandwidth
4
+ module Voice
5
+ class Tag
6
+ include XmlVerb
7
+
8
+ def to_bxml(xml)
9
+ xml.Tag(tag)
10
+ end
11
+ end
12
+ end
13
+ end
@@ -31,8 +31,15 @@ module Bandwidth
31
31
  s.to_bxml(xml)
32
32
  end
33
33
  end
34
- phone_numbers.each do |number|
35
- embedded_xml(xml, number, PhoneNumber)
34
+ if not phone_numbers.nil?
35
+ phone_numbers.each do |number|
36
+ embedded_xml(xml, number, PhoneNumber)
37
+ end
38
+ end
39
+ if not sip_uris.nil?
40
+ sip_uris.each do |sip_uri|
41
+ embedded_xml(xml, sip_uri, SipUri)
42
+ end
36
43
  end
37
44
  end
38
45
  end
@@ -13,7 +13,7 @@ module Bandwidth
13
13
  @http_call_back = http_call_back
14
14
 
15
15
  @global_headers = {
16
- 'user-agent' => 'ruby-sdk-refs/tags/ruby3.11.0'
16
+ 'user-agent' => 'ruby-sdk-refs/tags/ruby3.12.1'
17
17
  }
18
18
  end
19
19
 
@@ -7,7 +7,7 @@
7
7
  module Bandwidth
8
8
  module WebRtc
9
9
  def generate_bxml(device_token, sip_uri="sip:sipx.webrtc.bandwidth.com:5060")
10
- return '<?xml version="1.0" encoding="UTF-8"?><Transfer><SipUri uui="%s;encoding=jwt">%s</SipUri></Transfer>' % [device_token, sip_uri]
10
+ return '<?xml version="1.0" encoding="UTF-8"?><Response><Transfer><SipUri uui="%s;encoding=jwt">%s</SipUri></Transfer></Response>' % [device_token, sip_uri]
11
11
  end
12
12
  end
13
13
  end
@@ -13,7 +13,7 @@ module Bandwidth
13
13
  @http_call_back = http_call_back
14
14
 
15
15
  @global_headers = {
16
- 'user-agent' => 'ruby-sdk-refs/tags/ruby3.11.0'
16
+ 'user-agent' => 'ruby-sdk-refs/tags/ruby3.12.1'
17
17
  }
18
18
  end
19
19
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bandwidth-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.11.0
4
+ version: 3.13.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - APIMatic SDK Generator
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-09-09 00:00:00.000000000 Z
11
+ date: 2021-01-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logging
@@ -168,9 +168,13 @@ files:
168
168
  - lib/bandwidth/voice_lib/bxml/verbs/resume_recording.rb
169
169
  - lib/bandwidth/voice_lib/bxml/verbs/ring.rb
170
170
  - lib/bandwidth/voice_lib/bxml/verbs/send_dtmf.rb
171
+ - lib/bandwidth/voice_lib/bxml/verbs/sip_uri.rb
171
172
  - lib/bandwidth/voice_lib/bxml/verbs/speak_sentence.rb
173
+ - lib/bandwidth/voice_lib/bxml/verbs/start_gather.rb
172
174
  - lib/bandwidth/voice_lib/bxml/verbs/start_recording.rb
175
+ - lib/bandwidth/voice_lib/bxml/verbs/stop_gather.rb
173
176
  - lib/bandwidth/voice_lib/bxml/verbs/stop_recording.rb
177
+ - lib/bandwidth/voice_lib/bxml/verbs/tag.rb
174
178
  - lib/bandwidth/voice_lib/bxml/verbs/transfer.rb
175
179
  - lib/bandwidth/voice_lib/bxml/verbs/xml_verb.rb
176
180
  - lib/bandwidth/voice_lib/voice.rb
@@ -239,7 +243,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
239
243
  - !ruby/object:Gem::Version
240
244
  version: '0'
241
245
  requirements: []
242
- rubygems_version: 3.1.2
246
+ rubygems_version: 3.2.3
243
247
  signing_key:
244
248
  specification_version: 4
245
249
  summary: bandwidth