twilio-ruby 5.2.2 → 5.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c74ddae744865799fc9de4d040d7e76e03a00af5
4
- data.tar.gz: c2c329a9cf5fa999f5f8b5aab65ad2b9eceb1e37
3
+ metadata.gz: 6d9b5316ccdb29c8d31c1e65cb9d193b17b468ab
4
+ data.tar.gz: 23f357ff05acc9e3dfe144560634c607325e9d09
5
5
  SHA512:
6
- metadata.gz: 384d64e79b01344c0e645ba553cf43bedf760d5e392e020cff47adfdbd1bdf1de0cb590a0f9d4819468b8a63a66e914a7832af03685a4f231241b848d7fba000
7
- data.tar.gz: d4a1539831a044d612d2fae57b888ee45384208ac68a9af3841e79f438d64eee5cc060c3156a3997ede480303b3edf63b7136f16203e7597ba90bbb17960850e
6
+ metadata.gz: 1ec8e3579ab72d8e42a075e552025e0c97145eb0d13ce659167445b0f42fa66ebf0e7e9dee638c89272553b08e13cf6d4393ed9570c5c6361ea001f23f344b22
7
+ data.tar.gz: 981d8ba5cd8c9e2f53ac60c2492eda489c98b796cc6ccefb30fc908a45eedc163be10a3a5c53725fc0e2765504299bc883f10040f09aacf1442ad6e278aaf34b
data/CHANGES.md CHANGED
@@ -1,6 +1,14 @@
1
1
  twilio-ruby changelog
2
2
  =====================
3
3
 
4
+ [2017-09-15] Version 5.2.3
5
+ ---------------------------
6
+ **Api**
7
+ - Add `sip_registration` property on SIP Domains
8
+ - Add new video and market usage category keys
9
+ - Add support for transferring IncomingPhoneNumbers between accounts.
10
+
11
+
4
12
  [2017-09-08] Version 5.2.2
5
13
  ---------------------------
6
14
  - Add configurable timeout to HttpClient
data/Makefile CHANGED
@@ -1,8 +1,8 @@
1
- .PHONY: test lint-changed lint docs
1
+ .PHONY: githooks test lint-changed lint docs
2
2
 
3
3
  CHANGED_RUBY_FILES = $(shell git status --porcelain | grep ".rb" | awk -F ' ' '{print $2}' | tr '\n' ' ')
4
4
 
5
- install:
5
+ install: githooks
6
6
  bundle install; bundle exec rake install
7
7
 
8
8
  test-install:
@@ -17,6 +17,10 @@ docs:
17
17
  lint:
18
18
  rubocop --cache true --parallel
19
19
 
20
+ githooks:
21
+ cp githooks/pre-commit .git/hooks/pre-commit
22
+ chmod +x .git/hooks/pre-commit
23
+
20
24
  authors:
21
25
  echo "Authors\n=======\n\nA huge thanks to all of our contributors:\n\n" > AUTHORS.md
22
26
  git log --raw | grep "^Author: " | cut -d ' ' -f2- | cut -d '<' -f1 | sed 's/^/- /' | sort | uniq >> AUTHORS.md
data/README.md CHANGED
@@ -27,13 +27,13 @@ in-line code documentation here in the library.
27
27
  To install using [Bundler][bundler] grab the latest stable version:
28
28
 
29
29
  ```ruby
30
- gem 'twilio-ruby', '~> 5.2.2'
30
+ gem 'twilio-ruby', '~> 5.2.3'
31
31
  ```
32
32
 
33
33
  To manually install `twilio-ruby` via [Rubygems][rubygems] simply gem install:
34
34
 
35
35
  ```bash
36
- gem install twilio-ruby -v 5.2.2
36
+ gem install twilio-ruby -v 5.2.3
37
37
  ```
38
38
 
39
39
  To build and install the development branch yourself from the latest source:
@@ -98,7 +98,8 @@ end
98
98
  ```
99
99
 
100
100
  ### Customizing your HTTP Client
101
- twilio-ruby uses [Faraday][faraday] to make HTTP requests. You can tell Twilio::REST::Client to use any of the Faraday adapters like so:
101
+ twilio-ruby uses [Faraday][faraday] to make HTTP requests. You can tell
102
+ Twilio::REST::Client to use any of the Faraday adapters like so:
102
103
 
103
104
  ```ruby
