twilio-ruby 5.34.0 → 5.38.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (113) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGES.md +126 -0
  3. data/README.md +24 -3
  4. data/lib/twilio-ruby.rb +1 -1
  5. data/lib/twilio-ruby/rest/api/v2010/account/call.rb +87 -87
  6. data/lib/twilio-ruby/rest/api/v2010/account/conference.rb +14 -0
  7. data/lib/twilio-ruby/rest/api/v2010/account/conference/participant.rb +47 -9
  8. data/lib/twilio-ruby/rest/api/v2010/account/message.rb +71 -71
  9. data/lib/twilio-ruby/rest/api/v2010/account/queue.rb +29 -29
  10. data/lib/twilio-ruby/rest/api/v2010/account/sip/domain.rb +38 -3
  11. data/lib/twilio-ruby/rest/api/v2010/account/validation_request.rb +12 -12
  12. data/lib/twilio-ruby/rest/autopilot.rb +6 -0
  13. data/lib/twilio-ruby/rest/autopilot/v1.rb +7 -0
  14. data/lib/twilio-ruby/rest/autopilot/v1/assistant.rb +0 -16
  15. data/lib/twilio-ruby/rest/autopilot/v1/assistant/query.rb +12 -3
  16. data/lib/twilio-ruby/rest/autopilot/v1/restore_assistant.rb +198 -0
  17. data/lib/twilio-ruby/rest/client.rb +35 -15
  18. data/lib/twilio-ruby/rest/conversations/v1/conversation.rb +28 -3
  19. data/lib/twilio-ruby/rest/conversations/v1/conversation/participant.rb +27 -4
  20. data/lib/twilio-ruby/rest/flex_api/v1/channel.rb +2 -1
  21. data/lib/twilio-ruby/rest/flex_api/v1/configuration.rb +7 -0
  22. data/lib/twilio-ruby/rest/flex_api/v1/flex_flow.rb +6 -3
  23. data/lib/twilio-ruby/rest/monitor/v1/alert.rb +8 -8
  24. data/lib/twilio-ruby/rest/notify/v1/service.rb +20 -1
  25. data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle.rb +26 -0
  26. data/lib/twilio-ruby/rest/numbers/v2/regulatory_compliance/bundle/evaluation.rb +324 -0
  27. data/lib/twilio-ruby/rest/preview.rb +6 -0
  28. data/lib/twilio-ruby/rest/preview/trusted_comms.rb +7 -0
  29. data/lib/twilio-ruby/rest/preview/trusted_comms/brands_information.rb +193 -0
  30. data/lib/twilio-ruby/rest/preview/trusted_comms/business.rb +26 -0
  31. data/lib/twilio-ruby/rest/{autopilot/v1/assistant/export_assistant.rb → preview/trusted_comms/business/brand.rb} +88 -71
  32. data/lib/twilio-ruby/rest/preview/trusted_comms/business/brand/branded_channel.rb +266 -0
  33. data/lib/twilio-ruby/rest/preview/trusted_comms/business/brand/branded_channel/channel.rb +194 -0
  34. data/lib/twilio-ruby/rest/serverless/v1/service/environment/log.rb +7 -0
  35. data/lib/twilio-ruby/rest/supersim.rb +18 -0
  36. data/lib/twilio-ruby/rest/supersim/v1.rb +30 -0
  37. data/lib/twilio-ruby/rest/supersim/v1/fleet.rb +63 -16
  38. data/lib/twilio-ruby/rest/supersim/v1/network.rb +315 -0
  39. data/lib/twilio-ruby/rest/{authy/v1/service.rb → supersim/v1/network_access_profile.rb} +95 -121
  40. data/lib/twilio-ruby/rest/supersim/v1/network_access_profile/network_access_profile_network.rb +352 -0
  41. data/lib/twilio-ruby/rest/verify.rb +9 -0
  42. data/lib/twilio-ruby/rest/verify/v2.rb +16 -0
  43. data/lib/twilio-ruby/rest/{authy/v1 → verify/v2}/form.rb +8 -8
  44. data/lib/twilio-ruby/rest/verify/v2/service.rb +74 -3
  45. data/lib/twilio-ruby/rest/{authy/v1 → verify/v2}/service/entity.rb +32 -8
  46. data/lib/twilio-ruby/rest/verify/v2/service/entity/access_token.rb +141 -0
  47. data/lib/twilio-ruby/rest/{authy/v1 → verify/v2}/service/entity/factor.rb +8 -8
  48. data/lib/twilio-ruby/rest/{authy/v1 → verify/v2}/service/entity/factor/challenge.rb +8 -8
  49. data/lib/twilio-ruby/rest/verify/v2/service/verification.rb +3 -3
  50. data/lib/twilio-ruby/rest/verify/v2/service/webhook.rb +425 -0
  51. data/lib/twilio-ruby/rest/video/v1/composition_settings.rb +8 -4
  52. data/lib/twilio-ruby/rest/video/v1/recording_settings.rb +8 -4
  53. data/lib/twilio-ruby/rest/voice.rb +36 -0
  54. data/lib/twilio-ruby/rest/voice/v1.rb +64 -0
  55. data/lib/twilio-ruby/rest/voice/v1/byoc_trunk.rb +513 -0
  56. data/lib/twilio-ruby/rest/voice/v1/connection_policy.rb +379 -0
  57. data/lib/twilio-ruby/rest/voice/v1/connection_policy/connection_policy_target.rb +458 -0
  58. data/lib/twilio-ruby/rest/voice/v1/ip_record.rb +366 -0
  59. data/lib/twilio-ruby/rest/voice/v1/source_ip_mapping.rb +346 -0
  60. data/lib/twilio-ruby/util/configuration.rb +9 -1
  61. data/lib/twilio-ruby/version.rb +1 -1
  62. data/spec/integration/api/v2010/account/call_spec.rb +5 -5
  63. data/spec/integration/api/v2010/account/conference/participant_spec.rb +177 -0
  64. data/spec/integration/api/v2010/account/conference_spec.rb +42 -14
  65. data/spec/integration/api/v2010/account/outgoing_caller_id_spec.rb +8 -14
  66. data/spec/integration/api/v2010/account/sip/domain_spec.rb +12 -4
  67. data/spec/integration/api/v2010/account/token_spec.rb +23 -11
  68. data/spec/integration/api/v2010/account/validation_request_spec.rb +1 -1
  69. data/spec/integration/autopilot/v1/assistant/query_spec.rb +4 -4
  70. data/spec/integration/autopilot/v1/assistant_spec.rb +4 -8
  71. data/spec/integration/autopilot/v1/restore_assistant_spec.rb +53 -0
  72. data/spec/integration/conversations/v1/conversation/participant_spec.rb +7 -0
  73. data/spec/integration/conversations/v1/conversation_spec.rb +16 -0
  74. data/spec/integration/flex_api/v1/configuration_spec.rb +3 -0
  75. data/spec/integration/numbers/v2/regulatory_compliance/bundle/evaluation_spec.rb +623 -0
  76. data/spec/integration/numbers/v2/regulatory_compliance/bundle_spec.rb +4 -0
  77. data/spec/integration/preview/trusted_comms/brands_information_spec.rb +44 -0
  78. data/spec/integration/preview/trusted_comms/business/brand/branded_channel/channel_spec.rb +54 -0
  79. data/spec/integration/preview/trusted_comms/business/brand/branded_channel_spec.rb +52 -0
  80. data/spec/integration/preview/trusted_comms/business/brand_spec.rb +49 -0
  81. data/spec/integration/preview/trusted_comms/business_spec.rb +1 -0
  82. data/spec/integration/serverless/v1/service/environment/log_spec.rb +1 -0
  83. data/spec/integration/supersim/v1/fleet_spec.rb +16 -7
  84. data/spec/integration/supersim/v1/network_access_profile/network_access_profile_network_spec.rb +179 -0
  85. data/spec/integration/supersim/v1/network_access_profile_spec.rb +223 -0
  86. data/spec/integration/supersim/v1/network_spec.rb +139 -0
  87. data/spec/integration/supersim/v1/sim_spec.rb +78 -6
  88. data/spec/integration/trunking/v1/trunk/credential_list_spec.rb +13 -13
  89. data/spec/integration/trunking/v1/trunk/ip_access_control_list_spec.rb +23 -23
  90. data/spec/integration/trunking/v1/trunk/origination_url_spec.rb +28 -28
  91. data/spec/integration/trunking/v1/trunk/phone_number_spec.rb +17 -17
  92. data/spec/integration/trunking/v1/trunk_spec.rb +33 -33
  93. data/spec/integration/{authy/v1 → verify/v2}/form_spec.rb +4 -4
  94. data/spec/integration/verify/v2/service/entity/access_token_spec.rb +46 -0
  95. data/spec/integration/{authy/v1 → verify/v2}/service/entity/factor/challenge_spec.rb +73 -73
  96. data/spec/integration/{authy/v1 → verify/v2}/service/entity/factor_spec.rb +54 -54
  97. data/spec/integration/verify/v2/service/entity_spec.rb +204 -0
  98. data/spec/integration/verify/v2/service/webhook_spec.rb +262 -0
  99. data/spec/integration/verify/v2/service_spec.rb +32 -4
  100. data/spec/integration/voice/v1/byoc_trunk_spec.rb +250 -0
  101. data/spec/integration/voice/v1/connection_policy/connection_policy_target_spec.rb +246 -0
  102. data/spec/integration/voice/v1/connection_policy_spec.rb +226 -0
  103. data/spec/integration/voice/v1/ip_record_spec.rb +223 -0
  104. data/spec/integration/voice/v1/source_ip_mapping_spec.rb +219 -0
  105. data/spec/rest/client_spec.rb +168 -58
  106. data/spec/util/configuration_spec.rb +12 -0
  107. data/twilio-ruby.gemspec +1 -1
  108. metadata +63 -23
  109. data/lib/twilio-ruby/rest/authy.rb +0 -55
  110. data/lib/twilio-ruby/rest/authy/v1.rb +0 -59
  111. data/spec/integration/authy/v1/service/entity_spec.rb +0 -201
  112. data/spec/integration/authy/v1/service_spec.rb +0 -231
  113. data/spec/integration/autopilot/v1/assistant/export_assistant_spec.rb +0 -49
