Class: ModernTreasury::ExternalAccountVerifyRequest
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- ModernTreasury::ExternalAccountVerifyRequest
- Defined in:
- lib/modern_treasury/models/external_account_verify_request.rb
Overview
ExternalAccountVerifyRequest Model.
Instance Attribute Summary collapse
-
#currency ⇒ CurrencyEnum
Three-letter ISO currency code.
-
#originating_account_id ⇒ UUID | String
The ID of the internal account where the micro-deposits originate from.
-
#payment_type ⇒ PaymentType4Enum
Both ach and eft are supported payment types.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(originating_account_id = nil, payment_type = nil, currency = SKIP) ⇒ ExternalAccountVerifyRequest
constructor
A new instance of ExternalAccountVerifyRequest.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(originating_account_id = nil, payment_type = nil, currency = SKIP) ⇒ ExternalAccountVerifyRequest
Returns a new instance of ExternalAccountVerifyRequest.
46 47 48 49 50 51 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 46 def initialize(originating_account_id = nil, payment_type = nil, currency = SKIP) @originating_account_id = originating_account_id @payment_type = payment_type @currency = currency unless currency == SKIP end |
Instance Attribute Details
#currency ⇒ CurrencyEnum
Three-letter ISO currency code.
23 24 25 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 23 def currency @currency end |
#originating_account_id ⇒ UUID | String
The ID of the internal account where the micro-deposits originate from. Both credit and debit capabilities must be enabled.
15 16 17 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 15 def originating_account_id @originating_account_id end |
#payment_type ⇒ PaymentType4Enum
Both ach and eft are supported payment types.
19 20 21 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 19 def payment_type @payment_type end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 54 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. originating_account_id = hash.key?('originating_account_id') ? hash['originating_account_id'] : nil payment_type = hash.key?('payment_type') ? hash['payment_type'] : nil currency = hash.key?('currency') ? hash['currency'] : SKIP # Create object from extracted values. ExternalAccountVerifyRequest.new(originating_account_id, payment_type, currency) end |
.names ⇒ Object
A mapping from model property names to API property names.
26 27 28 29 30 31 32 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 26 def self.names @_hash = {} if @_hash.nil? @_hash['originating_account_id'] = 'originating_account_id' @_hash['payment_type'] = 'payment_type' @_hash['currency'] = 'currency' @_hash end |
.nullables ⇒ Object
An array for nullable fields
42 43 44 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 42 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
35 36 37 38 39 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 35 def self.optionals %w[ currency ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
77 78 79 80 81 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 77 def inspect class_name = self.class.name.split('::').last "<#{class_name} originating_account_id: #{@originating_account_id.inspect}, payment_type:"\ " #{@payment_type.inspect}, currency: #{@currency.inspect}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
70 71 72 73 74 |
# File 'lib/modern_treasury/models/external_account_verify_request.rb', line 70 def to_s class_name = self.class.name.split('::').last "<#{class_name} originating_account_id: #{@originating_account_id}, payment_type:"\ " #{@payment_type}, currency: #{@currency}>" end |