104
105
  @client.http_client.adapter = :typhoeus
@@ -0,0 +1 @@
1
+ make test
@@ -26,5 +26,8 @@ module Twilio
26
26
  "[HTTP #{status_code}] #{code} : #{message}"
27
27
  end
28
28
  end
29
+
30
+ class ObsoleteError < StandardError
31
+ end
29
32
  end
30
33
  end
@@ -0,0 +1,10 @@
1
+ module Twilio
2
+ module REST
3
+ class ObsoleteClient
4
+ def initialize(*)
5
+ raise ObsoleteError, "#{self.class} has been removed from this version of the library. "\
6
+ 'Please refer to current documentation for guidance.'
7
+ end
8
+ end
9
+ end
10
+ end
@@ -337,6 +337,8 @@ module Twilio
337
337
 
338
338
  ##
339
339
  # Update the IncomingPhoneNumberInstance
340
+ # @param [String] account_sid The unique id of the Account to which you wish to
341
+ # transfer this phnoe number
340
342
  # @param [String] api_version Calls to this phone number will start a new TwiML
341
343
  # session with this API version.
342
344
  # @param [String] friendly_name A human readable descriptive text for this
@@ -385,8 +387,9 @@ module Twilio
385
387
  # @param [incoming_phone_number.VoiceReceiveMode] voice_receive_mode The
386
388
  # voice_receive_mode
387
389
  # @return [IncomingPhoneNumberInstance] Updated IncomingPhoneNumberInstance
