twilio-ruby 5.7.2 → 5.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +4 -0
- data/CHANGES.md +19 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/framework/error.rb +20 -6
- data/lib/twilio-ruby/framework/version.rb +1 -10
- data/lib/twilio-ruby/jwt/access_token.rb +3 -1
- data/lib/twilio-ruby/rest/lookups/v1/phone_number.rb +0 -7
- data/lib/twilio-ruby/rest/preview.rb +11 -3
- data/lib/twilio-ruby/rest/preview/understand.rb +6 -6
- data/lib/twilio-ruby/rest/preview/understand/{service.rb → assistant.rb} +94 -55
- data/lib/twilio-ruby/rest/preview/understand/{service → assistant}/field_type.rb +33 -23
- data/lib/twilio-ruby/rest/preview/understand/{service → assistant}/field_type/field_value.rb +30 -22
- data/lib/twilio-ruby/rest/preview/understand/{service → assistant}/intent.rb +39 -25
- data/lib/twilio-ruby/rest/preview/understand/{service → assistant}/intent/field.rb +20 -20
- data/lib/twilio-ruby/rest/preview/understand/{service → assistant}/intent/sample.rb +45 -27
- data/lib/twilio-ruby/rest/preview/understand/{service → assistant}/model_build.rb +21 -21
- data/lib/twilio-ruby/rest/preview/understand/{service → assistant}/query.rb +31 -26
- data/lib/twilio-ruby/rest/studio/v1/flow/engagement.rb +6 -2
- data/lib/twilio-ruby/rest/video/v1/recording.rb +1 -1
- data/lib/twilio-ruby/version.rb +1 -1
- data/spec/integration/accounts/v1/credential/aws_spec.rb +9 -9
- data/spec/integration/accounts/v1/credential/public_key_spec.rb +9 -9
- data/spec/integration/api/v2010/account/address/dependent_phone_number_spec.rb +7 -7
- data/spec/integration/api/v2010/account/address_spec.rb +22 -22
- data/spec/integration/api/v2010/account/application_spec.rb +22 -22
- data/spec/integration/api/v2010/account/authorized_connect_app_spec.rb +9 -9
- data/spec/integration/api/v2010/account/available_phone_number/local_spec.rb +4 -4
- data/spec/integration/api/v2010/account/available_phone_number/machine_to_machine_spec.rb +4 -4
- data/spec/integration/api/v2010/account/available_phone_number/mobile_spec.rb +4 -4
- data/spec/integration/api/v2010/account/available_phone_number/national_spec.rb +4 -4
- data/spec/integration/api/v2010/account/available_phone_number/shared_cost_spec.rb +4 -4
- data/spec/integration/api/v2010/account/available_phone_number/toll_free_spec.rb +4 -4
- data/spec/integration/api/v2010/account/available_phone_number/voip_spec.rb +4 -4
- data/spec/integration/api/v2010/account/available_phone_number_spec.rb +7 -7
- data/spec/integration/api/v2010/account/call/feedback_spec.rb +15 -15
- data/spec/integration/api/v2010/account/call/feedback_summary_spec.rb +13 -13
- data/spec/integration/api/v2010/account/call/notification_spec.rb +21 -21
- data/spec/integration/api/v2010/account/call/recording_spec.rb +21 -21
- data/spec/integration/api/v2010/account/call_spec.rb +22 -22
- data/spec/integration/api/v2010/account/conference/participant_spec.rb +35 -35
- data/spec/integration/api/v2010/account/conference_spec.rb +14 -14
- data/spec/integration/api/v2010/account/connect_app_spec.rb +14 -14
- data/spec/integration/api/v2010/account/incoming_phone_number/assigned_add_on/assigned_add_on_extension_spec.rb +19 -19
- data/spec/integration/api/v2010/account/incoming_phone_number/assigned_add_on_spec.rb +29 -29
- data/spec/integration/api/v2010/account/incoming_phone_number/local_spec.rb +7 -7
- data/spec/integration/api/v2010/account/incoming_phone_number/mobile_spec.rb +7 -7
- data/spec/integration/api/v2010/account/incoming_phone_number/toll_free_spec.rb +7 -7
- data/spec/integration/api/v2010/account/incoming_phone_number_spec.rb +22 -22
- data/spec/integration/api/v2010/account/key_spec.rb +19 -19
- data/spec/integration/api/v2010/account/message/feedback_spec.rb +5 -5
- data/spec/integration/api/v2010/account/message/media_spec.rb +21 -21
- data/spec/integration/api/v2010/account/message_spec.rb +22 -22
- data/spec/integration/api/v2010/account/new_key_spec.rb +3 -3
- data/spec/integration/api/v2010/account/new_signing_key_spec.rb +3 -3
- data/spec/integration/api/v2010/account/notification_spec.rb +14 -14
- data/spec/integration/api/v2010/account/outgoing_caller_id_spec.rb +19 -19
- data/spec/integration/api/v2010/account/queue/member_spec.rb +21 -21
- data/spec/integration/api/v2010/account/queue_spec.rb +22 -22
- data/spec/integration/api/v2010/account/recording/add_on_result/payload_spec.rb +28 -28
- data/spec/integration/api/v2010/account/recording/add_on_result_spec.rb +21 -21
- data/spec/integration/api/v2010/account/recording/transcription_spec.rb +21 -21
- data/spec/integration/api/v2010/account/recording_spec.rb +14 -14
- data/spec/integration/api/v2010/account/short_code_spec.rb +14 -14
- data/spec/integration/api/v2010/account/signing_key_spec.rb +19 -19
- data/spec/integration/api/v2010/account/sip/credential_list/credential_spec.rb +33 -33
- data/spec/integration/api/v2010/account/sip/credential_list_spec.rb +22 -22
- data/spec/integration/api/v2010/account/sip/domain/credential_list_mapping_spec.rb +29 -29
- data/spec/integration/api/v2010/account/sip/domain/ip_access_control_list_mapping_spec.rb +29 -29
- data/spec/integration/api/v2010/account/sip/domain_spec.rb +22 -22
- data/spec/integration/api/v2010/account/sip/ip_access_control_list/ip_address_spec.rb +33 -33
- data/spec/integration/api/v2010/account/sip/ip_access_control_list_spec.rb +22 -22
- data/spec/integration/api/v2010/account/token_spec.rb +3 -3
- data/spec/integration/api/v2010/account/transcription_spec.rb +14 -14
- data/spec/integration/api/v2010/account/usage/record/all_time_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record/daily_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record/last_month_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record/monthly_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record/this_month_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record/today_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record/yearly_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record/yesterday_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/record_spec.rb +4 -4
- data/spec/integration/api/v2010/account/usage/trigger_spec.rb +22 -22
- data/spec/integration/api/v2010/account/validation_request_spec.rb +3 -3
- data/spec/integration/api/v2010/account_spec.rb +84 -68
- data/spec/integration/chat/v1/credential_spec.rb +9 -9
- data/spec/integration/chat/v1/service/channel/invite_spec.rb +26 -26
- data/spec/integration/chat/v1/service/channel/member_spec.rb +36 -36
- data/spec/integration/chat/v1/service/channel/message_spec.rb +35 -35
- data/spec/integration/chat/v1/service/channel_spec.rb +22 -22
- data/spec/integration/chat/v1/service/role_spec.rb +22 -22
- data/spec/integration/chat/v1/service/user/user_channel_spec.rb +7 -7
- data/spec/integration/chat/v1/service/user_spec.rb +22 -22
- data/spec/integration/chat/v1/service_spec.rb +9 -9
- data/spec/integration/chat/v2/credential_spec.rb +9 -9
- data/spec/integration/chat/v2/service/binding_spec.rb +14 -14
- data/spec/integration/chat/v2/service/channel/invite_spec.rb +26 -26
- data/spec/integration/chat/v2/service/channel/member_spec.rb +33 -33
- data/spec/integration/chat/v2/service/channel/message_spec.rb +40 -40
- data/spec/integration/chat/v2/service/channel_spec.rb +22 -22
- data/spec/integration/chat/v2/service/role_spec.rb +22 -22
- data/spec/integration/chat/v2/service/user/user_binding_spec.rb +21 -21
- data/spec/integration/chat/v2/service/user/user_channel_spec.rb +7 -7
- data/spec/integration/chat/v2/service/user_spec.rb +22 -22
- data/spec/integration/chat/v2/service_spec.rb +9 -9
- data/spec/integration/fax/v1/fax/fax_media_spec.rb +13 -13
- data/spec/integration/fax/v1/fax_spec.rb +9 -9
- data/spec/integration/ip_messaging/v1/credential_spec.rb +9 -9
- data/spec/integration/ip_messaging/v1/service/channel/invite_spec.rb +26 -26
- data/spec/integration/ip_messaging/v1/service/channel/member_spec.rb +36 -36
- data/spec/integration/ip_messaging/v1/service/channel/message_spec.rb +35 -35
- data/spec/integration/ip_messaging/v1/service/channel_spec.rb +22 -22
- data/spec/integration/ip_messaging/v1/service/role_spec.rb +22 -22
- data/spec/integration/ip_messaging/v1/service/user/user_channel_spec.rb +7 -7
- data/spec/integration/ip_messaging/v1/service/user_spec.rb +22 -22
- data/spec/integration/ip_messaging/v1/service_spec.rb +9 -9
- data/spec/integration/ip_messaging/v2/credential_spec.rb +9 -9
- data/spec/integration/ip_messaging/v2/service/binding_spec.rb +14 -14
- data/spec/integration/ip_messaging/v2/service/channel/invite_spec.rb +26 -26
- data/spec/integration/ip_messaging/v2/service/channel/member_spec.rb +33 -33
- data/spec/integration/ip_messaging/v2/service/channel/message_spec.rb +40 -40
- data/spec/integration/ip_messaging/v2/service/channel_spec.rb +22 -22
- data/spec/integration/ip_messaging/v2/service/role_spec.rb +22 -22
- data/spec/integration/ip_messaging/v2/service/user/user_binding_spec.rb +21 -21
- data/spec/integration/ip_messaging/v2/service/user/user_channel_spec.rb +7 -7
- data/spec/integration/ip_messaging/v2/service/user_spec.rb +22 -22
- data/spec/integration/ip_messaging/v2/service_spec.rb +9 -9
- data/spec/integration/lookups/v1/phone_number_spec.rb +0 -10
- data/spec/integration/messaging/v1/service/alpha_sender_spec.rb +16 -16
- data/spec/integration/messaging/v1/service/phone_number_spec.rb +21 -21
- data/spec/integration/messaging/v1/service/short_code_spec.rb +19 -19
- data/spec/integration/messaging/v1/service_spec.rb +9 -9
- data/spec/integration/monitor/v1/alert_spec.rb +6 -6
- data/spec/integration/monitor/v1/event_spec.rb +3 -3
- data/spec/integration/notify/v1/credential_spec.rb +9 -9
- data/spec/integration/notify/v1/service/binding_spec.rb +17 -17
- data/spec/integration/notify/v1/service/notification_spec.rb +4 -4
- data/spec/integration/notify/v1/service/segment_spec.rb +4 -4
- data/spec/integration/notify/v1/service/user/segment_memberships_spec.rb +15 -15
- data/spec/integration/notify/v1/service/user/user_binding_spec.rb +28 -28
- data/spec/integration/notify/v1/service/user_spec.rb +17 -17
- data/spec/integration/notify/v1/service_spec.rb +9 -9
- data/spec/integration/preview/acc_security/service/verification_check_spec.rb +3 -3
- data/spec/integration/preview/acc_security/service/verification_spec.rb +3 -3
- data/spec/integration/preview/acc_security/service_spec.rb +6 -6
- data/spec/integration/preview/deployed_devices/fleet/certificate_spec.rb +22 -22
- data/spec/integration/preview/deployed_devices/fleet/deployment_spec.rb +22 -22
- data/spec/integration/preview/deployed_devices/fleet/device_spec.rb +22 -22
- data/spec/integration/preview/deployed_devices/fleet/key_spec.rb +22 -22
- data/spec/integration/preview/deployed_devices/fleet_spec.rb +9 -9
- data/spec/integration/preview/hosted_numbers/authorization_document/dependent_hosted_number_order_spec.rb +4 -4
- data/spec/integration/preview/hosted_numbers/authorization_document_spec.rb +9 -9
- data/spec/integration/preview/hosted_numbers/hosted_number_order_spec.rb +9 -9
- data/spec/integration/preview/marketplace/available_add_on/available_add_on_extension_spec.rb +9 -9
- data/spec/integration/preview/marketplace/available_add_on_spec.rb +3 -3
- data/spec/integration/preview/marketplace/installed_add_on/installed_add_on_extension_spec.rb +14 -14
- data/spec/integration/preview/marketplace/installed_add_on_spec.rb +12 -12
- data/spec/integration/preview/proxy/service/phone_number_spec.rb +19 -19
- data/spec/integration/preview/proxy/service/session/interaction_spec.rb +12 -12
- data/spec/integration/preview/proxy/service/session/participant/message_interaction_spec.rb +23 -23
- data/spec/integration/preview/proxy/service/session/participant_spec.rb +31 -31
- data/spec/integration/preview/proxy/service/session_spec.rb +21 -21
- data/spec/integration/preview/proxy/service/short_code_spec.rb +19 -19
- data/spec/integration/preview/proxy/service_spec.rb +9 -9
- data/spec/integration/preview/studio/flow/engagement/step_spec.rb +12 -12
- data/spec/integration/preview/studio/flow/engagement_spec.rb +11 -11
- data/spec/integration/preview/studio/flow_spec.rb +6 -6
- data/spec/integration/preview/sync/service/document/document_permission_spec.rb +22 -22
- data/spec/integration/preview/sync/service/document_spec.rb +23 -23
- data/spec/integration/preview/sync/service/sync_list/sync_list_item_spec.rb +33 -33
- data/spec/integration/preview/sync/service/sync_list/sync_list_permission_spec.rb +22 -22
- data/spec/integration/preview/sync/service/sync_list_spec.rb +17 -17
- data/spec/integration/preview/sync/service/sync_map/sync_map_item_spec.rb +33 -33
- data/spec/integration/preview/sync/service/sync_map/sync_map_permission_spec.rb +22 -22
- data/spec/integration/preview/sync/service/sync_map_spec.rb +17 -17
- data/spec/integration/preview/sync/service_spec.rb +9 -9
- data/spec/integration/preview/understand/assistant/field_type/field_value_spec.rb +208 -0
- data/spec/integration/preview/understand/{service → assistant}/field_type_spec.rb +38 -38
- data/spec/integration/preview/understand/{service → assistant}/intent/field_spec.rb +36 -36
- data/spec/integration/preview/understand/assistant/intent/sample_spec.rb +251 -0
- data/spec/integration/preview/understand/{service → assistant}/intent_spec.rb +42 -46
- data/spec/integration/preview/understand/{service → assistant}/model_build_spec.rb +34 -34
- data/spec/integration/preview/understand/{service → assistant}/query_spec.rb +42 -38
- data/spec/integration/preview/understand/{service_spec.rb → assistant_spec.rb} +57 -49
- data/spec/integration/preview/wireless/command_spec.rb +3 -3
- data/spec/integration/preview/wireless/rate_plan_spec.rb +9 -9
- data/spec/integration/preview/wireless/sim/usage_spec.rb +3 -3
- data/spec/integration/preview/wireless/sim_spec.rb +6 -6
- data/spec/integration/proxy/v1/service/phone_number_spec.rb +16 -16
- data/spec/integration/proxy/v1/service/session/interaction_spec.rb +19 -19
- data/spec/integration/proxy/v1/service/session/participant/message_interaction_spec.rb +23 -23
- data/spec/integration/proxy/v1/service/session/participant_spec.rb +31 -31
- data/spec/integration/proxy/v1/service/session_spec.rb +21 -21
- data/spec/integration/proxy/v1/service/short_code_spec.rb +19 -19
- data/spec/integration/proxy/v1/service_spec.rb +9 -9
- data/spec/integration/studio/v1/flow/engagement/engagement_context_spec.rb +5 -5
- data/spec/integration/studio/v1/flow/engagement/step/step_context_spec.rb +7 -7
- data/spec/integration/studio/v1/flow/engagement/step_spec.rb +12 -12
- data/spec/integration/studio/v1/flow/engagement_spec.rb +11 -11
- data/spec/integration/studio/v1/flow_spec.rb +6 -6
- data/spec/integration/sync/v1/service/document/document_permission_spec.rb +22 -22
- data/spec/integration/sync/v1/service/document_spec.rb +22 -22
- data/spec/integration/sync/v1/service/sync_list/sync_list_item_spec.rb +30 -30
- data/spec/integration/sync/v1/service/sync_list/sync_list_permission_spec.rb +22 -22
- data/spec/integration/sync/v1/service/sync_list_spec.rb +22 -22
- data/spec/integration/sync/v1/service/sync_map/sync_map_item_spec.rb +30 -30
- data/spec/integration/sync/v1/service/sync_map/sync_map_permission_spec.rb +22 -22
- data/spec/integration/sync/v1/service/sync_map_spec.rb +22 -22
- data/spec/integration/sync/v1/service/sync_stream/stream_message_spec.rb +8 -8
- data/spec/integration/sync/v1/service/sync_stream_spec.rb +22 -22
- data/spec/integration/sync/v1/service_spec.rb +9 -9
- data/spec/integration/taskrouter/v1/workspace/activity_spec.rb +22 -22
- data/spec/integration/taskrouter/v1/workspace/event_spec.rb +9 -9
- data/spec/integration/taskrouter/v1/workspace/task/reservation_spec.rb +21 -21
- data/spec/integration/taskrouter/v1/workspace/task_channel_spec.rb +9 -9
- data/spec/integration/taskrouter/v1/workspace/task_queue/task_queue_cumulative_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/task_queue/task_queue_real_time_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/task_queue/task_queue_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/task_queue/task_queues_statistics_spec.rb +4 -4
- data/spec/integration/taskrouter/v1/workspace/task_queue_spec.rb +26 -26
- data/spec/integration/taskrouter/v1/workspace/task_spec.rb +23 -23
- data/spec/integration/taskrouter/v1/workspace/worker/reservation_spec.rb +21 -21
- data/spec/integration/taskrouter/v1/workspace/worker/worker_channel_spec.rb +21 -21
- data/spec/integration/taskrouter/v1/workspace/worker/worker_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/worker/workers_cumulative_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/worker/workers_real_time_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/worker/workers_statistics_spec.rb +3 -3
- data/spec/integration/taskrouter/v1/workspace/worker_spec.rb +22 -22
- data/spec/integration/taskrouter/v1/workspace/workflow/workflow_cumulative_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/workflow/workflow_real_time_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/workflow/workflow_statistics_spec.rb +5 -5
- data/spec/integration/taskrouter/v1/workspace/workflow_spec.rb +22 -22
- data/spec/integration/taskrouter/v1/workspace/workspace_cumulative_statistics_spec.rb +3 -3
- data/spec/integration/taskrouter/v1/workspace/workspace_real_time_statistics_spec.rb +3 -3
- data/spec/integration/taskrouter/v1/workspace/workspace_statistics_spec.rb +3 -3
- data/spec/integration/taskrouter/v1/workspace_spec.rb +9 -9
- data/spec/integration/trunking/v1/trunk/credential_list_spec.rb +20 -20
- data/spec/integration/trunking/v1/trunk/ip_access_control_list_spec.rb +20 -20
- data/spec/integration/trunking/v1/trunk/origination_url_spec.rb +22 -22
- data/spec/integration/trunking/v1/trunk/phone_number_spec.rb +20 -20
- data/spec/integration/trunking/v1/trunk_spec.rb +9 -9
- data/spec/integration/video/v1/composition_spec.rb +6 -6
- data/spec/integration/video/v1/recording_spec.rb +10 -6
- data/spec/integration/video/v1/room/recording_spec.rb +9 -9
- data/spec/integration/video/v1/room/room_participant/room_participant_published_track_spec.rb +12 -12
- data/spec/integration/video/v1/room/room_participant/room_participant_subscribed_track_spec.rb +12 -12
- data/spec/integration/video/v1/room/room_participant_spec.rb +14 -14
- data/spec/integration/video/v1/room_spec.rb +6 -6
- data/spec/integration/wireless/v1/command_spec.rb +3 -3
- data/spec/integration/wireless/v1/rate_plan_spec.rb +9 -9
- data/spec/integration/wireless/v1/sim/data_session_spec.rb +3 -3
- data/spec/integration/wireless/v1/sim/usage_record_spec.rb +3 -3
- data/spec/integration/wireless/v1/sim_spec.rb +6 -6
- data/spec/jwt/access_token_spec.rb +2 -0
- metadata +26 -26
- data/spec/integration/preview/understand/service/field_type/field_value_spec.rb +0 -205
- data/spec/integration/preview/understand/service/intent/sample_spec.rb +0 -247
@@ -6,19 +6,19 @@
|
|
6
6
|
|
7
7
|
require 'spec_helper.rb'
|
8
8
|
|
9
|
-
describe '
|
9
|
+
describe 'Assistant' do
|
10
10
|
it "can fetch" do
|
11
11
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
12
12
|
|
13
13
|
expect {
|
14
|
-
@client.preview.understand.
|
14
|
+
@client.preview.understand.assistants('UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
15
15
|
}.to raise_exception(Twilio::REST::TwilioError)
|
16
16
|
|
17
17
|
values = {}
|
18
18
|
expect(
|
19
19
|
@holodeck.has_request?(Holodeck::Request.new(
|
20
20
|
method: 'get',
|
21
|
-
url: 'https://preview.twilio.com/understand/
|
21
|
+
url: 'https://preview.twilio.com/understand/Assistants/UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
22
22
|
))).to eq(true)
|
23
23
|
end
|
24
24
|
|
@@ -37,18 +37,20 @@ describe 'Service' do
|
|
37
37
|
"ttl": 3600,
|
38
38
|
"unique_name": "so-so-unique",
|
39
39
|
"links": {
|
40
|
-
"
|
41
|
-
"
|
42
|
-
"
|
43
|
-
"
|
44
|
-
"queries": "https://preview.twilio.com/understand/Services/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
40
|
+
"field_types": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/FieldTypes",
|
41
|
+
"intents": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Intents",
|
42
|
+
"model_builds": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/ModelBuilds",
|
43
|
+
"queries": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
45
44
|
},
|
46
|
-
"url": "https://preview.twilio.com/understand/
|
45
|
+
"url": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
46
|
+
"response_url": "https://example.com/response_url",
|
47
|
+
"callback_url": "https://example.com/callback_url",
|
48
|
+
"callback_events": "model_build_completed model_build_failed"
|
47
49
|
}
|
48
50
|
]
|
49
51
|
))
|
50
52
|
|
51
|
-
actual = @client.preview.understand.
|
53
|
+
actual = @client.preview.understand.assistants('UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
52
54
|
|
53
55
|
expect(actual).to_not eq(nil)
|
54
56
|
end
|
@@ -57,14 +59,14 @@ describe 'Service' do
|
|
57
59
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
58
60
|
|
59
61
|
expect {
|
60
|
-
@client.preview.understand.
|
62
|
+
@client.preview.understand.assistants.list()
|
61
63
|
}.to raise_exception(Twilio::REST::TwilioError)
|
62
64
|
|
63
65
|
values = {}
|
64
66
|
expect(
|
65
67
|
@holodeck.has_request?(Holodeck::Request.new(
|
66
68
|
method: 'get',
|
67
|
-
url: 'https://preview.twilio.com/understand/
|
69
|
+
url: 'https://preview.twilio.com/understand/Assistants',
|
68
70
|
))).to eq(true)
|
69
71
|
end
|
70
72
|
|
@@ -73,21 +75,21 @@ describe 'Service' do
|
|
73
75
|
200,
|
74
76
|
%q[
|
75
77
|
{
|
76
|
-
"
|
78
|
+
"assistants": [],
|
77
79
|
"meta": {
|
78
|
-
"first_page_url": "https://preview.twilio.com/understand/
|
79
|
-
"key": "
|
80
|
+
"first_page_url": "https://preview.twilio.com/understand/Assistants?PageSize=50&Page=0",
|
81
|
+
"key": "assistants",
|
80
82
|
"next_page_url": null,
|
81
83
|
"page": 0,
|
82
84
|
"page_size": 50,
|
83
85
|
"previous_page_url": null,
|
84
|
-
"url": "https://preview.twilio.com/understand/
|
86
|
+
"url": "https://preview.twilio.com/understand/Assistants?PageSize=50&Page=0"
|
85
87
|
}
|
86
88
|
}
|
87
89
|
]
|
88
90
|
))
|
89
91
|
|
90
|
-
actual = @client.preview.understand.
|
92
|
+
actual = @client.preview.understand.assistants.list()
|
91
93
|
|
92
94
|
expect(actual).to_not eq(nil)
|
93
95
|
end
|
@@ -97,7 +99,7 @@ describe 'Service' do
|
|
97
99
|
200,
|
98
100
|
%q[
|
99
101
|
{
|
100
|
-
"
|
102
|
+
"assistants": [
|
101
103
|
{
|
102
104
|
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
103
105
|
"date_created": "2017-07-04T08:34:00Z",
|
@@ -109,29 +111,31 @@ describe 'Service' do
|
|
109
111
|
"ttl": 3600,
|
110
112
|
"unique_name": "so-so-unique",
|
111
113
|
"links": {
|
112
|
-
"
|
113
|
-
"
|
114
|
-
"
|
115
|
-
"
|
116
|
-
"queries": "https://preview.twilio.com/understand/Services/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
114
|
+
"field_types": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/FieldTypes",
|
115
|
+
"intents": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Intents",
|
116
|
+
"model_builds": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/ModelBuilds",
|
117
|
+
"queries": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
117
118
|
},
|
118
|
-
"url": "https://preview.twilio.com/understand/
|
119
|
+
"url": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
120
|
+
"response_url": "https://example.com/response_url",
|
121
|
+
"callback_url": "https://example.com/callback_url",
|
122
|
+
"callback_events": "model_build_completed model_build_failed"
|
119
123
|
}
|
120
124
|
],
|
121
125
|
"meta": {
|
122
|
-
"first_page_url": "https://preview.twilio.com/understand/
|
123
|
-
"key": "
|
126
|
+
"first_page_url": "https://preview.twilio.com/understand/Assistants?PageSize=50&Page=0",
|
127
|
+
"key": "assistants",
|
124
128
|
"next_page_url": null,
|
125
129
|
"page": 0,
|
126
130
|
"page_size": 50,
|
127
131
|
"previous_page_url": null,
|
128
|
-
"url": "https://preview.twilio.com/understand/
|
132
|
+
"url": "https://preview.twilio.com/understand/Assistants?PageSize=50&Page=0"
|
129
133
|
}
|
130
134
|
}
|
131
135
|
]
|
132
136
|
))
|
133
137
|
|
134
|
-
actual = @client.preview.understand.
|
138
|
+
actual = @client.preview.understand.assistants.list()
|
135
139
|
|
136
140
|
expect(actual).to_not eq(nil)
|
137
141
|
end
|
@@ -140,14 +144,14 @@ describe 'Service' do
|
|
140
144
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
141
145
|
|
142
146
|
expect {
|
143
|
-
@client.preview.understand.
|
147
|
+
@client.preview.understand.assistants.create()
|
144
148
|
}.to raise_exception(Twilio::REST::TwilioError)
|
145
149
|
|
146
150
|
values = {}
|
147
151
|
expect(
|
148
152
|
@holodeck.has_request?(Holodeck::Request.new(
|
149
153
|
method: 'post',
|
150
|
-
url: 'https://preview.twilio.com/understand/
|
154
|
+
url: 'https://preview.twilio.com/understand/Assistants',
|
151
155
|
))).to eq(true)
|
152
156
|
end
|
153
157
|
|
@@ -166,18 +170,20 @@ describe 'Service' do
|
|
166
170
|
"ttl": 3600,
|
167
171
|
"unique_name": "so-so-unique",
|
168
172
|
"links": {
|
169
|
-
"
|
170
|
-
"
|
171
|
-
"
|
172
|
-
"
|
173
|
-
"queries": "https://preview.twilio.com/understand/Services/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
173
|
+
"field_types": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/FieldTypes",
|
174
|
+
"intents": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Intents",
|
175
|
+
"model_builds": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/ModelBuilds",
|
176
|
+
"queries": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
174
177
|
},
|
175
|
-
"url": "https://preview.twilio.com/understand/
|
178
|
+
"url": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
179
|
+
"response_url": "https://example.com/response_url",
|
180
|
+
"callback_url": "https://example.com/callback_url",
|
181
|
+
"callback_events": "model_build_completed model_build_failed"
|
176
182
|
}
|
177
183
|
]
|
178
184
|
))
|
179
185
|
|
180
|
-
actual = @client.preview.understand.
|
186
|
+
actual = @client.preview.understand.assistants.create()
|
181
187
|
|
182
188
|
expect(actual).to_not eq(nil)
|
183
189
|
end
|
@@ -186,14 +192,14 @@ describe 'Service' do
|
|
186
192
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
187
193
|
|
188
194
|
expect {
|
189
|
-
@client.preview.understand.
|
195
|
+
@client.preview.understand.assistants('UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
190
196
|
}.to raise_exception(Twilio::REST::TwilioError)
|
191
197
|
|
192
198
|
values = {}
|
193
199
|
expect(
|
194
200
|
@holodeck.has_request?(Holodeck::Request.new(
|
195
201
|
method: 'post',
|
196
|
-
url: 'https://preview.twilio.com/understand/
|
202
|
+
url: 'https://preview.twilio.com/understand/Assistants/UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
197
203
|
))).to eq(true)
|
198
204
|
end
|
199
205
|
|
@@ -212,18 +218,20 @@ describe 'Service' do
|
|
212
218
|
"ttl": 3600,
|
213
219
|
"unique_name": "so-so-unique",
|
214
220
|
"links": {
|
215
|
-
"
|
216
|
-
"
|
217
|
-
"
|
218
|
-
"
|
219
|
-
"queries": "https://preview.twilio.com/understand/Services/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
221
|
+
"field_types": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/FieldTypes",
|
222
|
+
"intents": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Intents",
|
223
|
+
"model_builds": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/ModelBuilds",
|
224
|
+
"queries": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Queries"
|
220
225
|
},
|
221
|
-
"url": "https://preview.twilio.com/understand/
|
226
|
+
"url": "https://preview.twilio.com/understand/Assistants/UAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
227
|
+
"response_url": "https://example.com/response_url",
|
228
|
+
"callback_url": "https://example.com/callback_url",
|
229
|
+
"callback_events": "model_build_completed model_build_failed"
|
222
230
|
}
|
223
231
|
]
|
224
232
|
))
|
225
233
|
|
226
|
-
actual = @client.preview.understand.
|
234
|
+
actual = @client.preview.understand.assistants('UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
227
235
|
|
228
236
|
expect(actual).to_not eq(nil)
|
229
237
|
end
|
@@ -232,14 +240,14 @@ describe 'Service' do
|
|
232
240
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
233
241
|
|
234
242
|
expect {
|
235
|
-
@client.preview.understand.
|
243
|
+
@client.preview.understand.assistants('UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
|
236
244
|
}.to raise_exception(Twilio::REST::TwilioError)
|
237
245
|
|
238
246
|
values = {}
|
239
247
|
expect(
|
240
248
|
@holodeck.has_request?(Holodeck::Request.new(
|
241
249
|
method: 'delete',
|
242
|
-
url: 'https://preview.twilio.com/understand/
|
250
|
+
url: 'https://preview.twilio.com/understand/Assistants/UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
243
251
|
))).to eq(true)
|
244
252
|
end
|
245
253
|
|
@@ -249,7 +257,7 @@ describe 'Service' do
|
|
249
257
|
nil,
|
250
258
|
))
|
251
259
|
|
252
|
-
actual = @client.preview.understand.
|
260
|
+
actual = @client.preview.understand.assistants('UAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
|
253
261
|
|
254
262
|
expect(actual).to eq(true)
|
255
263
|
end
|
@@ -11,14 +11,14 @@ describe 'Command' do
|
|
11
11
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
12
12
|
|
13
13
|
expect {
|
14
|
-
@client.preview.wireless.commands('
|
14
|
+
@client.preview.wireless.commands('DCXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
15
15
|
}.to raise_exception(Twilio::REST::TwilioError)
|
16
16
|
|
17
17
|
values = {}
|
18
18
|
expect(
|
19
19
|
@holodeck.has_request?(Holodeck::Request.new(
|
20
20
|
method: 'get',
|
21
|
-
url: 'https://preview.twilio.com/wireless/Commands/
|
21
|
+
url: 'https://preview.twilio.com/wireless/Commands/DCXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
22
22
|
))).to eq(true)
|
23
23
|
end
|
24
24
|
|
@@ -42,7 +42,7 @@ describe 'Command' do
|
|
42
42
|
]
|
43
43
|
))
|
44
44
|
|
45
|
-
actual = @client.preview.wireless.commands('
|
45
|
+
actual = @client.preview.wireless.commands('DCXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
46
46
|
|
47
47
|
expect(actual).to_not eq(nil)
|
48
48
|
end
|
@@ -95,14 +95,14 @@ describe 'RatePlan' do
|
|
95
95
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
96
96
|
|
97
97
|
expect {
|
98
|
-
@client.preview.wireless.rate_plans('
|
98
|
+
@client.preview.wireless.rate_plans('WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
99
99
|
}.to raise_exception(Twilio::REST::TwilioError)
|
100
100
|
|
101
101
|
values = {}
|
102
102
|
expect(
|
103
103
|
@holodeck.has_request?(Holodeck::Request.new(
|
104
104
|
method: 'get',
|
105
|
-
url: 'https://preview.twilio.com/wireless/RatePlans/
|
105
|
+
url: 'https://preview.twilio.com/wireless/RatePlans/WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
106
106
|
))).to eq(true)
|
107
107
|
end
|
108
108
|
|
@@ -133,7 +133,7 @@ describe 'RatePlan' do
|
|
133
133
|
]
|
134
134
|
))
|
135
135
|
|
136
|
-
actual = @client.preview.wireless.rate_plans('
|
136
|
+
actual = @client.preview.wireless.rate_plans('WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
137
137
|
|
138
138
|
expect(actual).to_not eq(nil)
|
139
139
|
end
|
@@ -189,14 +189,14 @@ describe 'RatePlan' do
|
|
189
189
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
190
190
|
|
191
191
|
expect {
|
192
|
-
@client.preview.wireless.rate_plans('
|
192
|
+
@client.preview.wireless.rate_plans('WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
193
193
|
}.to raise_exception(Twilio::REST::TwilioError)
|
194
194
|
|
195
195
|
values = {}
|
196
196
|
expect(
|
197
197
|
@holodeck.has_request?(Holodeck::Request.new(
|
198
198
|
method: 'post',
|
199
|
-
url: 'https://preview.twilio.com/wireless/RatePlans/
|
199
|
+
url: 'https://preview.twilio.com/wireless/RatePlans/WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
200
200
|
))).to eq(true)
|
201
201
|
end
|
202
202
|
|
@@ -227,7 +227,7 @@ describe 'RatePlan' do
|
|
227
227
|
]
|
228
228
|
))
|
229
229
|
|
230
|
-
actual = @client.preview.wireless.rate_plans('
|
230
|
+
actual = @client.preview.wireless.rate_plans('WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
231
231
|
|
232
232
|
expect(actual).to_not eq(nil)
|
233
233
|
end
|
@@ -236,14 +236,14 @@ describe 'RatePlan' do
|
|
236
236
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
237
237
|
|
238
238
|
expect {
|
239
|
-
@client.preview.wireless.rate_plans('
|
239
|
+
@client.preview.wireless.rate_plans('WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
|
240
240
|
}.to raise_exception(Twilio::REST::TwilioError)
|
241
241
|
|
242
242
|
values = {}
|
243
243
|
expect(
|
244
244
|
@holodeck.has_request?(Holodeck::Request.new(
|
245
245
|
method: 'delete',
|
246
|
-
url: 'https://preview.twilio.com/wireless/RatePlans/
|
246
|
+
url: 'https://preview.twilio.com/wireless/RatePlans/WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
247
247
|
))).to eq(true)
|
248
248
|
end
|
249
249
|
|
@@ -253,7 +253,7 @@ describe 'RatePlan' do
|
|
253
253
|
nil,
|
254
254
|
))
|
255
255
|
|
256
|
-
actual = @client.preview.wireless.rate_plans('
|
256
|
+
actual = @client.preview.wireless.rate_plans('WPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
|
257
257
|
|
258
258
|
expect(actual).to eq(true)
|
259
259
|
end
|
@@ -11,7 +11,7 @@ describe 'Usage' do
|
|
11
11
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
12
12
|
|
13
13
|
expect {
|
14
|
-
@client.preview.wireless.sims('
|
14
|
+
@client.preview.wireless.sims('DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
15
15
|
.usage().fetch()
|
16
16
|
}.to raise_exception(Twilio::REST::TwilioError)
|
17
17
|
|
@@ -19,7 +19,7 @@ describe 'Usage' do
|
|
19
19
|
expect(
|
20
20
|
@holodeck.has_request?(Holodeck::Request.new(
|
21
21
|
method: 'get',
|
22
|
-
url: 'https://preview.twilio.com/wireless/Sims/
|
22
|
+
url: 'https://preview.twilio.com/wireless/Sims/DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Usage',
|
23
23
|
))).to eq(true)
|
24
24
|
end
|
25
25
|
|
@@ -41,7 +41,7 @@ describe 'Usage' do
|
|
41
41
|
]
|
42
42
|
))
|
43
43
|
|
44
|
-
actual = @client.preview.wireless.sims('
|
44
|
+
actual = @client.preview.wireless.sims('DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
45
45
|
.usage().fetch()
|
46
46
|
|
47
47
|
expect(actual).to_not eq(nil)
|
@@ -11,14 +11,14 @@ describe 'Sim' do
|
|
11
11
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
12
12
|
|
13
13
|
expect {
|
14
|
-
@client.preview.wireless.sims('
|
14
|
+
@client.preview.wireless.sims('DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
15
15
|
}.to raise_exception(Twilio::REST::TwilioError)
|
16
16
|
|
17
17
|
values = {}
|
18
18
|
expect(
|
19
19
|
@holodeck.has_request?(Holodeck::Request.new(
|
20
20
|
method: 'get',
|
21
|
-
url: 'https://preview.twilio.com/wireless/Sims/
|
21
|
+
url: 'https://preview.twilio.com/wireless/Sims/DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
22
22
|
))).to eq(true)
|
23
23
|
end
|
24
24
|
|
@@ -56,7 +56,7 @@ describe 'Sim' do
|
|
56
56
|
]
|
57
57
|
))
|
58
58
|
|
59
|
-
actual = @client.preview.wireless.sims('
|
59
|
+
actual = @client.preview.wireless.sims('DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
60
60
|
|
61
61
|
expect(actual).to_not eq(nil)
|
62
62
|
end
|
@@ -156,14 +156,14 @@ describe 'Sim' do
|
|
156
156
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
157
157
|
|
158
158
|
expect {
|
159
|
-
@client.preview.wireless.sims('
|
159
|
+
@client.preview.wireless.sims('DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
160
160
|
}.to raise_exception(Twilio::REST::TwilioError)
|
161
161
|
|
162
162
|
values = {}
|
163
163
|
expect(
|
164
164
|
@holodeck.has_request?(Holodeck::Request.new(
|
165
165
|
method: 'post',
|
166
|
-
url: 'https://preview.twilio.com/wireless/Sims/
|
166
|
+
url: 'https://preview.twilio.com/wireless/Sims/DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
167
167
|
))).to eq(true)
|
168
168
|
end
|
169
169
|
|
@@ -201,7 +201,7 @@ describe 'Sim' do
|
|
201
201
|
]
|
202
202
|
))
|
203
203
|
|
204
|
-
actual = @client.preview.wireless.sims('
|
204
|
+
actual = @client.preview.wireless.sims('DEXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
205
205
|
|
206
206
|
expect(actual).to_not eq(nil)
|
207
207
|
end
|
@@ -11,7 +11,7 @@ describe 'PhoneNumber' do
|
|
11
11
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
12
12
|
|
13
13
|
expect {
|
14
|
-
@client.proxy.v1.services('
|
14
|
+
@client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
15
15
|
.phone_numbers.create()
|
16
16
|
}.to raise_exception(Twilio::REST::TwilioError)
|
17
17
|
|
@@ -19,7 +19,7 @@ describe 'PhoneNumber' do
|
|
19
19
|
expect(
|
20
20
|
@holodeck.has_request?(Holodeck::Request.new(
|
21
21
|
method: 'post',
|
22
|
-
url: 'https://proxy.twilio.com/v1/Services/
|
22
|
+
url: 'https://proxy.twilio.com/v1/Services/KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers',
|
23
23
|
))).to eq(true)
|
24
24
|
end
|
25
25
|
|
@@ -45,7 +45,7 @@ describe 'PhoneNumber' do
|
|
45
45
|
]
|
46
46
|
))
|
47
47
|
|
48
|
-
actual = @client.proxy.v1.services('
|
48
|
+
actual = @client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
49
49
|
.phone_numbers.create()
|
50
50
|
|
51
51
|
expect(actual).to_not eq(nil)
|
@@ -55,15 +55,15 @@ describe 'PhoneNumber' do
|
|
55
55
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
56
56
|
|
57
57
|
expect {
|
58
|
-
@client.proxy.v1.services('
|
59
|
-
.phone_numbers('
|
58
|
+
@client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
59
|
+
.phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
|
60
60
|
}.to raise_exception(Twilio::REST::TwilioError)
|
61
61
|
|
62
62
|
values = {}
|
63
63
|
expect(
|
64
64
|
@holodeck.has_request?(Holodeck::Request.new(
|
65
65
|
method: 'delete',
|
66
|
-
url: 'https://proxy.twilio.com/v1/Services/
|
66
|
+
url: 'https://proxy.twilio.com/v1/Services/KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
67
67
|
))).to eq(true)
|
68
68
|
end
|
69
69
|
|
@@ -73,8 +73,8 @@ describe 'PhoneNumber' do
|
|
73
73
|
nil,
|
74
74
|
))
|
75
75
|
|
76
|
-
actual = @client.proxy.v1.services('
|
77
|
-
.phone_numbers('
|
76
|
+
actual = @client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
77
|
+
.phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
|
78
78
|
|
79
79
|
expect(actual).to eq(true)
|
80
80
|
end
|
@@ -83,7 +83,7 @@ describe 'PhoneNumber' do
|
|
83
83
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
84
84
|
|
85
85
|
expect {
|
86
|
-
@client.proxy.v1.services('
|
86
|
+
@client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
87
87
|
.phone_numbers.list()
|
88
88
|
}.to raise_exception(Twilio::REST::TwilioError)
|
89
89
|
|
@@ -91,7 +91,7 @@ describe 'PhoneNumber' do
|
|
91
91
|
expect(
|
92
92
|
@holodeck.has_request?(Holodeck::Request.new(
|
93
93
|
method: 'get',
|
94
|
-
url: 'https://proxy.twilio.com/v1/Services/
|
94
|
+
url: 'https://proxy.twilio.com/v1/Services/KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers',
|
95
95
|
))).to eq(true)
|
96
96
|
end
|
97
97
|
|
@@ -130,7 +130,7 @@ describe 'PhoneNumber' do
|
|
130
130
|
]
|
131
131
|
))
|
132
132
|
|
133
|
-
actual = @client.proxy.v1.services('
|
133
|
+
actual = @client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
134
134
|
.phone_numbers.list()
|
135
135
|
|
136
136
|
expect(actual).to_not eq(nil)
|
@@ -140,15 +140,15 @@ describe 'PhoneNumber' do
|
|
140
140
|
@holodeck.mock(Twilio::Response.new(500, ''))
|
141
141
|
|
142
142
|
expect {
|
143
|
-
@client.proxy.v1.services('
|
144
|
-
.phone_numbers('
|
143
|
+
@client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
144
|
+
.phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
145
145
|
}.to raise_exception(Twilio::REST::TwilioError)
|
146
146
|
|
147
147
|
values = {}
|
148
148
|
expect(
|
149
149
|
@holodeck.has_request?(Holodeck::Request.new(
|
150
150
|
method: 'get',
|
151
|
-
url: 'https://proxy.twilio.com/v1/Services/
|
151
|
+
url: 'https://proxy.twilio.com/v1/Services/KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
152
152
|
))).to eq(true)
|
153
153
|
end
|
154
154
|
|
@@ -174,8 +174,8 @@ describe 'PhoneNumber' do
|
|
174
174
|
]
|
175
175
|
))
|
176
176
|
|
177
|
-
actual = @client.proxy.v1.services('
|
178
|
-
.phone_numbers('
|
177
|
+
actual = @client.proxy.v1.services('KSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
|
178
|
+
.phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
179
179
|
|
180
180
|
expect(actual).to_not eq(nil)
|
181
181
|
end
|