@@ -13,7 +13,7 @@ describe 'PhoneNumber' do
13
13
  @holodeck.mock(Twilio::Response.new(500, ''))
14
14
 
15
15
  expect {
16
- @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
16
+ @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
17
17
  .phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
18
18
  }.to raise_exception(Twilio::REST::TwilioError)
19
19
 
@@ -21,7 +21,7 @@ describe 'PhoneNumber' do
21
21
  expect(
22
22
  @holodeck.has_request?(Holodeck::Request.new(
23
23
  method: 'get',
24
- url: 'https://trunking.twilio.com/v1/Trunks/TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
24
+ url: 'https://trunking.twilio.com/v1/Trunks/TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
25
25
  ))).to eq(true)
26
26
  end
27
27
 
@@ -66,7 +66,7 @@ describe 'PhoneNumber' do
66
66
  ]
67
67
  ))
68
68
 
69
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
69
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
70
70
  .phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
71
71
 
72
72
  expect(actual).to_not eq(nil)
@@ -76,7 +76,7 @@ describe 'PhoneNumber' do
76
76
  @holodeck.mock(Twilio::Response.new(500, ''))
77
77
 
78
78
  expect {
79
- @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
79
+ @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
80
80
  .phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
81
81
  }.to raise_exception(Twilio::REST::TwilioError)
