Class: UnivapayClientSdk::DirectDebitBankAccountCreateRequest
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- UnivapayClientSdk::DirectDebitBankAccountCreateRequest
- Defined in:
- lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb
Overview
Request payload for registering a consumer bank account for direct debit.
Instance Attribute Summary collapse
-
#bank_account_name ⇒ String
Account holder name (口座名義), in half-width katakana.
-
#bank_account_number ⇒ String
Seven-digit account number (口座番号).
-
#bank_account_type ⇒ DirectDebitBankAccountType
Deposit account type (預金種類) —
regular(普通),current(当座),savings(貯蓄) orothers(その他). -
#bank_code ⇒ String
Four-digit code identifying the consumer's bank (銀行コード).
-
#bank_name ⇒ String
Bank name in half-width katakana (銀行名).
-
#branch_code ⇒ String
Three-digit code identifying the bank branch (支店コード).
-
#user_number ⇒ String
The merchant's own membership number for the consumer (会員番号).
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(user_number:, bank_code:, bank_name:, branch_code:, bank_account_type:, bank_account_name:, bank_account_number:, additional_properties: nil) ⇒ DirectDebitBankAccountCreateRequest
constructor
A new instance of DirectDebitBankAccountCreateRequest.
-
#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(user_number:, bank_code:, bank_name:, branch_code:, bank_account_type:, bank_account_name:, bank_account_number:, additional_properties: nil) ⇒ DirectDebitBankAccountCreateRequest
Returns a new instance of DirectDebitBankAccountCreateRequest.
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 66 def initialize(user_number:, bank_code:, bank_name:, branch_code:, bank_account_type:, bank_account_name:, bank_account_number:, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @user_number = user_number @bank_code = bank_code @bank_name = bank_name @branch_code = branch_code @bank_account_type = bank_account_type @bank_account_name = bank_account_name @bank_account_number = bank_account_number @additional_properties = additional_properties end |
Instance Attribute Details
#bank_account_name ⇒ String
Account holder name (口座名義), in half-width katakana. Full-width characters are rejected by the bank.
37 38 39 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 37 def bank_account_name @bank_account_name end |
#bank_account_number ⇒ String
Seven-digit account number (口座番号).
41 42 43 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 41 def bank_account_number @bank_account_number end |
#bank_account_type ⇒ DirectDebitBankAccountType
Deposit account type (預金種類) — regular (普通), current (当座), savings
(貯蓄) or others (その他).
32 33 34 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 32 def bank_account_type @bank_account_type end |
#bank_code ⇒ String
Four-digit code identifying the consumer's bank (銀行コード).
19 20 21 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 19 def bank_code @bank_code end |
#bank_name ⇒ String
Bank name in half-width katakana (銀行名).
23 24 25 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 23 def bank_name @bank_name end |
#branch_code ⇒ String
Three-digit code identifying the bank branch (支店コード).
27 28 29 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 27 def branch_code @branch_code end |
#user_number ⇒ String
The merchant's own membership number for the consumer (会員番号). Alphanumeric.
15 16 17 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 15 def user_number @user_number end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 83 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. user_number = hash.key?('user_number') ? hash['user_number'] : nil bank_code = hash.key?('bank_code') ? hash['bank_code'] : nil bank_name = hash.key?('bank_name') ? hash['bank_name'] : nil branch_code = hash.key?('branch_code') ? hash['branch_code'] : nil bank_account_type = hash.key?('bank_account_type') ? hash['bank_account_type'] : nil bank_account_name = hash.key?('bank_account_name') ? hash['bank_account_name'] : nil bank_account_number = hash.key?('bank_account_number') ? hash['bank_account_number'] : nil # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. DirectDebitBankAccountCreateRequest.new(user_number: user_number, bank_code: bank_code, bank_name: bank_name, branch_code: branch_code, bank_account_type: bank_account_type, bank_account_name: bank_account_name, bank_account_number: bank_account_number, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 44 def self.names @_hash = {} if @_hash.nil? @_hash['user_number'] = 'user_number' @_hash['bank_code'] = 'bank_code' @_hash['bank_name'] = 'bank_name' @_hash['branch_code'] = 'branch_code' @_hash['bank_account_type'] = 'bank_account_type' @_hash['bank_account_name'] = 'bank_account_name' @_hash['bank_account_number'] = 'bank_account_number' @_hash end |
.nullables ⇒ Object
An array for nullable fields
62 63 64 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 62 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
57 58 59 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 57 def self.optionals [] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
126 127 128 129 130 131 132 133 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 126 def inspect class_name = self.class.name.split('::').last "<#{class_name} user_number: #{@user_number.inspect}, bank_code: #{@bank_code.inspect},"\ " bank_name: #{@bank_name.inspect}, branch_code: #{@branch_code.inspect}, bank_account_type:"\ " #{@bank_account_type.inspect}, bank_account_name: #{@bank_account_name.inspect},"\ " bank_account_number: #{@bank_account_number.inspect}, additional_properties:"\ " #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
117 118 119 120 121 122 123 |
# File 'lib/univapay_client_sdk/models/direct_debit_bank_account_create_request.rb', line 117 def to_s class_name = self.class.name.split('::').last "<#{class_name} user_number: #{@user_number}, bank_code: #{@bank_code}, bank_name:"\ " #{@bank_name}, branch_code: #{@branch_code}, bank_account_type: #{@bank_account_type},"\ " bank_account_name: #{@bank_account_name}, bank_account_number: #{@bank_account_number},"\ " additional_properties: #{@additional_properties}>" end |