bandwidth-sdk 11.2.0 → 11.3.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -9,7 +9,8 @@ module Bandwidth
9
9
 
10
10
  @attribute_map = {
11
11
  transfer_caller_id: 'transferCallerId', # Optional [String]: The caller ID to use when the call is transferred, if different. Must be in E.164 format (e.g. +15555555555) or be one of the following strings Restricted, Anonymous, Private, or Unavailable. Leave as default to pass along the number of the remote party. Defaults to None.
12
- call_timeout: 'callTimeout', # Optional [Number]:The timeout (in seconds) for the callee to answer the call after it starts ringing. If the call does not start ringing within 30s, the call will be cancelled regardless of this value. Range: decimal values between 1 - 300. Default value is 30 seconds. Defaults to None.
12
+ transfer_caller_display_name: 'transferCallerDisplayName', # Optional [String]: The caller display name to use when the call is transferred. May not exceed 256 characters nor contain control characters such as new lines. Defaults to None.
13
+ call_timeout: 'callTimeout', # Optional [Number]: The timeout (in seconds) for the callee to answer the call after it starts ringing. If the call does not start ringing within 30s, the call will be cancelled regardless of this value. Range: decimal values between 1 - 300. Default value is 30 seconds. Defaults to None.
13
14
  transfer_complete_url: 'transferCompleteUrl', # Optional [String]: URL to send the Transfer Complete event to and request new BXML. Optional but recommended. See below for further details. May be a relative URL. Defaults to None.
14
15
  transfer_complete_method: 'transferCompleteMethod', # Optional [String]: The HTTP method to use for the request to transferCompleteUrl. GET or POST. Default value is POST. Defaults to None.
15
16
  transfer_complete_fallback_url: 'transferCompleteFallbackUrl', # Optional [String]: A fallback url which, if provided, will be used to retry the Transfer Complete callback delivery in case transferCompleteUrl fails to respond. Defaults to None.
@@ -11,5 +11,5 @@ OpenAPI Generator version: 7.0.0
11
11
  =end
12
12
 
13
13
  module Bandwidth
14
- VERSION = '11.2.0'
14
+ VERSION = '11.3.0'
15
15
  end
@@ -3,6 +3,7 @@ describe 'Bandwidth::Bxml::Transfer' do
3
3
  let(:initial_attributes) {
4
4
  {
5
5
  transfer_caller_id: '+19195551234',
6
+ transfer_caller_display_name: 'initial_caller',
6
7
  call_timeout: 5,
7
8
  transfer_complete_url: 'https://initial.com',
8
9
  transfer_complete_method: 'POST',
@@ -21,6 +22,7 @@ describe 'Bandwidth::Bxml::Transfer' do
21
22
  let(:new_attributes) {
22
23
  {
23
24
  transfer_caller_id: '+19195554321',
25
+ transfer_caller_display_name: 'new_caller',
24
26
  call_timeout: 10,
25
27
  transfer_complete_url: 'https://new.com',
26
28
  transfer_complete_method: 'POST',
@@ -49,13 +51,13 @@ describe 'Bandwidth::Bxml::Transfer' do
49
51
  end
50
52
 
51
53
  it 'tests the to_bxml method of the Transfer instance' do
52
- expected = "\n<Transfer transferCallerId=\"+19195551234\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\"/>\n"
54
+ expected = "\n<Transfer transferCallerId=\"+19195551234\" transferCallerDisplayName=\"initial_caller\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\"/>\n"
53
55
  expect(instance.to_bxml).to eq(expected)
54
56
  end
55
57
 
56
58
  it 'tests the set_attributes method of the Transfer instance' do
57
59
  instance.set_attributes(new_attributes)
58
- expected = "\n<Transfer transferCallerId=\"+19195554321\" callTimeout=\"10\" transferCompleteUrl=\"https://new.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://new.com\" transferCompleteFallbackMethod=\"POST\" username=\"new_username\" password=\"new_password\" fallbackUsername=\"new_fallback_username\" fallbackPassword=\"new_fallback_password\" tag=\"new_tag\" diversionTreatment=\"stack\" diversionReason=\"no-answer\"/>\n"
60
+ expected = "\n<Transfer transferCallerId=\"+19195554321\" transferCallerDisplayName=\"new_caller\" callTimeout=\"10\" transferCompleteUrl=\"https://new.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://new.com\" transferCompleteFallbackMethod=\"POST\" username=\"new_username\" password=\"new_password\" fallbackUsername=\"new_fallback_username\" fallbackPassword=\"new_fallback_password\" tag=\"new_tag\" diversionTreatment=\"stack\" diversionReason=\"no-answer\"/>\n"
59
61
  expect(instance.to_bxml).to eq(expected)
60
62
  end
61
63
  end
@@ -67,16 +69,16 @@ describe 'Bandwidth::Bxml::Transfer' do
67
69
  end
68
70
 
69
71
  it 'tests the to_bxml method of the nested Transfer instance' do
70
- expected = "\n<Transfer transferCallerId=\"+19195551234\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\">\n <PhoneNumber>+19195551234</PhoneNumber>\n</Transfer>\n"
72
+ expected = "\n<Transfer transferCallerId=\"+19195551234\" transferCallerDisplayName=\"initial_caller\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\">\n <PhoneNumber>+19195551234</PhoneNumber>\n</Transfer>\n"
71
73
  expect(instance_nested.to_bxml).to eq(expected)
72
74
  end
73
75
 
74
76
  it 'tests the add_verb method of the nested Transfer instance' do
75
- expected_single = "\n<Transfer transferCallerId=\"+19195551234\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\">\n <PhoneNumber>+19195551234</PhoneNumber>\n <SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri>\n</Transfer>\n"
77
+ expected_single = "\n<Transfer transferCallerId=\"+19195551234\" transferCallerDisplayName=\"initial_caller\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\">\n <PhoneNumber>+19195551234</PhoneNumber>\n <SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri>\n</Transfer>\n"
76
78
  instance_nested.add_transfer_recipients(sip_uri)
77
79
  expect(instance_nested.to_bxml).to eq(expected_single)
78
80
 
79
- expected_multiple = "\n<Transfer transferCallerId=\"+19195551234\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\">\n <PhoneNumber>+19195551234</PhoneNumber>\n <SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri>\n <SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri>\n <PhoneNumber>+19195551234</PhoneNumber>\n</Transfer>\n"
81
+ expected_multiple = "\n<Transfer transferCallerId=\"+19195551234\" transferCallerDisplayName=\"initial_caller\" callTimeout=\"5\" transferCompleteUrl=\"https://initial.com\" transferCompleteMethod=\"POST\" transferCompleteFallbackUrl=\"https://initial.com\" transferCompleteFallbackMethod=\"POST\" username=\"initial_username\" password=\"initial_password\" fallbackUsername=\"initial_fallback_username\" fallbackPassword=\"initial_fallback_password\" tag=\"initial_tag\" diversionTreatment=\"propagate\" diversionReason=\"user-busy\">\n <PhoneNumber>+19195551234</PhoneNumber>\n <SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri>\n <SipUri>sip:1-999-123-4567@voip-provider.example.net</SipUri>\n <PhoneNumber>+19195551234</PhoneNumber>\n</Transfer>\n"
80
82
  instance_nested.add_transfer_recipients([sip_uri, phone_number])
81
83
  expect(instance_nested.to_bxml).to eq(expected_multiple)
82
84
  end
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: 11.2.0
4
+ version: 11.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bandwidth
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-16 00:00:00.000000000 Z
11
+ date: 2024-02-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -460,62 +460,62 @@ signing_key:
460
460
  specification_version: 4
461
461
  summary: Bandwidth Ruby SDK
462
462
  test_files:
463
- - spec/api/phone_number_lookup_api_spec.rb
464
463
  - spec/api/recordings_api_spec.rb
465
464
  - spec/api/mfa_api_spec.rb
465
+ - spec/api/calls_api_spec.rb
466
+ - spec/api/conferences_api_spec.rb
466
467
  - spec/api/statistics_api_spec.rb
467
468
  - spec/api/media_api_spec.rb
469
+ - spec/api/phone_number_lookup_api_spec.rb
468
470
  - spec/api/messages_api_spec.rb
469
- - spec/api/calls_api_spec.rb
470
- - spec/api/conferences_api_spec.rb
471
471
  - spec/api_client_spec.rb
472
472
  - spec/api_error_spec.rb
473
473
  - spec/call_utils.rb
474
474
  - spec/configuration_spec.rb
475
475
  - spec/fixtures/ruby_cat.jpeg
476
476
  - spec/integration/mfa_api_integration_spec.rb
477
- - spec/integration/messages_api_integration_spec.rb
477
+ - spec/integration/calls_api_integration_spec.rb
478
478
  - spec/integration/recordings_api_integration_spec.rb
479
+ - spec/integration/conferences_api_integration_spec.rb
480
+ - spec/integration/messages_api_integration_spec.rb
481
+ - spec/integration/phone_number_lookup_api_integration_spec.rb
479
482
  - spec/integration/media_api_integration_spec.rb
480
- - spec/integration/calls_api_integration_spec.rb
481
483
  - spec/integration/statistics_api_integration_spec.rb
482
- - spec/integration/phone_number_lookup_api_integration_spec.rb
483
- - spec/integration/conferences_api_integration_spec.rb
484
- - spec/models/verify_code_request_spec.rb
485
484
  - spec/models/deferred_result_spec.rb
486
- - spec/models/call_state_spec.rb
487
- - spec/models/message_spec.rb
485
+ - spec/models/verify_code_request_spec.rb
488
486
  - spec/models/call_state_enum_spec.rb
487
+ - spec/models/call_state_spec.rb
489
488
  - spec/models/bxml/bxml_spec.rb
490
489
  - spec/models/bxml/response_spec.rb
491
- - spec/models/bxml/nestable_verb_spec.rb
492
- - spec/models/bxml/verbs/gather_spec.rb
493
- - spec/models/bxml/verbs/phone_number_spec.rb
494
- - spec/models/bxml/verbs/start_transcription_spec.rb
490
+ - spec/models/bxml/verb_spec.rb
491
+ - spec/models/bxml/verbs/stop_stream_spec.rb
492
+ - spec/models/bxml/verbs/start_recording_spec.rb
493
+ - spec/models/bxml/verbs/send_dtmf_spec.rb
495
494
  - spec/models/bxml/verbs/speak_sentence_spec.rb
496
- - spec/models/bxml/verbs/hangup_spec.rb
497
495
  - spec/models/bxml/verbs/custom_param_spec.rb
498
- - spec/models/bxml/verbs/start_recording_spec.rb
499
- - spec/models/bxml/verbs/pause_spec.rb
500
- - spec/models/bxml/verbs/bridge_spec.rb
501
- - spec/models/bxml/verbs/stop_gather_spec.rb
502
- - spec/models/bxml/verbs/stream_param_spec.rb
503
- - spec/models/bxml/verbs/tag_spec.rb
504
- - spec/models/bxml/verbs/start_gather_spec.rb
505
- - spec/models/bxml/verbs/transfer_spec.rb
506
496
  - spec/models/bxml/verbs/start_stream_spec.rb
507
- - spec/models/bxml/verbs/stop_transcription_spec.rb
508
- - spec/models/bxml/verbs/play_audio_spec.rb
509
- - spec/models/bxml/verbs/sip_uri_spec.rb
510
- - spec/models/bxml/verbs/resume_recording_spec.rb
511
- - spec/models/bxml/verbs/stop_recording_spec.rb
497
+ - spec/models/bxml/verbs/start_transcription_spec.rb
512
498
  - spec/models/bxml/verbs/pause_recording_spec.rb
499
+ - spec/models/bxml/verbs/phone_number_spec.rb
500
+ - spec/models/bxml/verbs/stream_param_spec.rb
501
+ - spec/models/bxml/verbs/bridge_spec.rb
513
502
  - spec/models/bxml/verbs/record_spec.rb
514
- - spec/models/bxml/verbs/redirect_spec.rb
503
+ - spec/models/bxml/verbs/pause_spec.rb
504
+ - spec/models/bxml/verbs/play_audio_spec.rb
505
+ - spec/models/bxml/verbs/stop_recording_spec.rb
506
+ - spec/models/bxml/verbs/forward_spec.rb
507
+ - spec/models/bxml/verbs/stop_transcription_spec.rb
515
508
  - spec/models/bxml/verbs/ring_spec.rb
516
- - spec/models/bxml/verbs/send_dtmf_spec.rb
517
- - spec/models/bxml/verbs/stop_stream_spec.rb
509
+ - spec/models/bxml/verbs/tag_spec.rb
510
+ - spec/models/bxml/verbs/sip_uri_spec.rb
511
+ - spec/models/bxml/verbs/redirect_spec.rb
518
512
  - spec/models/bxml/verbs/conference_spec.rb
519
- - spec/models/bxml/verbs/forward_spec.rb
520
- - spec/models/bxml/verb_spec.rb
513
+ - spec/models/bxml/verbs/stop_gather_spec.rb
514
+ - spec/models/bxml/verbs/gather_spec.rb
515
+ - spec/models/bxml/verbs/resume_recording_spec.rb
516
+ - spec/models/bxml/verbs/start_gather_spec.rb
517
+ - spec/models/bxml/verbs/transfer_spec.rb
518
+ - spec/models/bxml/verbs/hangup_spec.rb
519
+ - spec/models/bxml/nestable_verb_spec.rb
520
+ - spec/models/message_spec.rb
521
521
  - spec/spec_helper.rb