82
82
 
@@ -84,7 +84,7 @@ describe 'PhoneNumber' do
84
84
  expect(
85
85
  @holodeck.has_request?(Holodeck::Request.new(
86
86
  method: 'delete',
87
- url: 'https://trunking.twilio.com/v1/Trunks/TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
87
+ url: 'https://trunking.twilio.com/v1/Trunks/TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
88
88
  ))).to eq(true)
89
89
  end
90
90
 
@@ -94,7 +94,7 @@ describe 'PhoneNumber' do
94
94
  nil,
95
95
  ))
96
96
 
97
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
97
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
98
98
  .phone_numbers('PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
99
99
 
100
100
  expect(actual).to eq(true)
@@ -104,7 +104,7 @@ describe 'PhoneNumber' do
104
104
  @holodeck.mock(Twilio::Response.new(500, ''))
105
105
 
106
106
  expect {
107
- @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
107
+ @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
108
108
  .phone_numbers.create(phone_number_sid: 'PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
109
109
  }.to raise_exception(Twilio::REST::TwilioError)
110
110
 
@@ -112,7 +112,7 @@ describe 'PhoneNumber' do
112
112
  expect(
113
113
  @holodeck.has_request?(Holodeck::Request.new(
114
114
  method: 'post',
115
- url: 'https://trunking.twilio.com/v1/Trunks/TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers',
115
+ url: 'https://trunking.twilio.com/v1/Trunks/TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers',
116
116
  data: values,
117
117
  ))).to eq(true)
118
118
  end
@@ -158,7 +158,7 @@ describe 'PhoneNumber' do
158
158
  ]
159
159
  ))
160
160
 
