class Twilio::REST::Verify::V2

Public Class Methods

new(domain) click to toggle source

Initialize the V2 version of Verify

Calls superclass method Twilio::REST::Version::new
   # File lib/twilio-ruby/rest/verify/v2.rb
15 def initialize(domain)
16   super
17   @version = 'v2'
18   @forms = nil
19   @services = nil
20   @verification_attempts = nil
21   @verification_templates = nil
22 end

Public Instance Methods

forms(form_type=:unset) click to toggle source

@param [form.FormTypes] form_type The Type of this Form. Currently only

`form-push` is supported.

@return [Twilio::REST::Verify::V2::FormContext] if form_type was passed. @return [Twilio::REST::Verify::V2::FormList]

   # File lib/twilio-ruby/rest/verify/v2.rb
29 def forms(form_type=:unset)
30   if form_type.nil?
31       raise ArgumentError, 'form_type cannot be nil'
32   end
33   if form_type == :unset
34       @forms ||= FormList.new self
35   else
36       FormContext.new(self, form_type)
37   end
38 end
services(sid=:unset) click to toggle source

@param [String] sid The Twilio-provided string that uniquely identifies the

Verification Service resource to fetch.

@return [Twilio::REST::Verify::V2::ServiceContext] if sid was passed. @return [Twilio::REST::Verify::V2::ServiceList]

   # File lib/twilio-ruby/rest/verify/v2.rb
45 def services(sid=:unset)
46   if sid.nil?
47       raise ArgumentError, 'sid cannot be nil'
48   end
49   if sid == :unset
50       @services ||= ServiceList.new self
51   else
52       ServiceContext.new(self, sid)
53   end
54 end
to_s() click to toggle source

Provide a user friendly representation

   # File lib/twilio-ruby/rest/verify/v2.rb
79 def to_s
80   '<Twilio::REST::Verify::V2>'
81 end
verification_attempts(sid=:unset) click to toggle source

@param [String] sid The unique SID identifier of a Verification Attempt @return [Twilio::REST::Verify::V2::VerificationAttemptContext] if sid was passed. @return [Twilio::REST::Verify::V2::VerificationAttemptList]

   # File lib/twilio-ruby/rest/verify/v2.rb
60 def verification_attempts(sid=:unset)
61   if sid.nil?
62       raise ArgumentError, 'sid cannot be nil'
63   end
64   if sid == :unset
65       @verification_attempts ||= VerificationAttemptList.new self
66   else
67       VerificationAttemptContext.new(self, sid)
68   end
69 end
verification_templates() click to toggle source

@return [Twilio::REST::Verify::V2::VerificationTemplateContext]

   # File lib/twilio-ruby/rest/verify/v2.rb
73 def verification_templates
74   @verification_templates ||= VerificationTemplateList.new self
75 end