Class: Twilio::REST::Verify::V2::ServiceContext::VerificationCheckInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Verify::V2::ServiceContext::VerificationCheckInstance
- Defined in:
- lib/twilio-ruby/rest/verify/v2/service/verification_check.rb
Instance Method Summary collapse
-
#account_sid ⇒ String
The SID of the [Account](www.twilio.com/docs/iam/api/account) that created the VerificationCheck resource.
-
#amount ⇒ String
The amount of the associated PSD2 compliant transaction.
- #channel ⇒ Channel
-
#date_created ⇒ Time
The [ISO 8601](en.wikipedia.org/wiki/ISO_8601) date and time in GMT when the Verification Check resource was created.
-
#date_updated ⇒ Time
The [ISO 8601](en.wikipedia.org/wiki/ISO_8601) date and time in GMT when the Verification Check resource was last updated.
-
#initialize(version, payload, service_sid: nil) ⇒ VerificationCheckInstance
constructor
Initialize the VerificationCheckInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#payee ⇒ String
The payee of the associated PSD2 compliant transaction.
-
#service_sid ⇒ String
The SID of the [Service](www.twilio.com/docs/verify/api/service) the resource is associated with.
-
#sid ⇒ String
The unique string that we created to identify the VerificationCheck resource.
-
#sna_attempts_error_codes ⇒ Array<Hash>
List of error codes as a result of attempting a verification using the
snachannel. -
#status ⇒ String
The status of the verification.
-
#to ⇒ String
The phone number or [email](www.twilio.com/docs/verify/email) being verified.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#valid ⇒ Boolean
Use "status" instead.
Constructor Details
#initialize(version, payload, service_sid: nil) ⇒ VerificationCheckInstance
Initialize the VerificationCheckInstance
123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 123 def initialize(version, payload , service_sid: nil) super(version) # Marshaled Properties @properties = { 'sid' => payload['sid'], 'service_sid' => payload['service_sid'], 'account_sid' => payload['account_sid'], 'to' => payload['to'], 'channel' => payload['channel'], 'status' => payload['status'], 'valid' => payload['valid'], 'amount' => payload['amount'], 'payee' => payload['payee'], 'date_created' => Twilio.deserialize_iso8601_datetime(payload['date_created']), 'date_updated' => Twilio.deserialize_iso8601_datetime(payload['date_updated']), 'sna_attempts_error_codes' => payload['sna_attempts_error_codes'], } end |
Instance Method Details
#account_sid ⇒ String
Returns The SID of the [Account](www.twilio.com/docs/iam/api/account) that created the VerificationCheck resource.
158 159 160 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 158 def account_sid @properties['account_sid'] end |
#amount ⇒ String
Returns The amount of the associated PSD2 compliant transaction. Requires the PSD2 Service flag enabled.
188 189 190 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 188 def amount @properties['amount'] end |
#channel ⇒ Channel
170 171 172 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 170 def channel @properties['channel'] end |
#date_created ⇒ Time
Returns The [ISO 8601](en.wikipedia.org/wiki/ISO_8601) date and time in GMT when the Verification Check resource was created.
200 201 202 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 200 def date_created @properties['date_created'] end |
#date_updated ⇒ Time
Returns The [ISO 8601](en.wikipedia.org/wiki/ISO_8601) date and time in GMT when the Verification Check resource was last updated.
206 207 208 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 206 def date_updated @properties['date_updated'] end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
224 225 226 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 224 def inspect "<Twilio.Verify.V2.VerificationCheckInstance>" end |
#payee ⇒ String
Returns The payee of the associated PSD2 compliant transaction. Requires the PSD2 Service flag enabled.
194 195 196 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 194 def payee @properties['payee'] end |
#service_sid ⇒ String
Returns The SID of the [Service](www.twilio.com/docs/verify/api/service) the resource is associated with.
152 153 154 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 152 def service_sid @properties['service_sid'] end |
#sid ⇒ String
Returns The unique string that we created to identify the VerificationCheck resource.
146 147 148 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 146 def sid @properties['sid'] end |
#sna_attempts_error_codes ⇒ Array<Hash>
Returns List of error codes as a result of attempting a verification using the sna channel. The error codes are chronologically ordered, from the first attempt to the latest attempt. This will be an empty list if no errors occured or null if the last channel used wasn’t sna.
212 213 214 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 212 def sna_attempts_error_codes @properties['sna_attempts_error_codes'] end |
#status ⇒ String
Returns The status of the verification. Can be: pending, approved, canceled, max_attempts_reached, deleted, failed or expired.
176 177 178 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 176 def status @properties['status'] end |
#to ⇒ String
Returns The phone number or [email](www.twilio.com/docs/verify/email) being verified. Phone numbers must be in [E.164 format](www.twilio.com/docs/glossary/what-e164).
164 165 166 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 164 def to @properties['to'] end |
#to_s ⇒ Object
Provide a user friendly representation
218 219 220 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 218 def to_s "<Twilio.Verify.V2.VerificationCheckInstance>" end |
#valid ⇒ Boolean
Returns Use "status" instead. Legacy property indicating whether the verification was successful.
182 183 184 |
# File 'lib/twilio-ruby/rest/verify/v2/service/verification_check.rb', line 182 def valid @properties['valid'] end |