161
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
161
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
162
162
  .phone_numbers.create(phone_number_sid: 'PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
163
163
 
164
164
  expect(actual).to_not eq(nil)
@@ -168,7 +168,7 @@ describe 'PhoneNumber' do
168
168
  @holodeck.mock(Twilio::Response.new(500, ''))
169
169
 
170
170
  expect {
171
- @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
171
+ @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
172
172
  .phone_numbers.list()
173
173
  }.to raise_exception(Twilio::REST::TwilioError)
174
174
 
@@ -176,7 +176,7 @@ describe 'PhoneNumber' do
176
176
  expect(
177
177
  @holodeck.has_request?(Holodeck::Request.new(
178
178
  method: 'get',
179
- url: 'https://trunking.twilio.com/v1/Trunks/TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers',
179
+ url: 'https://trunking.twilio.com/v1/Trunks/TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/PhoneNumbers',
180
180
  ))).to eq(true)
181
181
  end
182
182
 
@@ -186,13 +186,13 @@ describe 'PhoneNumber' do
186
186
  %q[
187
187
  {
188
188
  "meta": {
189
- "first_page_url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0",
189
+ "first_page_url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0",
190
190
  "key": "phone_numbers",
191
191
  "next_page_url": null,
192
192
  "page": 0,
193
193
  "page_size": 1,
194
194
  "previous_page_url": null,
195
- "url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0"
195
+ "url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0"
196
196
  },
197
197
  "phone_numbers": [
198
198
  {
@@ -234,7 +234,7 @@ describe 'PhoneNumber' do
234
234
  ]
235
235
  ))
236
236
 
237
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
237
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
238
238
  .phone_numbers.list()
239
239
 
240
240
  expect(actual).to_not eq(nil)
@@ -246,20 +246,20 @@ describe 'PhoneNumber' do
246
246
  %q[
247
247
  {
248
248
  "meta": {
249
- "first_page_url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0",
249
+ "first_page_url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0",
250
250
  "key": "phone_numbers",
251
251
  "next_page_url": null,
252
252
  "page": 0,
253
253
  "page_size": 1,
254
254
  "previous_page_url": null,
255
- "url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0"
255
+ "url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers?PageSize=1&Page=0"
256
256
  },
257
257
  "phone_numbers": []
258
258
  }
259
259
  ]
260
260
  ))
261
261
 
262
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
262
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
263
263
  .phone_numbers.list()
264
264
 
265
265
  expect(actual).to_not eq(nil)
@@ -13,14 +13,14 @@ describe 'Trunk' do
13
13
  @holodeck.mock(Twilio::Response.new(500, ''))
14
14
 
15
15
  expect {
16
- @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
16
+ @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
17
17
  }.to raise_exception(Twilio::REST::TwilioError)
18
18
 
19
19
  values = {}
20
20
  expect(
21
21
  @holodeck.has_request?(Holodeck::Request.new(
22
22
  method: 'get',
23
- url: 'https://trunking.twilio.com/v1/Trunks/TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
23
+ url: 'https://trunking.twilio.com/v1/Trunks/TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
24
24
  ))).to eq(true)
25
25
  end
26
26
 
@@ -29,7 +29,7 @@ describe 'Trunk' do
29
29
  200,
30
30
  %q[
31
31
  {
32
- "sid": "TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
32
+ "sid": "TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
33
33
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
34
34
  "domain_name": "test.pstn.twilio.com",
35
35
  "disaster_recovery_method": "POST",
@@ -45,18 +45,18 @@ describe 'Trunk' do
45
45
  "auth_type_set": [],
46
46
  "date_created": "2015-01-02T11:23:45Z",
47
47
  "date_updated": "2015-01-02T11:23:45Z",
48
- "url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
48
+ "url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
49
49
  "links": {
50
- "origination_urls": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
51
- "credential_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
52
- "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
53
- "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
50
+ "origination_urls": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
51
+ "credential_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
52
+ "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
53
+ "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
54
54
  }
55
55
  }
56
56
  ]
57
57
  ))
58
58
 
59
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
59
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
60
60
 
61
61
  expect(actual).to_not eq(nil)
62
62
  end
@@ -65,14 +65,14 @@ describe 'Trunk' do
65
65
  @holodeck.mock(Twilio::Response.new(500, ''))
66
66
 
67
67
  expect {
68
- @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
68
+ @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
69
69
  }.to raise_exception(Twilio::REST::TwilioError)
70
70
 
71
71
  values = {}
72
72
  expect(
73
73
  @holodeck.has_request?(Holodeck::Request.new(
74
74
  method: 'delete',
75
- url: 'https://trunking.twilio.com/v1/Trunks/TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
75
+ url: 'https://trunking.twilio.com/v1/Trunks/TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
76
76
  ))).to eq(true)
77
77
  end
78
78
 