388
- def update(api_version: :unset, friendly_name: :unset, sms_application_sid: :unset, sms_fallback_method: :unset, sms_fallback_url: :unset, sms_method: :unset, sms_url: :unset, status_callback: :unset, status_callback_method: :unset, voice_application_sid: :unset, voice_caller_id_lookup: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_url: :unset, emergency_status: :unset, emergency_address_sid: :unset, trunk_sid: :unset, voice_receive_mode: :unset)
390
+ def update(account_sid: :unset, api_version: :unset, friendly_name: :unset, sms_application_sid: :unset, sms_fallback_method: :unset, sms_fallback_url: :unset, sms_method: :unset, sms_url: :unset, status_callback: :unset, status_callback_method: :unset, voice_application_sid: :unset, voice_caller_id_lookup: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_url: :unset, emergency_status: :unset, emergency_address_sid: :unset, trunk_sid: :unset, voice_receive_mode: :unset)
389
391
  data = Twilio::Values.of({
392
+ 'AccountSid' => account_sid,
390
393
  'ApiVersion' => api_version,
391
394
  'FriendlyName' => friendly_name,
392
395
  'SmsApplicationSid' => sms_application_sid,
@@ -722,6 +725,8 @@ module Twilio
722
725
 
723
726
  ##
724
727
  # Update the IncomingPhoneNumberInstance
728
+ # @param [String] account_sid The unique id of the Account to which you wish to
729
+ # transfer this phnoe number
725
730
  # @param [String] api_version Calls to this phone number will start a new TwiML
726
731
  # session with this API version.
727
732
  # @param [String] friendly_name A human readable descriptive text for this
@@ -770,8 +775,9 @@ module Twilio
770
775
  # @param [incoming_phone_number.VoiceReceiveMode] voice_receive_mode The
771
776
  # voice_receive_mode
772
777
  # @return [IncomingPhoneNumberInstance] Updated IncomingPhoneNumberInstance
773
- def update(api_version: :unset, friendly_name: :unset, sms_application_sid: :unset, sms_fallback_method: :unset, sms_fallback_url: :unset, sms_method: :unset, sms_url: :unset, status_callback: :unset, status_callback_method: :unset, voice_application_sid: :unset, voice_caller_id_lookup: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_url: :unset, emergency_status: :unset, emergency_address_sid: :unset, trunk_sid: :unset, voice_receive_mode: :unset)
778
+ def update(account_sid: :unset, api_version: :unset, friendly_name: :unset, sms_application_sid: :unset, sms_fallback_method: :unset, sms_fallback_url: :unset, sms_method: :unset, sms_url: :unset, status_callback: :unset, status_callback_method: :unset, voice_application_sid: :unset, voice_caller_id_lookup: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_url: :unset, emergency_status: :unset, emergency_address_sid: :unset, trunk_sid: :unset, voice_receive_mode: :unset)
774
779
  context.update(
780
+ account_sid: account_sid,
775
781
  api_version: api_version,
776
782
  friendly_name: friendly_name,
777
783
  sms_application_sid: sms_application_sid,
@@ -135,8 +135,9 @@ module Twilio
135
135
  # @param [String] voice_status_callback_url The URL that Twilio will request to
136
136
  # pass status parameters
137
137
  # @param [String] voice_status_callback_method The voice_status_callback_method
138
+ # @param [Boolean] sip_registration The sip_registration
138
139
  # @return [DomainInstance] Newly created DomainInstance
139
- def create(domain_name: nil, friendly_name: :unset, auth_type: :unset, voice_url: :unset, voice_method: :unset, voice_fallback_url: :unset, voice_fallback_method: :unset, voice_status_callback_url: :unset, voice_status_callback_method: :unset)
140
+ def create(domain_name: nil, friendly_name: :unset, auth_type: :unset, voice_url: :unset, voice_method: :unset, voice_fallback_url: :unset, voice_fallback_method: :unset, voice_status_callback_url: :unset, voice_status_callback_method: :unset, sip_registration: :unset)
140
141
  data = Twilio::Values.of({
141
142
  'DomainName' => domain_name,
142
143
  'FriendlyName' => friendly_name,
@@ -147,6 +148,7 @@ module Twilio
147
148
  'VoiceFallbackMethod' => voice_fallback_method,
148
149
  'VoiceStatusCallbackUrl' => voice_status_callback_url,
149
150
  'VoiceStatusCallbackMethod' => voice_status_callback_method,
151
+ 'SipRegistration' => sip_registration,
150
152
  })
151
153
 
152
154
  payload = @version.create(
@@ -255,8 +257,9 @@ module Twilio
255
257
  # @param [String] voice_status_callback_method The voice_status_callback_method
256
258
  # @param [String] voice_status_callback_url The voice_status_callback_url
257
259
  # @param [String] voice_url The voice_url
260
+ # @param [Boolean] sip_registration The sip_registration
258
261
  # @return [DomainInstance] Updated DomainInstance
259
- def update(auth_type: :unset, friendly_name: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_status_callback_method: :unset, voice_status_callback_url: :unset, voice_url: :unset)
262
+ def update(auth_type: :unset, friendly_name: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_status_callback_method: :unset, voice_status_callback_url: :unset, voice_url: :unset, sip_registration: :unset)
260
263
  data = Twilio::Values.of({
261
264
  'AuthType' => auth_type,
262
265
  'FriendlyName' => friendly_name,
@@ -266,6 +269,7 @@ module Twilio
266
269
  'VoiceStatusCallbackMethod' => voice_status_callback_method,
267
270
  'VoiceStatusCallbackUrl' => voice_status_callback_url,
268
271
  'VoiceUrl' => voice_url,
272
+ 'SipRegistration' => sip_registration,
269
273
  })
270
274
 
271
275
  payload = @version.update(
@@ -381,6 +385,7 @@ module Twilio
381
385
  'voice_status_callback_url' => payload['voice_status_callback_url'],
382
386
  'voice_url' => payload['voice_url'],
383
387
  'subresource_uris' => payload['subresource_uris'],
388
+ 'sip_registration' => payload['sip_registration'],
384
389
  }
385
390
 
386
391
  # Context
@@ -502,6 +507,12 @@ module Twilio
502
507
  @properties['subresource_uris']
503
508
  end
504
509
 
510
+ ##
511
+ # @return [Boolean] If SIP registration is allowed
512
+ def sip_registration
513
+ @properties['sip_registration']
514
+ end
515
+
505
516
  ##
506
517
  # Fetch a DomainInstance
507
518
  # @return [DomainInstance] Fetched DomainInstance
@@ -520,8 +531,9 @@ module Twilio
520
531
  # @param [String] voice_status_callback_method The voice_status_callback_method
521
532
  # @param [String] voice_status_callback_url The voice_status_callback_url
522
533
  # @param [String] voice_url The voice_url
534
+ # @param [Boolean] sip_registration The sip_registration
523
535
  # @return [DomainInstance] Updated DomainInstance
524
- def update(auth_type: :unset, friendly_name: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_status_callback_method: :unset, voice_status_callback_url: :unset, voice_url: :unset)
536
+ def update(auth_type: :unset, friendly_name: :unset, voice_fallback_method: :unset, voice_fallback_url: :unset, voice_method: :unset, voice_status_callback_method: :unset, voice_status_callback_url: :unset, voice_url: :unset, sip_registration: :unset)
525
537
  context.update(
526
538
  auth_type: auth_type,
527
539
  friendly_name: friendly_name,
@@ -531,6 +543,7 @@ module Twilio
531
543
  voice_status_callback_method: voice_status_callback_method,
532
544
  voice_status_callback_url: voice_status_callback_url,
533
545
  voice_url: voice_url,
546
+ sip_registration: sip_registration,
534
547
  )
535
548
  end
536
549
 
@@ -365,5 +365,33 @@ module Twilio
365
365
  "#<Twilio::REST::Client #{@account_sid}>"
366
366
  end
367
367
  end
368
+
369
+ ##
370
+ # Dummy client which provides no functionality. Please use Twilio::REST::Client instead.
371
+ class BaseClient < ObsoleteClient; end
372
+
373
+ ##
374
+ # Dummy client which provides no functionality. Please use Twilio::REST::Client instead.
375
+ class IpMessagingClient < ObsoleteClient; end
376
+
377
+ ##
378
+ # Dummy client which provides no functionality. Please use Twilio::REST::Client instead.
379
+ class LookupsClient < ObsoleteClient; end
380
+
381
+ ##
382
+ # Dummy client which provides no functionality. Please use Twilio::REST::Client instead.
383
+ class MonitorClient < ObsoleteClient; end
384
+
385
+ ##
386
+ # Dummy client which provides no functionality. Please use Twilio::REST::Client instead.
387
+ class PricingClient < ObsoleteClient; end
388
+
389
+ ##
390
+ # Dummy client which provides no functionality. Please use Twilio::REST::Client instead.
391
+ class TaskRouterClient < ObsoleteClient; end
392
+
393
+ ##
394
+ # Dummy client which provides no functionality. Please use Twilio::REST::Client instead.
395
+ class TrunkingClient < ObsoleteClient; end
368
396
  end
369
397
  end
@@ -17,25 +17,19 @@ module Twilio
17
17
  @port = 443
18
18
 
19
19
  # Versions
20
- @sync = nil
21
- @wireless = nil
20
+ @bulk_exports = nil
22
21
  @deployed_devices = nil
22
+ @hosted_numbers = nil
23
23
  @marketplace = nil
24
- @bulk_exports = nil
25
24
  @proxy = nil
26
- @hosted_numbers = nil
27
- end
28
-
29
- ##
30
- # Version sync of preview
31
- def sync
32
- @sync ||= Sync.new self
25
+ @sync = nil
26
+ @wireless = nil
33
27
  end
34
28
 
35
29
  ##
36
- # Version wireless of preview
37
- def wireless
38
- @wireless ||= Wireless.new self
30
+ # Version bulk_exports of preview
31
+ def bulk_exports
32
+ @bulk_exports ||= BulkExports.new self
39
33
  end
40
34
 
41
35
  ##
@@ -45,15 +39,15 @@ module Twilio
45
39
  end
46
40
 
47
41
  ##
48
- # Version marketplace of preview
49
- def marketplace
50
- @marketplace ||= Marketplace.new self
42
+ # Version hosted_numbers of preview
43
+ def hosted_numbers
44
+ @hosted_numbers ||= HostedNumbers.new self
51
45
  end
52
46
 
53
47
  ##
54
- # Version bulk_exports of preview
55
- def bulk_exports
56
- @bulk_exports ||= BulkExports.new self
48
+ # Version marketplace of preview
49
+ def marketplace
50
+ @marketplace ||= Marketplace.new self
57
51
  end
58
52
 
59
53
  ##
@@ -63,41 +57,31 @@ module Twilio
63
57
  end
64
58
 
65
59
  ##
66
- # Version hosted_numbers of preview
67
- def hosted_numbers
68
- @hosted_numbers ||= HostedNumbers.new self
69
- end
70
-
71
- ##
72
- # @param [String] sid A 34 character string that uniquely identifies this Service.
73
- # @return [Twilio::REST::Preview::Proxy::ServiceInstance] if sid was passed.
74
- # @return [Twilio::REST::Preview::Proxy::ServiceList]
75
- def services(sid=:unset)
76
- self.proxy.services(sid)
60
+ # Version sync of preview
61
+ def sync
62
+ @sync ||= Sync.new self
77
63
  end
78
64
 
79
65
  ##
80
- # @param [String] sid The sid
81
- # @return [Twilio::REST::Preview::Wireless::CommandInstance] if sid was passed.
82
- # @return [Twilio::REST::Preview::Wireless::CommandList]
83
- def commands(sid=:unset)
84
- self.wireless.commands(sid)
66
+ # Version wireless of preview
67
+ def wireless
68
+ @wireless ||= Wireless.new self
85
69
  end
86
70
 
87
71
  ##
88
- # @param [String] sid The sid
89
- # @return [Twilio::REST::Preview::Wireless::RatePlanInstance] if sid was passed.
90
- # @return [Twilio::REST::Preview::Wireless::RatePlanList]
91
- def rate_plans(sid=:unset)
92
- self.wireless.rate_plans(sid)
72
+ # @param [String] resource_type The resource_type
73
+ # @return [Twilio::REST::Preview::BulkExports::ExportInstance] if resource_type was passed.
74
+ # @return [Twilio::REST::Preview::BulkExports::ExportList]
75
+ def exports(resource_type=:unset)
76
+ self.bulk_exports.exports(resource_type)
93
77
  end
94
78
 
95
79
  ##
96
- # @param [String] sid The sid
97
- # @return [Twilio::REST::Preview::Wireless::SimInstance] if sid was passed.
98
- # @return [Twilio::REST::Preview::Wireless::SimList]
99
- def sims(sid=:unset)
100
- self.wireless.sims(sid)
80
+ # @param [String] resource_type The resource_type
81
+ # @return [Twilio::REST::Preview::BulkExports::ExportConfigurationInstance] if resource_type was passed.
82
+ # @return [Twilio::REST::Preview::BulkExports::ExportConfigurationList]
83
+ def export_configuration(resource_type=:unset)
84
+ self.bulk_exports.export_configuration(resource_type)
101
85
  end
102
86
 
103
87
  ##
@@ -109,6 +93,15 @@ module Twilio
109
93
  self.deployed_devices.fleets(sid)
110
94
  end
111
95
 
96
+ ##
97
+ # @param [String] sid A 34 character string that uniquely identifies this
98
+ # HostedNumberOrder.
99
+ # @return [Twilio::REST::Preview::HostedNumbers::HostedNumberOrderInstance] if sid was passed.
100
+ # @return [Twilio::REST::Preview::HostedNumbers::HostedNumberOrderList]
101
+ def hosted_number_orders(sid=:unset)
102
+ self.hosted_numbers.hosted_number_orders(sid)
103
+ end
104
+
112
105
  ##
113
106
  # @param [String] sid A 34 character string that uniquely identifies this Add-on.
114
107
  # @return [Twilio::REST::Preview::Marketplace::AvailableAddOnInstance] if sid was passed.
@@ -127,28 +120,35 @@ module Twilio
127
120
  end
128
121
 
129
122
  ##
130
- # @param [String] resource_type The resource_type
131
- # @return [Twilio::REST::Preview::BulkExports::ExportInstance] if resource_type was passed.
132
- # @return [Twilio::REST::Preview::BulkExports::ExportList]
133
- def exports(resource_type=:unset)
134
- self.bulk_exports.exports(resource_type)
123
+ # @param [String] sid The sid
124
+ # @return [Twilio::REST::Preview::Sync::ServiceInstance] if sid was passed.
125
+ # @return [Twilio::REST::Preview::Sync::ServiceList]
126
+ def services(sid=:unset)
127
+ self.sync.services(sid)
135
128
  end
136
129
 
137
130
  ##
138
- # @param [String] resource_type The resource_type
139
- # @return [Twilio::REST::Preview::BulkExports::ExportConfigurationInstance] if resource_type was passed.
140
- # @return [Twilio::REST::Preview::BulkExports::ExportConfigurationList]
141
- def export_configuration(resource_type=:unset)
142
- self.bulk_exports.export_configuration(resource_type)
131
+ # @param [String] sid The sid
132
+ # @return [Twilio::REST::Preview::Wireless::CommandInstance] if sid was passed.
133
+ # @return [Twilio::REST::Preview::Wireless::CommandList]
134
+ def commands(sid=:unset)
135
+ self.wireless.commands(sid)
143
136
  end
144
137
 
145
138
  ##
146
- # @param [String] sid A 34 character string that uniquely identifies this
147
- # HostedNumberOrder.
148
- # @return [Twilio::REST::Preview::HostedNumbers::HostedNumberOrderInstance] if sid was passed.
149
- # @return [Twilio::REST::Preview::HostedNumbers::HostedNumberOrderList]
150
- def hosted_number_orders(sid=:unset)
151
- self.hosted_numbers.hosted_number_orders(sid)
139
+ # @param [String] sid The sid
140
+ # @return [Twilio::REST::Preview::Wireless::RatePlanInstance] if sid was passed.
141
+ # @return [Twilio::REST::Preview::Wireless::RatePlanList]
142
+ def rate_plans(sid=:unset)
143
+ self.wireless.rate_plans(sid)
144
+ end
145
+
146
+ ##
147
+ # @param [String] sid The sid
148
+ # @return [Twilio::REST::Preview::Wireless::SimInstance] if sid was passed.
149
+ # @return [Twilio::REST::Preview::Wireless::SimList]
150
+ def sims(sid=:unset)
151
+ self.wireless.sims(sid)
152
152
  end
153
153
 
154
154
  ##
@@ -1,3 +1,3 @@
1
1
  module Twilio
2
- VERSION = '5.2.2'
2
+ VERSION = '5.2.3'
3
3
  end
@@ -38,6 +38,7 @@ describe 'Domain' do
38
38
  "date_updated": "Fri, 06 Sep 2013 18:48:50 -0000",
39
39
  "domain_name": "dunder-mifflin-scranton.api.twilio.com",
40
40
  "friendly_name": "Scranton Office",
41
+ "sip_registration": true,
41
42
  "sid": "SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
42
43
  "subresource_uris": {
43
44
  "credential_list_mappings": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SIP/Domains/SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialListMappings.json",
@@ -124,6 +125,7 @@ describe 'Domain' do
124
125
  "date_updated": "Fri, 06 Sep 2013 19:18:30 -0000",
125
126
  "domain_name": "dunder-mifflin-scranton.sip.twilio.com",
126
127
  "friendly_name": "Scranton Office",
128
+ "sip_registration": true,
127
129
  "sid": "SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
128
130
  "subresource_uris": {
129
131
  "credential_list_mappings": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SIP/Domains/SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialListMappings.json",
@@ -176,6 +178,7 @@ describe 'Domain' do
176
178
  "date_updated": "Fri, 06 Sep 2013 19:18:30 -0000",
177
179
  "domain_name": "dunder-mifflin-scranton.sip.twilio.com",
178
180
  "friendly_name": "Scranton Office",
181
+ "sip_registration": true,
179
182
  "sid": "SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
180
183
  "subresource_uris": {
181
184
  "credential_list_mappings": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SIP/Domains/SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialListMappings.json",
@@ -228,6 +231,7 @@ describe 'Domain' do
228
231
  "date_updated": "Fri, 06 Sep 2013 19:18:30 -0000",
229
232
  "domain_name": "dunder-mifflin-scranton.sip.twilio.com",
230
233
  "friendly_name": "Scranton Office",
234
+ "sip_registration": false,
231
235
  "sid": "SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
232
236
  "subresource_uris": {
233
237
  "credential_list_mappings": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SIP/Domains/SDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/CredentialListMappings.json",
@@ -0,0 +1,49 @@
1
+ require 'spec_helper'
2
+
3
+ describe Twilio::REST::ObsoleteClient do
4
+ it 'raise an exception' do
5
+ expect { Twilio::REST::ObsoleteClient.new }.to raise_error(Twilio::REST::ObsoleteError)
6
+ end
7
+ end
8
+
9
+ describe Twilio::REST::BaseClient do
10
+ it 'raise an exception' do
11
+ expect { Twilio::REST::BaseClient.new }.to raise_error(Twilio::REST::ObsoleteError)
12
+ end
13
+ end
14
+
15
+ describe Twilio::REST::IpMessagingClient do
16
+ it 'raise an exception' do
17
+ expect { Twilio::REST::IpMessagingClient.new }.to raise_error(Twilio::REST::ObsoleteError)
18
+ end
19
+ end
20
+
21
+ describe Twilio::REST::LookupsClient do
22
+ it 'raise an exception' do
23
+ expect { Twilio::REST::LookupsClient.new }.to raise_error(Twilio::REST::ObsoleteError)
24
+ end
25
+ end
26
+
27
+ describe Twilio::REST::MonitorClient do
28
+ it 'raise an exception' do
29
+ expect { Twilio::REST::MonitorClient.new }.to raise_error(Twilio::REST::ObsoleteError)
30
+ end
31
+ end
32
+
33
+ describe Twilio::REST::PricingClient do
34
+ it 'raise an exception' do
35
+ expect { Twilio::REST::PricingClient.new }.to raise_error(Twilio::REST::ObsoleteError)
36
+ end
37
+ end
38
+
39
+ describe Twilio::REST::TaskRouterClient do
40
+ it 'raise an exception' do
41
+ expect { Twilio::REST::TaskRouterClient.new }.to raise_error(Twilio::REST::ObsoleteError)
42
+ end
43
+ end
44
+
45
+ describe Twilio::REST::TrunkingClient do
46
+ it 'raise an exception' do
47
+ expect { Twilio::REST::TrunkingClient.new }.to raise_error(Twilio::REST::ObsoleteError)
48
+ end
49
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twilio-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.2.2
4
+ version: 5.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Twilio API Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-09-08 00:00:00.000000000 Z
11
+ date: 2017-09-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: libxml-ruby
@@ -126,11 +126,13 @@ files:
126
126
  - conf/cacert.pem
127
127
  - examples/examples.rb
128
128
  - examples/print_call_log.rb
129
+ - githooks/pre-commit
129
130
  - lib/rack/twilio_webhook_authentication.rb
130
131
  - lib/twilio-ruby.rb
131
132
  - lib/twilio-ruby/framework/domain.rb
132
133
  - lib/twilio-ruby/framework/error.rb
133
134
  - lib/twilio-ruby/framework/helper.rb
135
+ - lib/twilio-ruby/framework/obsolete_client.rb
134
136
  - lib/twilio-ruby/framework/page.rb
135
137
  - lib/twilio-ruby/framework/request.rb
136
138
  - lib/twilio-ruby/framework/resource.rb
@@ -596,6 +598,7 @@ files:
596
598
  - spec/jwt/client_capability_spec.rb
597
599
  - spec/jwt/task_router_spec.rb
598
600
  - spec/rack/twilio_webhook_authentication_spec.rb
601
+ - spec/rest/client_spec.rb
599
602
  - spec/security/request_validator_spec.rb
600
603
  - spec/spec_helper.rb
601
604
  - spec/support/fakeweb.rb
@@ -844,6 +847,7 @@ test_files:
844
847
  - spec/jwt/client_capability_spec.rb
845
848
  - spec/jwt/task_router_spec.rb
846
849
  - spec/rack/twilio_webhook_authentication_spec.rb
850
+ - spec/rest/client_spec.rb
847
851
  - spec/security/request_validator_spec.rb
848
852
  - spec/spec_helper.rb
849
853
  - spec/support/fakeweb.rb