bandwidth-sdk 11.2.0 → 12.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +29 -25
- data/README.md +14 -8
- data/bandwidth.yml +223 -17
- data/coverage/.last_run.json +1 -1
- data/coverage/.resultset.json +612 -209
- data/coverage/index.html +14875 -10424
- data/custom_templates/README.mustache +4 -4
- data/docs/CallRecordingMetadata.md +1 -1
- data/docs/CallTranscription.md +24 -0
- data/docs/CallTranscriptionMetadata.md +20 -0
- data/docs/CallTranscriptionResponse.md +24 -0
- data/docs/RecordingAvailableCallback.md +2 -2
- data/docs/RecordingTranscriptionMetadata.md +24 -0
- data/docs/RecordingTranscriptions.md +18 -0
- data/docs/RecordingsApi.md +49 -49
- data/docs/TranscriptionsApi.md +229 -0
- data/lib/bandwidth-sdk/api/recordings_api.rb +56 -56
- data/lib/bandwidth-sdk/api/transcriptions_api.rb +241 -0
- data/lib/bandwidth-sdk/configuration.rb +22 -4
- data/lib/bandwidth-sdk/models/bxml/verbs/transfer.rb +2 -1
- data/lib/bandwidth-sdk/models/call_recording_metadata.rb +1 -1
- data/lib/bandwidth-sdk/models/call_transcription.rb +317 -0
- data/lib/bandwidth-sdk/models/call_transcription_metadata.rb +223 -0
- data/lib/bandwidth-sdk/models/call_transcription_response.rb +244 -0
- data/lib/bandwidth-sdk/models/recording_available_callback.rb +2 -2
- data/lib/bandwidth-sdk/models/recording_transcription_metadata.rb +244 -0
- data/lib/bandwidth-sdk/models/recording_transcriptions.rb +214 -0
- data/lib/bandwidth-sdk/version.rb +1 -1
- data/lib/bandwidth-sdk.rb +6 -2
- data/spec/api/calls_api_spec.rb +4 -4
- data/spec/api/conferences_api_spec.rb +12 -12
- data/spec/api/media_api_spec.rb +6 -6
- data/spec/api/messages_api_spec.rb +2 -2
- data/spec/api/mfa_api_spec.rb +6 -6
- data/spec/api/phone_number_lookup_api_spec.rb +2 -2
- data/spec/api/recordings_api_spec.rb +30 -30
- data/spec/api/statistics_api_spec.rb +1 -1
- data/spec/api/transcriptions_api_spec.rb +130 -0
- data/spec/api_client_spec.rb +2 -2
- data/spec/integration/calls_api_integration_spec.rb +7 -7
- data/spec/integration/conferences_api_integration_spec.rb +9 -9
- data/spec/integration/media_api_integration_spec.rb +7 -7
- data/spec/integration/messages_api_integration_spec.rb +3 -3
- data/spec/integration/mfa_api_integration_spec.rb +3 -3
- data/spec/integration/phone_number_lookup_api_integration_spec.rb +2 -2
- data/spec/integration/recordings_api_integration_spec.rb +14 -14
- data/spec/integration/statistics_api_integration_spec.rb +1 -1
- data/spec/integration/transcriptions_api_integration_spec.rb +84 -0
- data/spec/models/bxml/verbs/transfer_spec.rb +7 -5
- data/spec/spec_helper.rb +1 -1
- metadata +50 -34
@@ -34,14 +34,14 @@ describe 'RecordingsApi Integration Tests' do
|
|
34
34
|
)
|
35
35
|
|
36
36
|
sleep(SLEEP_TIME_S * 2)
|
37
|
-
|
37
|
+
_pause_data, pause_status_code = @recordings_api_instance.update_call_recording_state_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, pause_recording)
|
38
38
|
expect(pause_status_code).to eq(200)
|
39
39
|
|
40
40
|
sleep(SLEEP_TIME_S)
|
41
|
-
|
41
|
+
_record_data, record_status_code = @recordings_api_instance.update_call_recording_state_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, start_recording)
|
42
42
|
expect(record_status_code).to eq(200)
|
43
43
|
|
44
|
-
|
44
|
+
_complete_data, complete_status_code = @calls_api_instance.update_call_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $complete_call_body)
|
45
45
|
expect(complete_status_code).to eq(200)
|
46
46
|
|
47
47
|
retries = 0
|
@@ -63,7 +63,7 @@ describe 'RecordingsApi Integration Tests' do
|
|
63
63
|
# Get Call Recordings
|
64
64
|
describe 'list_account_call_recordings' do
|
65
65
|
it 'lists account call recordings' do
|
66
|
-
data, status_code
|
66
|
+
data, status_code = @recordings_api_instance.list_account_call_recordings_with_http_info(BW_ACCOUNT_ID)
|
67
67
|
|
68
68
|
expect(status_code).to eq(200)
|
69
69
|
expect(data).to be_instance_of(Array)
|
@@ -76,7 +76,7 @@ describe 'RecordingsApi Integration Tests' do
|
|
76
76
|
# List Call Recordings
|
77
77
|
describe 'list_call_recordings' do
|
78
78
|
it 'lists all recordings for a single call' do
|
79
|
-
data, status_code
|
79
|
+
data, status_code = @recordings_api_instance.list_call_recordings_with_http_info(BW_ACCOUNT_ID, $manteca_call_id)
|
80
80
|
|
81
81
|
expect(status_code).to eq(200)
|
82
82
|
expect(data).to be_instance_of(Array)
|
@@ -94,7 +94,7 @@ describe 'RecordingsApi Integration Tests' do
|
|
94
94
|
# Get Call Recording
|
95
95
|
describe 'get_call_recording' do
|
96
96
|
it 'gets a call recording by id' do
|
97
|
-
data, status_code
|
97
|
+
data, status_code = @recordings_api_instance.get_call_recording_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $recording_id)
|
98
98
|
|
99
99
|
expect(status_code).to eq(200)
|
100
100
|
expect(data).to be_instance_of(Bandwidth::CallRecordingMetadata)
|
@@ -109,7 +109,7 @@ describe 'RecordingsApi Integration Tests' do
|
|
109
109
|
# Download Recording
|
110
110
|
describe 'download_call_recording' do
|
111
111
|
it 'downloads a call recording by id' do
|
112
|
-
data, status_code
|
112
|
+
data, status_code = @recordings_api_instance.download_call_recording_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $recording_id)
|
113
113
|
|
114
114
|
expect(status_code).to eq(200)
|
115
115
|
expect(data).to be_instance_of(String)
|
@@ -118,13 +118,13 @@ describe 'RecordingsApi Integration Tests' do
|
|
118
118
|
|
119
119
|
# Create Transcription Request
|
120
120
|
describe 'transcribe_call_recording' do
|
121
|
-
it 'creates a transcription request' do
|
121
|
+
it 'creates a recording transcription request' do
|
122
122
|
transcribe_recording = Bandwidth::TranscribeRecording.new(
|
123
123
|
callback_url: MANTECA_BASE_URL + '/transcriptions',
|
124
124
|
tag: $manteca_test_id
|
125
125
|
)
|
126
126
|
|
127
|
-
|
127
|
+
_data, status_code = @recordings_api_instance.transcribe_call_recording_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $recording_id, transcribe_recording)
|
128
128
|
expect(status_code).to eq(204)
|
129
129
|
|
130
130
|
retries = 0
|
@@ -147,10 +147,10 @@ describe 'RecordingsApi Integration Tests' do
|
|
147
147
|
# Get Transcription
|
148
148
|
describe 'get_call_transcription' do
|
149
149
|
it 'gets the completed call recording transcription' do
|
150
|
-
data, status_code
|
150
|
+
data, status_code = @recordings_api_instance.get_recording_transcription_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $recording_id)
|
151
151
|
|
152
152
|
expect(status_code).to eq(200)
|
153
|
-
expect(data).to be_instance_of(Bandwidth::
|
153
|
+
expect(data).to be_instance_of(Bandwidth::RecordingTranscriptions)
|
154
154
|
expect(data.transcripts).to be_instance_of(Array)
|
155
155
|
expect(data.transcripts[0]).to be_instance_of(Bandwidth::Transcription)
|
156
156
|
expect(data.transcripts[0].text).to be_instance_of(String)
|
@@ -161,7 +161,7 @@ describe 'RecordingsApi Integration Tests' do
|
|
161
161
|
# Delete Transcription
|
162
162
|
describe 'delete_call_transcription' do
|
163
163
|
it 'deletes the completed call recording transcription' do
|
164
|
-
|
164
|
+
_data, status_code = @recordings_api_instance.delete_recording_transcription_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $recording_id)
|
165
165
|
expect(status_code).to eq(204)
|
166
166
|
end
|
167
167
|
end
|
@@ -169,7 +169,7 @@ describe 'RecordingsApi Integration Tests' do
|
|
169
169
|
# Delete Recording Media
|
170
170
|
describe 'delete_recording_media' do
|
171
171
|
it 'deletes the completed call recording media' do
|
172
|
-
|
172
|
+
_data, status_code = @recordings_api_instance.delete_recording_media_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $recording_id)
|
173
173
|
expect(status_code).to eq(204)
|
174
174
|
end
|
175
175
|
end
|
@@ -177,7 +177,7 @@ describe 'RecordingsApi Integration Tests' do
|
|
177
177
|
# Delete Recording
|
178
178
|
describe 'delete_recording' do
|
179
179
|
it 'deletes the completed call recording data' do
|
180
|
-
|
180
|
+
_data, status_code = @recordings_api_instance.delete_recording_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $recording_id)
|
181
181
|
expect(status_code).to eq(204)
|
182
182
|
end
|
183
183
|
end
|
@@ -16,7 +16,7 @@ describe 'StatisticsApi Integration Tests' do
|
|
16
16
|
# Get Account Statistics
|
17
17
|
describe 'get_statistics' do
|
18
18
|
it 'gets account statistics' do
|
19
|
-
data, status_code
|
19
|
+
data, status_code = @statistics_api_instance.get_statistics_with_http_info(BW_ACCOUNT_ID)
|
20
20
|
|
21
21
|
expect(status_code).to eq(200)
|
22
22
|
expect(data).to be_instance_of(Bandwidth::AccountStatistics)
|
@@ -0,0 +1,84 @@
|
|
1
|
+
require_relative '../call_utils'
|
2
|
+
|
3
|
+
# Integration Tests for Bandwidth::TranscriptionsApi
|
4
|
+
describe 'TranscriptionsApi Integration Tests' do
|
5
|
+
before(:all) do
|
6
|
+
WebMock.allow_net_connect!
|
7
|
+
Bandwidth.configure do |config|
|
8
|
+
config.username = BW_USERNAME
|
9
|
+
config.password = BW_PASSWORD
|
10
|
+
end
|
11
|
+
@transcriptions_api_instance = Bandwidth::TranscriptionsApi.new
|
12
|
+
@calls_api_instance = Bandwidth::CallsApi.new
|
13
|
+
|
14
|
+
# transcription info
|
15
|
+
$manteca_test_id = setup_manteca('CALL')
|
16
|
+
$manteca_call_id = create_manteca_call($manteca_test_id, '/bxml/idle', @calls_api_instance)
|
17
|
+
$transcription_id = ''
|
18
|
+
end
|
19
|
+
|
20
|
+
after(:all) do
|
21
|
+
WebMock.disable_net_connect!
|
22
|
+
end
|
23
|
+
|
24
|
+
# Create Call Transcription
|
25
|
+
describe 'create_call_transcription' do
|
26
|
+
it 'creates a call transcription' do
|
27
|
+
sleep(SLEEP_TIME_S)
|
28
|
+
|
29
|
+
start_transcription_bxml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?><Response><StartTranscription name=\"#{$manteca_call_id}\" tracks=\"inbound\"></StartTranscription><Pause duration=\"6\"/></Response>"
|
30
|
+
_start_data, start_status_code = @calls_api_instance.update_call_bxml_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, start_transcription_bxml)
|
31
|
+
expect(start_status_code).to eq(204)
|
32
|
+
sleep(SLEEP_TIME_S)
|
33
|
+
|
34
|
+
stop_transcription_bxml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?><Response><StopTranscription name=\"#{$manteca_call_id}\"></StopTranscription></Response>"
|
35
|
+
_stop_data, stop_status_code = @calls_api_instance.update_call_bxml_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, stop_transcription_bxml)
|
36
|
+
expect(stop_status_code).to eq(204)
|
37
|
+
sleep(SLEEP_TIME_S)
|
38
|
+
|
39
|
+
_complete_data, complete_status_code = @calls_api_instance.update_call_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $complete_call_body)
|
40
|
+
expect(complete_status_code).to eq(200)
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
# List Real Time Call Transcriptions
|
45
|
+
describe 'list_real_time_transcriptions' do
|
46
|
+
it 'lists call transcriptions' do
|
47
|
+
sleep(SLEEP_TIME_S * 20)
|
48
|
+
data, status_code, _headers = @transcriptions_api_instance.list_real_time_transcriptions_with_http_info(BW_ACCOUNT_ID, $manteca_call_id)
|
49
|
+
|
50
|
+
expect(status_code).to eq(200)
|
51
|
+
expect(data).to be_instance_of(Array)
|
52
|
+
expect(data[0]).to be_instance_of(Bandwidth::CallTranscriptionMetadata)
|
53
|
+
expect(data[0].transcription_id).to be_instance_of(String)
|
54
|
+
expect(data[0].transcription_url).to be_instance_of(String)
|
55
|
+
$transcription_id = data[0].transcription_id
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
# Get Real Time Call Transcription
|
60
|
+
describe 'get_real_time_transcription' do
|
61
|
+
it 'gets the specified call transcription' do
|
62
|
+
data, status_code, _headers = @transcriptions_api_instance.get_real_time_transcription_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $transcription_id)
|
63
|
+
|
64
|
+
expect(status_code).to eq(200)
|
65
|
+
expect(data).to be_instance_of(Bandwidth::CallTranscriptionResponse)
|
66
|
+
expect(data.account_id).to eq(BW_ACCOUNT_ID)
|
67
|
+
expect(data.call_id).to eq($manteca_call_id)
|
68
|
+
expect(data.transcription_id).to eq($transcription_id)
|
69
|
+
expect(data.tracks).to be_instance_of(Array)
|
70
|
+
expect(data.tracks[0]).to be_instance_of(Bandwidth::CallTranscription)
|
71
|
+
expect(data.tracks[0].track).to eq('inbound')
|
72
|
+
expect(data.tracks[0].confidence).to be_instance_of(Float)
|
73
|
+
end
|
74
|
+
end
|
75
|
+
|
76
|
+
# Delete Real Time Call Transcription
|
77
|
+
describe 'delete_real_time_transcription' do
|
78
|
+
it 'deletes the specified call transcription' do
|
79
|
+
_data, status_code = @transcriptions_api_instance.delete_real_time_transcription_with_http_info(BW_ACCOUNT_ID, $manteca_call_id, $transcription_id)
|
80
|
+
|
81
|
+
expect(status_code).to eq(200) # This is a bug in the API, it should return 204. VAPI-1863 should fix this.
|
82
|
+
end
|
83
|
+
end
|
84
|
+
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
|
data/spec/spec_helper.rb
CHANGED
@@ -89,7 +89,7 @@ RSpec.configure do |config|
|
|
89
89
|
config.password = BW_PASSWORD
|
90
90
|
end
|
91
91
|
calls_api = Bandwidth::CallsApi.new
|
92
|
-
# cleanup_calls($active_calls, calls_api)
|
92
|
+
# cleanup_calls($active_calls, calls_api) # left out due to voice API issues
|
93
93
|
}
|
94
94
|
|
95
95
|
# rspec-expectations config goes here. You can use an alternate
|
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:
|
4
|
+
version: 12.0.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-
|
11
|
+
date: 2024-05-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -137,6 +137,9 @@ files:
|
|
137
137
|
- docs/CallRecordingMetadata.md
|
138
138
|
- docs/CallState.md
|
139
139
|
- docs/CallStateEnum.md
|
140
|
+
- docs/CallTranscription.md
|
141
|
+
- docs/CallTranscriptionMetadata.md
|
142
|
+
- docs/CallTranscriptionResponse.md
|
140
143
|
- docs/CallbackMethodEnum.md
|
141
144
|
- docs/CallsApi.md
|
142
145
|
- docs/CodeRequest.md
|
@@ -211,6 +214,8 @@ files:
|
|
211
214
|
- docs/RecordingAvailableCallback.md
|
212
215
|
- docs/RecordingCompleteCallback.md
|
213
216
|
- docs/RecordingStateEnum.md
|
217
|
+
- docs/RecordingTranscriptionMetadata.md
|
218
|
+
- docs/RecordingTranscriptions.md
|
214
219
|
- docs/RecordingsApi.md
|
215
220
|
- docs/RedirectCallback.md
|
216
221
|
- docs/RedirectMethodEnum.md
|
@@ -227,6 +232,7 @@ files:
|
|
227
232
|
- docs/TranscriptionAvailableCallback.md
|
228
233
|
- docs/TranscriptionList.md
|
229
234
|
- docs/TranscriptionMetadata.md
|
235
|
+
- docs/TranscriptionsApi.md
|
230
236
|
- docs/TransferAnswerCallback.md
|
231
237
|
- docs/TransferCompleteCallback.md
|
232
238
|
- docs/TransferDisconnectCallback.md
|
@@ -249,6 +255,7 @@ files:
|
|
249
255
|
- lib/bandwidth-sdk/api/phone_number_lookup_api.rb
|
250
256
|
- lib/bandwidth-sdk/api/recordings_api.rb
|
251
257
|
- lib/bandwidth-sdk/api/statistics_api.rb
|
258
|
+
- lib/bandwidth-sdk/api/transcriptions_api.rb
|
252
259
|
- lib/bandwidth-sdk/api_client.rb
|
253
260
|
- lib/bandwidth-sdk/api_error.rb
|
254
261
|
- lib/bandwidth-sdk/configuration.rb
|
@@ -293,6 +300,9 @@ files:
|
|
293
300
|
- lib/bandwidth-sdk/models/call_recording_metadata.rb
|
294
301
|
- lib/bandwidth-sdk/models/call_state.rb
|
295
302
|
- lib/bandwidth-sdk/models/call_state_enum.rb
|
303
|
+
- lib/bandwidth-sdk/models/call_transcription.rb
|
304
|
+
- lib/bandwidth-sdk/models/call_transcription_metadata.rb
|
305
|
+
- lib/bandwidth-sdk/models/call_transcription_response.rb
|
296
306
|
- lib/bandwidth-sdk/models/callback_method_enum.rb
|
297
307
|
- lib/bandwidth-sdk/models/code_request.rb
|
298
308
|
- lib/bandwidth-sdk/models/conference.rb
|
@@ -353,6 +363,8 @@ files:
|
|
353
363
|
- lib/bandwidth-sdk/models/recording_available_callback.rb
|
354
364
|
- lib/bandwidth-sdk/models/recording_complete_callback.rb
|
355
365
|
- lib/bandwidth-sdk/models/recording_state_enum.rb
|
366
|
+
- lib/bandwidth-sdk/models/recording_transcription_metadata.rb
|
367
|
+
- lib/bandwidth-sdk/models/recording_transcriptions.rb
|
356
368
|
- lib/bandwidth-sdk/models/redirect_callback.rb
|
357
369
|
- lib/bandwidth-sdk/models/redirect_method_enum.rb
|
358
370
|
- lib/bandwidth-sdk/models/stir_shaken.rb
|
@@ -385,6 +397,7 @@ files:
|
|
385
397
|
- spec/api/phone_number_lookup_api_spec.rb
|
386
398
|
- spec/api/recordings_api_spec.rb
|
387
399
|
- spec/api/statistics_api_spec.rb
|
400
|
+
- spec/api/transcriptions_api_spec.rb
|
388
401
|
- spec/api_client_spec.rb
|
389
402
|
- spec/api_error_spec.rb
|
390
403
|
- spec/call_utils.rb
|
@@ -398,6 +411,7 @@ files:
|
|
398
411
|
- spec/integration/phone_number_lookup_api_integration_spec.rb
|
399
412
|
- spec/integration/recordings_api_integration_spec.rb
|
400
413
|
- spec/integration/statistics_api_integration_spec.rb
|
414
|
+
- spec/integration/transcriptions_api_integration_spec.rb
|
401
415
|
- spec/models/bxml/bxml_spec.rb
|
402
416
|
- spec/models/bxml/nestable_verb_spec.rb
|
403
417
|
- spec/models/bxml/response_spec.rb
|
@@ -460,62 +474,64 @@ signing_key:
|
|
460
474
|
specification_version: 4
|
461
475
|
summary: Bandwidth Ruby SDK
|
462
476
|
test_files:
|
463
|
-
- spec/api/phone_number_lookup_api_spec.rb
|
464
|
-
- spec/api/recordings_api_spec.rb
|
465
477
|
- spec/api/mfa_api_spec.rb
|
466
478
|
- spec/api/statistics_api_spec.rb
|
479
|
+
- spec/api/calls_api_spec.rb
|
467
480
|
- spec/api/media_api_spec.rb
|
468
481
|
- spec/api/messages_api_spec.rb
|
469
|
-
- spec/api/
|
482
|
+
- spec/api/recordings_api_spec.rb
|
483
|
+
- spec/api/transcriptions_api_spec.rb
|
484
|
+
- spec/api/phone_number_lookup_api_spec.rb
|
470
485
|
- spec/api/conferences_api_spec.rb
|
471
486
|
- spec/api_client_spec.rb
|
472
487
|
- spec/api_error_spec.rb
|
473
488
|
- spec/call_utils.rb
|
474
489
|
- spec/configuration_spec.rb
|
475
490
|
- spec/fixtures/ruby_cat.jpeg
|
476
|
-
- spec/integration/mfa_api_integration_spec.rb
|
477
|
-
- spec/integration/messages_api_integration_spec.rb
|
478
491
|
- spec/integration/recordings_api_integration_spec.rb
|
479
|
-
- spec/integration/
|
492
|
+
- spec/integration/messages_api_integration_spec.rb
|
493
|
+
- spec/integration/conferences_api_integration_spec.rb
|
494
|
+
- spec/integration/mfa_api_integration_spec.rb
|
495
|
+
- spec/integration/phone_number_lookup_api_integration_spec.rb
|
480
496
|
- spec/integration/calls_api_integration_spec.rb
|
497
|
+
- spec/integration/transcriptions_api_integration_spec.rb
|
498
|
+
- spec/integration/media_api_integration_spec.rb
|
481
499
|
- spec/integration/statistics_api_integration_spec.rb
|
482
|
-
- spec/
|
483
|
-
- spec/
|
500
|
+
- spec/models/message_spec.rb
|
501
|
+
- spec/models/call_state_enum_spec.rb
|
484
502
|
- spec/models/verify_code_request_spec.rb
|
485
503
|
- spec/models/deferred_result_spec.rb
|
486
504
|
- spec/models/call_state_spec.rb
|
487
|
-
- spec/models/message_spec.rb
|
488
|
-
- spec/models/call_state_enum_spec.rb
|
489
505
|
- spec/models/bxml/bxml_spec.rb
|
490
|
-
- spec/models/bxml/response_spec.rb
|
491
506
|
- spec/models/bxml/nestable_verb_spec.rb
|
492
|
-
- spec/models/bxml/
|
493
|
-
- spec/models/bxml/verbs/
|
494
|
-
- spec/models/bxml/verbs/
|
507
|
+
- spec/models/bxml/verb_spec.rb
|
508
|
+
- spec/models/bxml/verbs/conference_spec.rb
|
509
|
+
- spec/models/bxml/verbs/stream_param_spec.rb
|
495
510
|
- spec/models/bxml/verbs/speak_sentence_spec.rb
|
496
|
-
- spec/models/bxml/verbs/
|
511
|
+
- spec/models/bxml/verbs/stop_recording_spec.rb
|
512
|
+
- spec/models/bxml/verbs/resume_recording_spec.rb
|
513
|
+
- spec/models/bxml/verbs/start_stream_spec.rb
|
514
|
+
- spec/models/bxml/verbs/start_gather_spec.rb
|
515
|
+
- spec/models/bxml/verbs/redirect_spec.rb
|
516
|
+
- spec/models/bxml/verbs/sip_uri_spec.rb
|
517
|
+
- spec/models/bxml/verbs/ring_spec.rb
|
497
518
|
- spec/models/bxml/verbs/custom_param_spec.rb
|
498
|
-
- spec/models/bxml/verbs/
|
499
|
-
- spec/models/bxml/verbs/
|
519
|
+
- spec/models/bxml/verbs/send_dtmf_spec.rb
|
520
|
+
- spec/models/bxml/verbs/start_transcription_spec.rb
|
521
|
+
- spec/models/bxml/verbs/gather_spec.rb
|
522
|
+
- spec/models/bxml/verbs/phone_number_spec.rb
|
500
523
|
- 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
524
|
- spec/models/bxml/verbs/transfer_spec.rb
|
506
|
-
- spec/models/bxml/verbs/
|
525
|
+
- spec/models/bxml/verbs/pause_spec.rb
|
526
|
+
- spec/models/bxml/verbs/start_recording_spec.rb
|
527
|
+
- spec/models/bxml/verbs/stop_gather_spec.rb
|
507
528
|
- spec/models/bxml/verbs/stop_transcription_spec.rb
|
508
529
|
- spec/models/bxml/verbs/play_audio_spec.rb
|
509
|
-
- spec/models/bxml/verbs/
|
510
|
-
- spec/models/bxml/verbs/
|
511
|
-
- spec/models/bxml/verbs/
|
530
|
+
- spec/models/bxml/verbs/tag_spec.rb
|
531
|
+
- spec/models/bxml/verbs/hangup_spec.rb
|
532
|
+
- spec/models/bxml/verbs/forward_spec.rb
|
512
533
|
- spec/models/bxml/verbs/pause_recording_spec.rb
|
513
|
-
- spec/models/bxml/verbs/record_spec.rb
|
514
|
-
- spec/models/bxml/verbs/redirect_spec.rb
|
515
|
-
- spec/models/bxml/verbs/ring_spec.rb
|
516
|
-
- spec/models/bxml/verbs/send_dtmf_spec.rb
|
517
534
|
- spec/models/bxml/verbs/stop_stream_spec.rb
|
518
|
-
- spec/models/bxml/verbs/
|
519
|
-
- spec/models/bxml/
|
520
|
-
- spec/models/bxml/verb_spec.rb
|
535
|
+
- spec/models/bxml/verbs/record_spec.rb
|
536
|
+
- spec/models/bxml/response_spec.rb
|
521
537
|
- spec/spec_helper.rb
|