@@ -82,7 +82,7 @@ describe 'Trunk' do
82
82
  nil,
83
83
  ))
84
84
 
85
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
85
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').delete()
86
86
 
87
87
  expect(actual).to eq(true)
88
88
  end
@@ -107,7 +107,7 @@ describe 'Trunk' do
107
107
  201,
108
108
  %q[
109
109
  {
110
- "sid": "TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
110
+ "sid": "TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
111
111
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
112
112
  "domain_name": "test.pstn.twilio.com",
113
113
  "disaster_recovery_method": "POST",
@@ -123,12 +123,12 @@ describe 'Trunk' do
123
123
  "auth_type_set": [],
124
124
  "date_created": "2015-01-02T11:23:45Z",
125
125
  "date_updated": "2015-01-02T11:23:45Z",
126
- "url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
126
+ "url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
127
127
  "links": {
128
- "origination_urls": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
129
- "credential_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
130
- "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
131
- "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
128
+ "origination_urls": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
129
+ "credential_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
130
+ "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
131
+ "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
132
132
  }
133
133
  }
134
134
  ]
@@ -170,7 +170,7 @@ describe 'Trunk' do
170
170
  },
171
171
  "trunks": [
172
172
  {
173
- "sid": "TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
173
+ "sid": "TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
174
174
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
175
175
  "domain_name": "test.pstn.twilio.com",
176
176
  "disaster_recovery_method": "POST",
@@ -186,12 +186,12 @@ describe 'Trunk' do
186
186
  "auth_type_set": [],
187
187
  "date_created": "2015-01-02T11:23:45Z",
188
188
  "date_updated": "2015-01-02T11:23:45Z",
189
- "url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
189
+ "url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
190
190
  "links": {
191
- "origination_urls": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
192
- "credential_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
193
- "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
194
- "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
191
+ "origination_urls": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
192
+ "credential_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
193
+ "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
194
+ "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
195
195
  }
196
196
  }
197
197
  ]
@@ -232,14 +232,14 @@ describe 'Trunk' do
232
232
  @holodeck.mock(Twilio::Response.new(500, ''))
233
233
 
234
234
  expect {
235
- @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
235
+ @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
236
236
  }.to raise_exception(Twilio::REST::TwilioError)
237
237
 
238
238
  values = {}
239
239
  expect(
240
240
  @holodeck.has_request?(Holodeck::Request.new(
241
241
  method: 'post',
242
- url: 'https://trunking.twilio.com/v1/Trunks/TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
242
+ url: 'https://trunking.twilio.com/v1/Trunks/TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
243
243
  ))).to eq(true)
244
244
  end
245
245
 
@@ -248,7 +248,7 @@ describe 'Trunk' do
248
248
  200,
249
249
  %q[
250
250
  {
251
- "sid": "TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
251
+ "sid": "TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
252
252
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
253
253
  "domain_name": "test.pstn.twilio.com",
254
254
  "disaster_recovery_method": "GET",
@@ -264,18 +264,18 @@ describe 'Trunk' do
264
264
  "auth_type_set": [],
265
265
  "date_created": "2015-01-02T11:23:45Z",
266
266
  "date_updated": "2015-01-02T11:23:45Z",
267
- "url": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
267
+ "url": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
268
268
  "links": {
269
- "origination_urls": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
270
- "credential_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
271
- "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
272
- "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TRaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
269
+ "origination_urls": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/OriginationUrls",
270
+ "credential_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialLists",
271
+ "ip_access_control_lists": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/IpAccessControlLists",
272
+ "phone_numbers": "https://trunking.twilio.com/v1/Trunks/TKaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/PhoneNumbers"
273
273
  }
274
274
  }
275
275
  ]
276
276
  ))
277
277
 
278
- actual = @client.trunking.v1.trunks('TRXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
278
+ actual = @client.trunking.v1.trunks('TKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
279
279
 
280
280
  expect(actual).to_not eq(nil)
281
281
  end
@@ -13,14 +13,14 @@ describe 'Form' do
13
13
  @holodeck.mock(Twilio::Response.new(500, ''))
14
14
 
15
15
  expect {
16
- @client.authy.v1.forms('form-app-push').fetch()
16
+ @client.verify.v2.forms('form-app-push').fetch()
17
17
  }.to raise_exception(Twilio::REST::TwilioError)
18
18
 
19
19
  values = {}
20
20
  expect(
21
21
  @holodeck.has_request?(Holodeck::Request.new(
22
22
  method: 'get',
23
- url: 'https://authy.twilio.com/v1/Forms/form-app-push',
23
+ url: 'https://verify.twilio.com/v2/Forms/form-app-push',
24
24
  ))).to eq(true)
25
25
  end
26
26
 
@@ -36,12 +36,12 @@ describe 'Form' do
36
36
  "create_challenge": {}
37
37
  },
38
38
  "form_meta": {},
39
- "url": "https://authy.twilio.com/v1/Forms/form-sms"
39
+ "url": "https://verify.twilio.com/v2/Forms/form-sms"
40
40
  }
