twilio-ruby 5.16.0 → 5.17.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGES.md +22 -0
- data/README.md +2 -2
- data/lib/twilio-ruby/rest/api/v2010/account/message.rb +5 -1
- data/lib/twilio-ruby/rest/api/v2010/account/sip.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list.rb +1 -1
- data/lib/twilio-ruby/rest/api/v2010/account/sip/credential_list/credential.rb +3 -3
- data/lib/twilio-ruby/rest/api/v2010/account/sip/ip_access_control_list.rb +2 -2
- data/lib/twilio-ruby/rest/authy.rb +9 -9
- data/lib/twilio-ruby/rest/authy/v1.rb +16 -16
- data/lib/twilio-ruby/rest/authy/v1/form.rb +18 -18
- data/lib/twilio-ruby/rest/authy/v1/service/entity/factor.rb +6 -12
- data/lib/twilio-ruby/rest/authy/v1/service/entity/factor/challenge.rb +6 -13
- data/lib/twilio-ruby/rest/chat/v2/service/channel/member.rb +25 -3
- data/lib/twilio-ruby/rest/ip_messaging/v2/service/channel/member.rb +25 -3
- data/lib/twilio-ruby/rest/preview.rb +13 -20
- data/lib/twilio-ruby/rest/preview/marketplace.rb +13 -13
- data/lib/twilio-ruby/rest/sync/v1/service/sync_list/sync_list_item.rb +6 -3
- data/lib/twilio-ruby/rest/sync/v1/service/sync_map/sync_map_item.rb +6 -3
- data/lib/twilio-ruby/rest/verify/v1/service/verification.rb +4 -1
- data/lib/twilio-ruby/rest/video.rb +9 -9
- data/lib/twilio-ruby/rest/video/v1.rb +16 -16
- data/lib/twilio-ruby/version.rb +1 -1
- data/spec/integration/authy/v1/form_spec.rb +1 -1
- data/spec/integration/authy/v1/service/entity/factor/challenge_spec.rb +5 -10
- data/spec/integration/authy/v1/service/entity/factor_spec.rb +3 -3
- data/spec/integration/chat/v2/service/channel/member_spec.rb +4 -0
- data/spec/integration/ip_messaging/v2/service/channel/member_spec.rb +4 -0
- metadata +3 -10
- data/lib/twilio-ruby/rest/preview/authy.rb +0 -43
- data/lib/twilio-ruby/rest/preview/authy/service.rb +0 -364
- data/lib/twilio-ruby/rest/preview/authy/service/entity.rb +0 -326
- data/spec/integration/preview/authy/service/entity_spec.rb +0 -173
- data/spec/integration/preview/authy/service_spec.rb +0 -201
@@ -1,201 +0,0 @@
|
|
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 'Service' do
|
12
|
-
it "can create" do
|
13
|
-
@holodeck.mock(Twilio::Response.new(500, ''))
|
14
|
-
|
15
|
-
expect {
|
16
|
-
@client.preview.authy.services.create(friendly_name: 'friendly_name')
|
17
|
-
}.to raise_exception(Twilio::REST::TwilioError)
|
18
|
-
|
19
|
-
values = {'FriendlyName' => 'friendly_name', }
|
20
|
-
expect(
|
21
|
-
@holodeck.has_request?(Holodeck::Request.new(
|
22
|
-
method: 'post',
|
23
|
-
url: 'https://preview.twilio.com/Authy/Services',
|
24
|
-
data: values,
|
25
|
-
))).to eq(true)
|
26
|
-
end
|
27
|
-
|
28
|
-
it "receives create responses" do
|
29
|
-
@holodeck.mock(Twilio::Response.new(
|
30
|
-
201,
|
31
|
-
%q[
|
32
|
-
{
|
33
|
-
"sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
34
|
-
"friendly_name": "friendly_name",
|
35
|
-
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
36
|
-
"date_created": "2015-07-30T20:00:00Z",
|
37
|
-
"date_updated": "2015-07-30T20:00:00Z",
|
38
|
-
"url": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
39
|
-
"links": {
|
40
|
-
"entities": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities"
|
41
|
-
}
|
42
|
-
}
|
43
|
-
]
|
44
|
-
))
|
45
|
-
|
46
|
-
actual = @client.preview.authy.services.create(friendly_name: 'friendly_name')
|
47
|
-
|
48
|
-
expect(actual).to_not eq(nil)
|
49
|
-
end
|
50
|
-
|
51
|
-
it "can fetch" do
|
52
|
-
@holodeck.mock(Twilio::Response.new(500, ''))
|
53
|
-
|
54
|
-
expect {
|
55
|
-
@client.preview.authy.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
56
|
-
}.to raise_exception(Twilio::REST::TwilioError)
|
57
|
-
|
58
|
-
values = {}
|
59
|
-
expect(
|
60
|
-
@holodeck.has_request?(Holodeck::Request.new(
|
61
|
-
method: 'get',
|
62
|
-
url: 'https://preview.twilio.com/Authy/Services/ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
63
|
-
))).to eq(true)
|
64
|
-
end
|
65
|
-
|
66
|
-
it "receives fetch responses" do
|
67
|
-
@holodeck.mock(Twilio::Response.new(
|
68
|
-
200,
|
69
|
-
%q[
|
70
|
-
{
|
71
|
-
"sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
72
|
-
"friendly_name": "friendly_name",
|
73
|
-
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
74
|
-
"date_created": "2015-07-30T20:00:00Z",
|
75
|
-
"date_updated": "2015-07-30T20:00:00Z",
|
76
|
-
"url": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
77
|
-
"links": {
|
78
|
-
"entities": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities"
|
79
|
-
}
|
80
|
-
}
|
81
|
-
]
|
82
|
-
))
|
83
|
-
|
84
|
-
actual = @client.preview.authy.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').fetch()
|
85
|
-
|
86
|
-
expect(actual).to_not eq(nil)
|
87
|
-
end
|
88
|
-
|
89
|
-
it "can read" do
|
90
|
-
@holodeck.mock(Twilio::Response.new(500, ''))
|
91
|
-
|
92
|
-
expect {
|
93
|
-
@client.preview.authy.services.list()
|
94
|
-
}.to raise_exception(Twilio::REST::TwilioError)
|
95
|
-
|
96
|
-
values = {}
|
97
|
-
expect(
|
98
|
-
@holodeck.has_request?(Holodeck::Request.new(
|
99
|
-
method: 'get',
|
100
|
-
url: 'https://preview.twilio.com/Authy/Services',
|
101
|
-
))).to eq(true)
|
102
|
-
end
|
103
|
-
|
104
|
-
it "receives read_empty responses" do
|
105
|
-
@holodeck.mock(Twilio::Response.new(
|
106
|
-
200,
|
107
|
-
%q[
|
108
|
-
{
|
109
|
-
"services": [],
|
110
|
-
"meta": {
|
111
|
-
"page": 0,
|
112
|
-
"page_size": 50,
|
113
|
-
"first_page_url": "https://preview.twilio.com/Authy/Services?PageSize=50&Page=0",
|
114
|
-
"previous_page_url": null,
|
115
|
-
"url": "https://preview.twilio.com/Authy/Services?PageSize=50&Page=0",
|
116
|
-
"next_page_url": null,
|
117
|
-
"key": "services"
|
118
|
-
}
|
119
|
-
}
|
120
|
-
]
|
121
|
-
))
|
122
|
-
|
123
|
-
actual = @client.preview.authy.services.list()
|
124
|
-
|
125
|
-
expect(actual).to_not eq(nil)
|
126
|
-
end
|
127
|
-
|
128
|
-
it "receives read_full responses" do
|
129
|
-
@holodeck.mock(Twilio::Response.new(
|
130
|
-
200,
|
131
|
-
%q[
|
132
|
-
{
|
133
|
-
"services": [
|
134
|
-
{
|
135
|
-
"sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
136
|
-
"friendly_name": "friendly_name",
|
137
|
-
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
138
|
-
"date_created": "2015-07-30T20:00:00Z",
|
139
|
-
"date_updated": "2015-07-30T20:00:00Z",
|
140
|
-
"url": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
141
|
-
"links": {
|
142
|
-
"entities": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities"
|
143
|
-
}
|
144
|
-
}
|
145
|
-
],
|
146
|
-
"meta": {
|
147
|
-
"page": 0,
|
148
|
-
"page_size": 50,
|
149
|
-
"first_page_url": "https://preview.twilio.com/Authy/Services?PageSize=50&Page=0",
|
150
|
-
"previous_page_url": null,
|
151
|
-
"url": "https://preview.twilio.com/Authy/Services?PageSize=50&Page=0",
|
152
|
-
"next_page_url": null,
|
153
|
-
"key": "services"
|
154
|
-
}
|
155
|
-
}
|
156
|
-
]
|
157
|
-
))
|
158
|
-
|
159
|
-
actual = @client.preview.authy.services.list()
|
160
|
-
|
161
|
-
expect(actual).to_not eq(nil)
|
162
|
-
end
|
163
|
-
|
164
|
-
it "can update" do
|
165
|
-
@holodeck.mock(Twilio::Response.new(500, ''))
|
166
|
-
|
167
|
-
expect {
|
168
|
-
@client.preview.authy.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
169
|
-
}.to raise_exception(Twilio::REST::TwilioError)
|
170
|
-
|
171
|
-
values = {}
|
172
|
-
expect(
|
173
|
-
@holodeck.has_request?(Holodeck::Request.new(
|
174
|
-
method: 'post',
|
175
|
-
url: 'https://preview.twilio.com/Authy/Services/ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',
|
176
|
-
))).to eq(true)
|
177
|
-
end
|
178
|
-
|
179
|
-
it "receives update responses" do
|
180
|
-
@holodeck.mock(Twilio::Response.new(
|
181
|
-
200,
|
182
|
-
%q[
|
183
|
-
{
|
184
|
-
"sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
185
|
-
"friendly_name": "friendly_name",
|
186
|
-
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
187
|
-
"date_created": "2015-07-30T20:00:00Z",
|
188
|
-
"date_updated": "2015-07-30T20:00:00Z",
|
189
|
-
"url": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
190
|
-
"links": {
|
191
|
-
"entities": "https://preview.twilio.com/Authy/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Entities"
|
192
|
-
}
|
193
|
-
}
|
194
|
-
]
|
195
|
-
))
|
196
|
-
|
197
|
-
actual = @client.preview.authy.services('ISXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX').update()
|
198
|
-
|
199
|
-
expect(actual).to_not eq(nil)
|
200
|
-
end
|
201
|
-
end
|