Class: ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry
- Defined in:
- lib/modern_treasury/models/ledger_transaction_create_partial_post_params.rb
Defined Under Namespace
Modules: Direction
Instance Attribute Summary collapse
-
#amount ⇒ Integer
Value in specified currency’s smallest unit.
-
#direction ⇒ Symbol, ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction
One of ‘credit`, `debit`.
-
#ledger_account_id ⇒ String
The ledger account that this ledger entry is associated with.
-
#metadata ⇒ Hash{Symbol=>String}?
Additional data represented as key-value pairs.
Instance Method Summary collapse
-
#initialize(amount: , direction: , ledger_account_id: , metadata: nil) ⇒ Object
constructor
Some parameter documentations has been truncated, see PostedLedgerEntry for more details.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(amount: , direction: , ledger_account_id: , metadata: nil) ⇒ Object
Some parameter documentations has been truncated, see ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry for more details.
55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 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/modern_treasury/models/ledger_transaction_create_partial_post_params.rb', line 55 class PostedLedgerEntry < ModernTreasury::Internal::Type::BaseModel # @!attribute amount # Value in specified currency's smallest unit. e.g. $10 would be represented # as 1000. Can be any integer up to 36 digits. # # @return [Integer] required :amount, Integer # @!attribute direction # One of `credit`, `debit`. Describes the direction money is flowing in the # transaction. A `credit` moves money from your account to someone else's. A # `debit` pulls money from someone else's account to your own. Note that wire, # rtp, and check payments will always be `credit`. # # @return [Symbol, ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction] required :direction, enum: -> { ModernTreasury::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction } # @!attribute ledger_account_id # The ledger account that this ledger entry is associated with. # # @return [String] required :ledger_account_id, String # @!attribute metadata # Additional data represented as key-value pairs. Both the key and value must be # strings. # # @return [Hash{Symbol=>String}, nil] optional :metadata, ModernTreasury::Internal::Type::HashOf[String] # @!method initialize(amount:, direction:, ledger_account_id:, metadata: nil) # Some parameter documentations has been truncated, see # {ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry} # for more details. # # @param amount [Integer] Value in specified currency's smallest unit. e.g. $10 would be represented as 10 # # @param direction [Symbol, ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction] One of `credit`, `debit`. Describes the direction money is flowing in the transa # # @param ledger_account_id [String] The ledger account that this ledger entry is associated with. # # @param metadata [Hash{Symbol=>String}] Additional data represented as key-value pairs. Both the key and value must be s # One of `credit`, `debit`. Describes the direction money is flowing in the # transaction. A `credit` moves money from your account to someone else's. A # `debit` pulls money from someone else's account to your own. Note that wire, # rtp, and check payments will always be `credit`. # # @see ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry#direction module Direction extend ModernTreasury::Internal::Type::Enum CREDIT = :credit DEBIT = :debit # @!method self.values # @return [Array<Symbol>] end end |
Instance Attribute Details
#amount ⇒ Integer
Value in specified currency’s smallest unit. e.g. $10 would be represented as 1000. Can be any integer up to 36 digits.
61 |
# File 'lib/modern_treasury/models/ledger_transaction_create_partial_post_params.rb', line 61 required :amount, Integer |
#direction ⇒ Symbol, ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction
One of ‘credit`, `debit`. Describes the direction money is flowing in the transaction. A `credit` moves money from your account to someone else’s. A ‘debit` pulls money from someone else’s account to your own. Note that wire, rtp, and check payments will always be ‘credit`.
70 71 |
# File 'lib/modern_treasury/models/ledger_transaction_create_partial_post_params.rb', line 70 required :direction, enum: -> { ModernTreasury::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction } |
#ledger_account_id ⇒ String
The ledger account that this ledger entry is associated with.
77 |
# File 'lib/modern_treasury/models/ledger_transaction_create_partial_post_params.rb', line 77 required :ledger_account_id, String |
#metadata ⇒ Hash{Symbol=>String}?
Additional data represented as key-value pairs. Both the key and value must be strings.
84 |
# File 'lib/modern_treasury/models/ledger_transaction_create_partial_post_params.rb', line 84 optional :metadata, ModernTreasury::Internal::Type::HashOf[String] |