41
41
  ]
42
42
  ))
43
43
 
44
- actual = @client.authy.v1.forms('form-app-push').fetch()
44
+ actual = @client.verify.v2.forms('form-app-push').fetch()
45
45
 
46
46
  expect(actual).to_not eq(nil)
47
47
  end
@@ -0,0 +1,46 @@
1
+ ##
2
+ # This code was generated by
3
+ # \ / _ _ _| _ _
4
+ # | (_)\/(_)(_|\/| |(/_ v1.0.0
5
+ # / /
6
+ #
7
+ # frozen_string_literal: true
8
+
9
+ require 'spec_helper.rb'
10
+
11
+ describe 'AccessToken' do
12
+ it "can create" do
13
+ @holodeck.mock(Twilio::Response.new(500, ''))
14
+
15
+ expect {
16
+ @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
17
+ .entities('identity') \
18
+ .access_tokens.create(factor_type: 'push')
19
+ }.to raise_exception(Twilio::REST::TwilioError)
20
+
21
+ values = {'FactorType' => 'push', }
22
+ expect(
23
+ @holodeck.has_request?(Holodeck::Request.new(
24
+ method: 'post',
25
+ url: 'https://verify.twilio.com/v2/Services/VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/AccessTokens',
26
+ data: values,
27
+ ))).to eq(true)
28
+ end
29
+
30
+ it "receives create responses" do
31
+ @holodeck.mock(Twilio::Response.new(
32
+ 201,
33
+ %q[
34
+ {
35
+ "token": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
36
+ }
37
+ ]
38
+ ))
39
+
40
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
41
+ .entities('identity') \
42
+ .access_tokens.create(factor_type: 'push')
43
+
44
+ expect(actual).to_not eq(nil)
45
+ end
46
+ end
@@ -13,17 +13,17 @@ describe 'Challenge' do
13
13
  @holodeck.mock(Twilio::Response.new(500, ''))
14
14
 
15
15
  expect {
16
- @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
17
- .entities('identity') \
18
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
19
- .challenges.create()
16
+ @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
17
+ .entities('identity') \
18
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
19
+ .challenges.create()
20
20
  }.to raise_exception(Twilio::REST::TwilioError)
21
21
 
22
22
  values = {}
23
23
  expect(
24
24
  @holodeck.has_request?(Holodeck::Request.new(
25
25
  method: 'post',
26
- url: 'https://authy.twilio.com/v1/Services/ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges',
26
+ url: 'https://verify.twilio.com/v2/Services/VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges',
27
27
  ))).to eq(true)
28
28
  end
29
29
 
@@ -34,7 +34,7 @@ describe 'Challenge' do
34
34
  {
35
35
  "sid": "YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
36
36
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
37
- "service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
37
+ "service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
38
38
  "entity_sid": "YEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
39
39
  "identity": "ff483d1ff591898a9942916050d2ca3f",
40
40
  "factor_sid": "YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
@@ -47,15 +47,15 @@ describe 'Challenge' do
47
47
  "details": "Hi! Mr. John Doe, would you like to sign up?",
48
48
  "hidden_details": "Hidden details about the sign up",
49
49
  "factor_type": "sms",
50
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
50
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
51
51
  }
52
52
  ]
53
53
  ))
54
54
 
55
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
56
- .entities('identity') \
57
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
58
- .challenges.create()
55
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
56
+ .entities('identity') \
57
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
58
+ .challenges.create()
59
59
 
60
60
  expect(actual).to_not eq(nil)
61
61
  end
@@ -64,17 +64,17 @@ describe 'Challenge' do
64
64
  @holodeck.mock(Twilio::Response.new(500, ''))
65
65
 
66
66
  expect {
67
- @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
68
- .entities('identity') \
69
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
70
- .challenges('sid').delete()
67
+ @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
68
+ .entities('identity') \
69
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
70
+ .challenges('sid').delete()
71
71
  }.to raise_exception(Twilio::REST::TwilioError)
72
72
 
73
73
  values = {}
