Class: Twilio::REST::Verify::V2
- Inherits:
-
Twilio::REST::Version
- Object
- Twilio::REST::Version
- Twilio::REST::Verify::V2
- Defined in:
- lib/twilio-ruby/rest/verify/v2.rb,
lib/twilio-ruby/rest/verify/v2/form.rb,
lib/twilio-ruby/rest/verify/v2/service.rb,
lib/twilio-ruby/rest/verify/v2/template.rb,
lib/twilio-ruby/rest/verify/v2/service/entity.rb,
lib/twilio-ruby/rest/verify/v2/service/webhook.rb,
lib/twilio-ruby/rest/verify/v2/service/rate_limit.rb,
lib/twilio-ruby/rest/verify/v2/service/access_token.rb,
lib/twilio-ruby/rest/verify/v2/service/verification.rb,
lib/twilio-ruby/rest/verify/v2/verification_attempt.rb,
lib/twilio-ruby/rest/verify/v2/service/entity/factor.rb,
lib/twilio-ruby/rest/verify/v2/service/entity/challenge.rb,
lib/twilio-ruby/rest/verify/v2/service/entity/new_factor.rb,
lib/twilio-ruby/rest/verify/v2/service/rate_limit/bucket.rb,
lib/twilio-ruby/rest/verify/v2/service/verification_check.rb,
lib/twilio-ruby/rest/verify/v2/service/messaging_configuration.rb,
lib/twilio-ruby/rest/verify/v2/service/entity/challenge/notification.rb
Defined Under Namespace
Classes: FormContext, FormInstance, FormList, FormPage, ServiceContext, ServiceInstance, ServiceList, ServicePage, TemplateInstance, TemplateList, TemplatePage, VerificationAttemptContext, VerificationAttemptInstance, VerificationAttemptList, VerificationAttemptPage
Instance Attribute Summary
Attributes inherited from Twilio::REST::Version
Instance Method Summary collapse
- #forms(form_type = :unset) ⇒ Twilio::REST::Verify::V2::FormContext, Twilio::REST::Verify::V2::FormList
-
#initialize(domain) ⇒ V2
constructor
Initialize the V2 version of Verify.
- #services(sid = :unset) ⇒ Twilio::REST::Verify::V2::ServiceContext, Twilio::REST::Verify::V2::ServiceList
- #templates ⇒ Twilio::REST::Verify::V2::TemplateContext
-
#to_s ⇒ Object
Provide a user friendly representation.
- #verification_attempts(sid = :unset) ⇒ Twilio::REST::Verify::V2::VerificationAttemptContext, Twilio::REST::Verify::V2::VerificationAttemptList
Methods inherited from Twilio::REST::Version
#absolute_url, #create, #delete, #exception, #fetch, #page, #read_limits, #relative_uri, #request, #stream, #update
Constructor Details
#initialize(domain) ⇒ V2
Initialize the V2 version of Verify
15 16 17 18 19 20 21 22 |
# File 'lib/twilio-ruby/rest/verify/v2.rb', line 15 def initialize(domain) super @version = 'v2' @forms = nil @services = nil @verification_attempts = nil @templates = nil end |
Instance Method Details
#forms(form_type = :unset) ⇒ Twilio::REST::Verify::V2::FormContext, Twilio::REST::Verify::V2::FormList
29 30 31 32 33 34 35 36 37 38 |
# File 'lib/twilio-ruby/rest/verify/v2.rb', line 29 def forms(form_type=:unset) if form_type.nil? raise ArgumentError, 'form_type cannot be nil' end if form_type == :unset @forms ||= FormList.new self else FormContext.new(self, form_type) end end |
#services(sid = :unset) ⇒ Twilio::REST::Verify::V2::ServiceContext, Twilio::REST::Verify::V2::ServiceList
45 46 47 48 49 50 51 52 53 54 |
# File 'lib/twilio-ruby/rest/verify/v2.rb', line 45 def services(sid=:unset) if sid.nil? raise ArgumentError, 'sid cannot be nil' end if sid == :unset @services ||= ServiceList.new self else ServiceContext.new(self, sid) end end |
#templates ⇒ Twilio::REST::Verify::V2::TemplateContext
73 74 75 |
# File 'lib/twilio-ruby/rest/verify/v2.rb', line 73 def templates @templates ||= TemplateList.new self end |
#to_s ⇒ Object
Provide a user friendly representation
79 80 81 |
# File 'lib/twilio-ruby/rest/verify/v2.rb', line 79 def to_s '<Twilio::REST::Verify::V2>' end |
#verification_attempts(sid = :unset) ⇒ Twilio::REST::Verify::V2::VerificationAttemptContext, Twilio::REST::Verify::V2::VerificationAttemptList
60 61 62 63 64 65 66 67 68 69 |
# File 'lib/twilio-ruby/rest/verify/v2.rb', line 60 def verification_attempts(sid=:unset) if sid.nil? raise ArgumentError, 'sid cannot be nil' end if sid == :unset @verification_attempts ||= VerificationAttemptList.new self else VerificationAttemptContext.new(self, sid) end end |