Class: Plaid::VerificationStatus3

Inherits:
Object
  • Object
show all
Defined in:
lib/plaid/models/verification_status3.rb

Overview

‘VERIFICATION_STATUS_PROCESSING_COMPLETE`: The income verification status processing has completed. `VERIFICATION_STATUS_DOCUMENT_REJECTED`: The documentation uploaded by the end user was recognized as a supported file format, but not recognized as a valid paystub. `VERIFICATION_STATUS_PROCESSING_FAILED`: A failure occurred when attempting to process the verification documentation.

Constant Summary collapse

VERIFICATION_STATUS3 =
[
  # TODO: Write general description for
  # VERIFICATION_STATUS_PROCESSING_COMPLETE
  VERIFICATION_STATUS_PROCESSING_COMPLETE = 'VERIFICATION_STATUS_PROCESSING_COMPLETE'.freeze,

  # TODO: Write general description for
  # VERIFICATION_STATUS_DOCUMENT_REJECTED
  VERIFICATION_STATUS_DOCUMENT_REJECTED = 'VERIFICATION_STATUS_DOCUMENT_REJECTED'.freeze,

  # TODO: Write general description for
  # VERIFICATION_STATUS_PROCESSING_FAILED
  VERIFICATION_STATUS_PROCESSING_FAILED = 'VERIFICATION_STATUS_PROCESSING_FAILED'.freeze
].freeze

Class Method Summary collapse

Class Method Details

.from_value(value, default_value = VERIFICATION_STATUS_PROCESSING_COMPLETE) ⇒ Object



34
35
36
37
38
39
40
41
42
43
44
45
46
# File 'lib/plaid/models/verification_status3.rb', line 34

def self.from_value(value, default_value = VERIFICATION_STATUS_PROCESSING_COMPLETE)
  return default_value if value.nil?

  str = value.to_s.strip

  case str.downcase
  when 'verification_status_processing_complete' then VERIFICATION_STATUS_PROCESSING_COMPLETE
  when 'verification_status_document_rejected' then VERIFICATION_STATUS_DOCUMENT_REJECTED
  when 'verification_status_processing_failed' then VERIFICATION_STATUS_PROCESSING_FAILED
  else
    default_value
  end
end

.validate(value) ⇒ Object



28
29
30
31
32
# File 'lib/plaid/models/verification_status3.rb', line 28

def self.validate(value)
  return false if value.nil?

  true
end