74
74
  expect(
75
75
  @holodeck.has_request?(Holodeck::Request.new(
76
76
  method: 'delete',
77
- url: 'https://authy.twilio.com/v1/Services/ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges/sid',
77
+ url: 'https://verify.twilio.com/v2/Services/VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges/sid',
78
78
  ))).to eq(true)
79
79
  end
80
80
 
@@ -84,10 +84,10 @@ describe 'Challenge' do
84
84
  nil,
85
85
  ))
86
86
 
87
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
88
- .entities('identity') \
89
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
90
- .challenges('sid').delete()
87
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
88
+ .entities('identity') \
89
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
90
+ .challenges('sid').delete()
91
91
 
92
92
  expect(actual).to eq(true)
93
93
  end
@@ -96,17 +96,17 @@ describe 'Challenge' do
96
96
  @holodeck.mock(Twilio::Response.new(500, ''))
97
97
 
98
98
  expect {
99
- @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
100
- .entities('identity') \
101
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
102
- .challenges('sid').fetch()
99
+ @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
100
+ .entities('identity') \
101
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
102
+ .challenges('sid').fetch()
103
103
  }.to raise_exception(Twilio::REST::TwilioError)
104
104
 
105
105
  values = {}
106
106
  expect(
107
107
  @holodeck.has_request?(Holodeck::Request.new(
108
108
  method: 'get',
109
- url: 'https://authy.twilio.com/v1/Services/ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges/sid',
109
+ url: 'https://verify.twilio.com/v2/Services/VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges/sid',
110
110
  ))).to eq(true)
111
111
  end
112
112
 
@@ -117,7 +117,7 @@ describe 'Challenge' do
117
117
  {
118
118
  "sid": "YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
119
119
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
120
- "service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
120
+ "service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
121
121
  "entity_sid": "YEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
122
122
  "identity": "ff483d1ff591898a9942916050d2ca3f",
123
123
  "factor_sid": "YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
@@ -130,15 +130,15 @@ describe 'Challenge' do
130
130
  "details": "details",
131
131
  "hidden_details": "hidden_details",
132
132
  "factor_type": "sms",
133
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
133
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
134
134
  }
135
135
  ]
136
136
  ))
137
137
 
138
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
139
- .entities('identity') \
140
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
141
- .challenges('sid').fetch()
138
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
139
+ .entities('identity') \
140
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
141
+ .challenges('sid').fetch()
142
142
 
143
143
  expect(actual).to_not eq(nil)
144
144
  end
@@ -150,7 +150,7 @@ describe 'Challenge' do
150
150
  {
151
151
  "sid": "YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
152
152
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
153
- "service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
153
+ "service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
154
154
  "entity_sid": "YEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
155
155
  "identity": "ff483d1ff591898a9942916050d2ca3f",
156
156
  "factor_sid": "YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
@@ -163,15 +163,15 @@ describe 'Challenge' do
163
163
  "details": "details",
164
164
  "hidden_details": "hidden_details",
165
165
  "factor_type": "sms",
166
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
166
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
167
167
  }
168
168
  ]
169
169
  ))
170
170
 
171
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
172
- .entities('identity') \
173
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
174
- .challenges('sid').fetch()
171
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
172
+ .entities('identity') \
173
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
174
+ .challenges('sid').fetch()
175
175
 
176
176
  expect(actual).to_not eq(nil)
177
177
  end
@@ -180,17 +180,17 @@ describe 'Challenge' do
180
180
  @holodeck.mock(Twilio::Response.new(500, ''))
181
181
 
182
182
  expect {
183
- @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
184
- .entities('identity') \
185
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
186
- .challenges.list()
183
+ @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
184
+ .entities('identity') \
185
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
186
+ .challenges.list()
187
187
  }.to raise_exception(Twilio::REST::TwilioError)
188
188
 
189
189
  values = {}
190
190
  expect(
191
191
  @holodeck.has_request?(Holodeck::Request.new(
192
192
  method: 'get',
193
- url: 'https://authy.twilio.com/v1/Services/ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges',
193
+ url: 'https://verify.twilio.com/v2/Services/VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges',
194
194
  ))).to eq(true)
195
195
  end
196
196
 
@@ -203,9 +203,9 @@ describe 'Challenge' do
203
203
  "meta": {
204
204
  "page": 0,
205
205
  "page_size": 50,
206
- "first_page_url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
206
+ "first_page_url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
207
207
  "previous_page_url": null,
208
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
208
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
209
209
  "next_page_url": null,
210
210
  "key": "challenges"
211
211
  }
@@ -213,10 +213,10 @@ describe 'Challenge' do
213
213
  ]
214
214
  ))
215
215
 
216
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
217
- .entities('identity') \
218
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
219
- .challenges.list()
216
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
217
+ .entities('identity') \
218
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
219
+ .challenges.list()
220
220
 
221
221
  expect(actual).to_not eq(nil)
222
222
  end
@@ -230,7 +230,7 @@ describe 'Challenge' do
230
230
  {
231
231
  "sid": "YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
232
232
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
233
- "service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
233
+ "service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
234
234
  "entity_sid": "YEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
235
235
  "identity": "ff483d1ff591898a9942916050d2ca3f",
236
236
  "factor_sid": "YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
@@ -243,15 +243,15 @@ describe 'Challenge' do
243
243
  "details": "details",
244
244
  "hidden_details": "hidden_details",
245
245
  "factor_type": "sms",
246
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
246
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
247
247
  }
248
248
  ],
249
249
  "meta": {
250
250
  "page": 0,
251
251
  "page_size": 50,
252
- "first_page_url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
252
+ "first_page_url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
253
253
  "previous_page_url": null,
254
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
254
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges?PageSize=50&Page=0",
255
255
  "next_page_url": null,
256
256
  "key": "challenges"
257
257
  }
@@ -259,10 +259,10 @@ describe 'Challenge' do
259
259
  ]
260
260
  ))
261
261
 
262
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
263
- .entities('identity') \
264
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
265
- .challenges.list()
262
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
263
+ .entities('identity') \
264
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
265
+ .challenges.list()
266
266
 
267
267
  expect(actual).to_not eq(nil)
268
268
  end
@@ -271,17 +271,17 @@ describe 'Challenge' do
271
271
  @holodeck.mock(Twilio::Response.new(500, ''))
272
272
 
273
273
  expect {
274
- @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
275
- .entities('identity') \
276
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
277
- .challenges('sid').update()
274
+ @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
275
+ .entities('identity') \
276
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
277
+ .challenges('sid').update()
278
278
  }.to raise_exception(Twilio::REST::TwilioError)
279
279
 
280
280
  values = {}
281
281
  expect(
282
282
  @holodeck.has_request?(Holodeck::Request.new(
283
283
  method: 'post',
284
- url: 'https://authy.twilio.com/v1/Services/ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges/sid',
284
+ url: 'https://verify.twilio.com/v2/Services/VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Entities/identity/Factors/YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Challenges/sid',
285
285
  ))).to eq(true)
286
286
  end
287
287
 
@@ -292,7 +292,7 @@ describe 'Challenge' do
292
292
  {
293
293
  "sid": "YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
294
294
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
295
- "service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
295
+ "service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
296
296
  "entity_sid": "YEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
297
297
  "identity": "ff483d1ff591898a9942916050d2ca3f",
298
298
  "factor_sid": "YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
@@ -305,15 +305,15 @@ describe 'Challenge' do
305
305
  "details": "Hi! Mr. John Doe, would you like to sign up?",
306
306
  "hidden_details": "Hidden details about the sign up",
307
307
  "factor_type": "sms",
308
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
308
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
309
309
  }
310
310
  ]
311
311
  ))
312
312
 
313
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
314
- .entities('identity') \
315
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
316
- .challenges('sid').update()
313
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
314
+ .entities('identity') \
315
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
316
+ .challenges('sid').update()
317
317
 
318
318
  expect(actual).to_not eq(nil)
319
319
  end
@@ -325,7 +325,7 @@ describe 'Challenge' do
325
325
  {
326
326
  "sid": "YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
327
327
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
328
- "service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
328
+ "service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
329
329
  "entity_sid": "YEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
330
330
  "identity": "ff483d1ff591898a9942916050d2ca3f",
331
331
  "factor_sid": "YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
@@ -338,15 +338,15 @@ describe 'Challenge' do
338
338
  "details": "Hi! Mr. John Doe, would you like to sign up?",
339
339
  "hidden_details": "Hidden details about the sign up",
340
340
  "factor_type": "sms",
341
- "url": "https://authy.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
341
+ "url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities/ff483d1ff591898a9942916050d2ca3f/Factors/YFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Challenges/YCaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
342
342
  }
343
343
  ]
344
344
  ))
345
345
 
346
- actual = @client.authy.v1.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
347
- .entities('identity') \
348
- .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
349
- .challenges('sid').update()
346
+ actual = @client.verify.v2.services('VAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
347
+ .entities('identity') \
348
+ .factors('YFXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX') \
349
+ .challenges('sid').update()
350
350
 
351
351
  expect(actual).to_not eq(nil)
352
352
  end