modern_treasury 0.3.0 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (173) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +31 -0
  3. data/README.md +1 -1
  4. data/lib/modern_treasury/internal/transport/base_client.rb +1 -4
  5. data/lib/modern_treasury/internal/transport/pooled_net_requester.rb +1 -9
  6. data/lib/modern_treasury/internal/type/base_model.rb +6 -12
  7. data/lib/modern_treasury/internal/util.rb +1 -1
  8. data/lib/modern_treasury/models/account_collection_flow.rb +2 -6
  9. data/lib/modern_treasury/models/account_collection_flow_create_params.rb +1 -3
  10. data/lib/modern_treasury/models/bulk_request_create_params.rb +28 -107
  11. data/lib/modern_treasury/models/bulk_result.rb +1 -3
  12. data/lib/modern_treasury/models/child_legal_entity_create.rb +10 -12
  13. data/lib/modern_treasury/models/connection_legal_entity_create_params.rb +11 -15
  14. data/lib/modern_treasury/models/counterparty.rb +4 -16
  15. data/lib/modern_treasury/models/counterparty_collect_account_params.rb +1 -3
  16. data/lib/modern_treasury/models/counterparty_create_params.rb +18 -33
  17. data/lib/modern_treasury/models/expected_payment_create_params.rb +1 -3
  18. data/lib/modern_treasury/models/expected_payment_list_params.rb +1 -0
  19. data/lib/modern_treasury/models/expected_payment_type.rb +1 -0
  20. data/lib/modern_treasury/models/external_account_create_params.rb +3 -6
  21. data/lib/modern_treasury/models/external_account_verify_params.rb +1 -0
  22. data/lib/modern_treasury/models/external_account_verify_response.rb +1 -0
  23. data/lib/modern_treasury/models/internal_account.rb +2 -3
  24. data/lib/modern_treasury/models/internal_account_create_params.rb +2 -3
  25. data/lib/modern_treasury/models/internal_account_list_params.rb +1 -0
  26. data/lib/modern_treasury/models/internal_account_update_account_capability_response.rb +1 -0
  27. data/lib/modern_treasury/models/internal_accounts/balance_report.rb +2 -7
  28. data/lib/modern_treasury/models/internal_accounts/balance_report_create_params.rb +2 -6
  29. data/lib/modern_treasury/models/internal_accounts/balance_report_retrieve_params.rb +1 -3
  30. data/lib/modern_treasury/models/ledger_account_balance_monitor_create_params.rb +1 -4
  31. data/lib/modern_treasury/models/ledger_account_list_params.rb +1 -4
  32. data/lib/modern_treasury/models/ledger_account_settlement.rb +3 -3
  33. data/lib/modern_treasury/models/ledger_entry_list_params.rb +46 -4
  34. data/lib/modern_treasury/models/ledger_transaction_create_partial_post_params.rb +2 -6
  35. data/lib/modern_treasury/models/ledger_transaction_list_params.rb +45 -1
  36. data/lib/modern_treasury/models/ledger_transactions/ledger_transaction_version.rb +2 -6
  37. data/lib/modern_treasury/models/legal_entity.rb +11 -16
  38. data/lib/modern_treasury/models/legal_entity_address_create_request.rb +1 -3
  39. data/lib/modern_treasury/models/legal_entity_association.rb +15 -27
  40. data/lib/modern_treasury/models/legal_entity_association_create_params.rb +1 -3
  41. data/lib/modern_treasury/models/legal_entity_bank_settings.rb +91 -0
  42. data/lib/modern_treasury/models/legal_entity_create_params.rb +11 -15
  43. data/lib/modern_treasury/models/legal_entity_update_params.rb +10 -12
  44. data/lib/modern_treasury/models/legal_entity_wealth_employment_detail.rb +312 -0
  45. data/lib/modern_treasury/models/line_item.rb +1 -18
  46. data/lib/modern_treasury/models/payment_action_create_response.rb +1 -1
  47. data/lib/modern_treasury/models/payment_action_list_params.rb +1 -2
  48. data/lib/modern_treasury/models/payment_action_list_response.rb +1 -1
  49. data/lib/modern_treasury/models/payment_action_retrieve_response.rb +1 -1
  50. data/lib/modern_treasury/models/payment_action_update_params.rb +1 -0
  51. data/lib/modern_treasury/models/payment_action_update_response.rb +1 -1
  52. data/lib/modern_treasury/models/payment_flow.rb +1 -4
  53. data/lib/modern_treasury/models/payment_order.rb +2 -19
  54. data/lib/modern_treasury/models/payment_order_create_async_params.rb +8 -37
  55. data/lib/modern_treasury/models/payment_order_create_params.rb +9 -40
  56. data/lib/modern_treasury/models/payment_order_list_params.rb +1 -0
  57. data/lib/modern_treasury/models/payment_order_type.rb +1 -0
  58. data/lib/modern_treasury/models/payment_order_update_params.rb +8 -37
  59. data/lib/modern_treasury/models/payment_reference.rb +1 -0
  60. data/lib/modern_treasury/models/reconciliation_rule.rb +1 -0
  61. data/lib/modern_treasury/models/return_object.rb +1 -0
  62. data/lib/modern_treasury/models/routing_detail.rb +1 -0
  63. data/lib/modern_treasury/models/routing_detail_create_params.rb +1 -0
  64. data/lib/modern_treasury/models/routing_number_lookup_request.rb +3 -7
  65. data/lib/modern_treasury/models/transaction.rb +1 -0
  66. data/lib/modern_treasury/models/transaction_create_params.rb +1 -0
  67. data/lib/modern_treasury/models/virtual_account_create_params.rb +3 -6
  68. data/lib/modern_treasury/models.rb +4 -2
  69. data/lib/modern_treasury/resources/ledger_entries.rb +3 -1
  70. data/lib/modern_treasury/resources/ledger_transactions.rb +3 -1
  71. data/lib/modern_treasury/resources/legal_entities.rb +4 -4
  72. data/lib/modern_treasury/resources/payment_orders.rb +3 -15
  73. data/lib/modern_treasury/version.rb +1 -1
  74. data/lib/modern_treasury.rb +2 -1
  75. data/rbi/modern_treasury/errors.rbi +2 -2
  76. data/rbi/modern_treasury/models/bulk_request_create_params.rbi +15 -38
  77. data/rbi/modern_treasury/models/child_legal_entity_create.rbi +14 -8
  78. data/rbi/modern_treasury/models/connection_legal_entity_create_params.rbi +16 -8
  79. data/rbi/modern_treasury/models/counterparty_create_params.rbi +21 -8
  80. data/rbi/modern_treasury/models/expected_payment_list_params.rbi +5 -0
  81. data/rbi/modern_treasury/models/expected_payment_type.rbi +1 -0
  82. data/rbi/modern_treasury/models/external_account_create_params.rbi +5 -0
  83. data/rbi/modern_treasury/models/external_account_verify_params.rbi +5 -0
  84. data/rbi/modern_treasury/models/external_account_verify_response.rbi +5 -0
  85. data/rbi/modern_treasury/models/internal_account.rbi +5 -0
  86. data/rbi/modern_treasury/models/internal_account_create_params.rbi +5 -0
  87. data/rbi/modern_treasury/models/internal_account_list_params.rbi +5 -0
  88. data/rbi/modern_treasury/models/internal_account_update_account_capability_response.rbi +5 -0
  89. data/rbi/modern_treasury/models/ledger_account_settlement.rbi +3 -3
  90. data/rbi/modern_treasury/models/ledger_entry_list_params.rbi +82 -0
  91. data/rbi/modern_treasury/models/ledger_transaction_list_params.rbi +84 -0
  92. data/rbi/modern_treasury/models/legal_entity.rbi +14 -8
  93. data/rbi/modern_treasury/models/legal_entity_association.rbi +16 -8
  94. data/rbi/modern_treasury/models/legal_entity_bank_settings.rbi +112 -0
  95. data/rbi/modern_treasury/models/legal_entity_create_params.rbi +14 -8
  96. data/rbi/modern_treasury/models/legal_entity_update_params.rbi +14 -8
  97. data/rbi/modern_treasury/models/legal_entity_wealth_employment_detail.rbi +815 -0
  98. data/rbi/modern_treasury/models/line_item.rbi +0 -21
  99. data/rbi/modern_treasury/models/payment_action_create_response.rbi +2 -2
  100. data/rbi/modern_treasury/models/payment_action_list_params.rbi +5 -10
  101. data/rbi/modern_treasury/models/payment_action_list_response.rbi +2 -2
  102. data/rbi/modern_treasury/models/payment_action_retrieve_response.rbi +2 -2
  103. data/rbi/modern_treasury/models/payment_action_update_params.rbi +5 -0
  104. data/rbi/modern_treasury/models/payment_action_update_response.rbi +2 -2
  105. data/rbi/modern_treasury/models/payment_order.rbi +5 -19
  106. data/rbi/modern_treasury/models/payment_order_create_async_params.rbi +5 -19
  107. data/rbi/modern_treasury/models/payment_order_create_params.rbi +5 -19
  108. data/rbi/modern_treasury/models/payment_order_list_params.rbi +5 -0
  109. data/rbi/modern_treasury/models/payment_order_type.rbi +1 -0
  110. data/rbi/modern_treasury/models/payment_order_update_params.rbi +5 -19
  111. data/rbi/modern_treasury/models/payment_reference.rbi +5 -0
  112. data/rbi/modern_treasury/models/reconciliation_rule.rbi +2 -0
  113. data/rbi/modern_treasury/models/return_object.rbi +5 -0
  114. data/rbi/modern_treasury/models/routing_detail.rbi +5 -0
  115. data/rbi/modern_treasury/models/routing_detail_create_params.rbi +5 -0
  116. data/rbi/modern_treasury/models/routing_number_lookup_request.rbi +5 -0
  117. data/rbi/modern_treasury/models/transaction.rbi +1 -0
  118. data/rbi/modern_treasury/models/transaction_create_params.rbi +5 -0
  119. data/rbi/modern_treasury/models/virtual_account_create_params.rbi +5 -0
  120. data/rbi/modern_treasury/models.rbi +5 -2
  121. data/rbi/modern_treasury/resources/ledger_entries.rbi +3 -0
  122. data/rbi/modern_treasury/resources/ledger_transactions.rbi +3 -0
  123. data/rbi/modern_treasury/resources/legal_entities.rbi +10 -4
  124. data/rbi/modern_treasury/resources/payment_orders.rbi +0 -18
  125. data/sig/modern_treasury/models/bulk_request_create_params.rbs +6 -28
  126. data/sig/modern_treasury/models/child_legal_entity_create.rbs +8 -8
  127. data/sig/modern_treasury/models/connection_legal_entity_create_params.rbs +8 -8
  128. data/sig/modern_treasury/models/counterparty_create_params.rbs +10 -8
  129. data/sig/modern_treasury/models/expected_payment_list_params.rbs +2 -0
  130. data/sig/modern_treasury/models/expected_payment_type.rbs +2 -0
  131. data/sig/modern_treasury/models/external_account_create_params.rbs +2 -0
  132. data/sig/modern_treasury/models/external_account_verify_params.rbs +2 -0
  133. data/sig/modern_treasury/models/external_account_verify_response.rbs +2 -0
  134. data/sig/modern_treasury/models/internal_account.rbs +2 -0
  135. data/sig/modern_treasury/models/internal_account_create_params.rbs +2 -0
  136. data/sig/modern_treasury/models/internal_account_list_params.rbs +2 -0
  137. data/sig/modern_treasury/models/internal_account_update_account_capability_response.rbs +2 -0
  138. data/sig/modern_treasury/models/ledger_account_settlement.rbs +4 -4
  139. data/sig/modern_treasury/models/ledger_entry_list_params.rbs +50 -0
  140. data/sig/modern_treasury/models/ledger_transaction_list_params.rbs +50 -0
  141. data/sig/modern_treasury/models/legal_entity.rbs +8 -8
  142. data/sig/modern_treasury/models/legal_entity_association.rbs +8 -8
  143. data/sig/modern_treasury/models/legal_entity_bank_settings.rbs +65 -0
  144. data/sig/modern_treasury/models/legal_entity_create_params.rbs +8 -8
  145. data/sig/modern_treasury/models/legal_entity_update_params.rbs +8 -8
  146. data/sig/modern_treasury/models/legal_entity_wealth_employment_detail.rbs +325 -0
  147. data/sig/modern_treasury/models/line_item.rbs +0 -10
  148. data/sig/modern_treasury/models/payment_action_list_params.rbs +9 -5
  149. data/sig/modern_treasury/models/payment_action_update_params.rbs +8 -1
  150. data/sig/modern_treasury/models/payment_order.rbs +2 -10
  151. data/sig/modern_treasury/models/payment_order_create_async_params.rbs +2 -14
  152. data/sig/modern_treasury/models/payment_order_create_params.rbs +2 -14
  153. data/sig/modern_treasury/models/payment_order_list_params.rbs +2 -0
  154. data/sig/modern_treasury/models/payment_order_type.rbs +2 -0
  155. data/sig/modern_treasury/models/payment_order_update_params.rbs +2 -14
  156. data/sig/modern_treasury/models/payment_reference.rbs +2 -0
  157. data/sig/modern_treasury/models/reconciliation_rule.rbs +2 -0
  158. data/sig/modern_treasury/models/return_object.rbs +2 -0
  159. data/sig/modern_treasury/models/routing_detail.rbs +2 -0
  160. data/sig/modern_treasury/models/routing_detail_create_params.rbs +2 -0
  161. data/sig/modern_treasury/models/routing_number_lookup_request.rbs +2 -0
  162. data/sig/modern_treasury/models/transaction.rbs +2 -0
  163. data/sig/modern_treasury/models/transaction_create_params.rbs +2 -0
  164. data/sig/modern_treasury/models/virtual_account_create_params.rbs +2 -0
  165. data/sig/modern_treasury/models.rbs +4 -2
  166. data/sig/modern_treasury/resources/ledger_entries.rbs +1 -0
  167. data/sig/modern_treasury/resources/ledger_transactions.rbs +1 -0
  168. data/sig/modern_treasury/resources/legal_entities.rbs +4 -4
  169. data/sig/modern_treasury/resources/payment_orders.rbs +0 -6
  170. metadata +8 -5
  171. data/lib/modern_treasury/models/accounting.rb +0 -30
  172. data/rbi/modern_treasury/models/accounting.rbi +0 -48
  173. data/sig/modern_treasury/models/accounting.rbs +0 -15
@@ -40,14 +40,12 @@ module ModernTreasury
40
40
  #
41
41
  # @return [Array<ModernTreasury::Models::LegalEntityAddressCreateRequest>, nil]
42
42
  optional :addresses,
43
- -> {
44
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityAddressCreateRequest]
45
- }
43
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityAddressCreateRequest] }
46
44
 
47
45
  # @!attribute bank_settings
48
46
  #
49
- # @return [ModernTreasury::Models::BankSettings, nil]
50
- optional :bank_settings, -> { ModernTreasury::BankSettings }, nil?: true
47
+ # @return [ModernTreasury::Models::LegalEntityBankSettings, nil]
48
+ optional :bank_settings, -> { ModernTreasury::LegalEntityBankSettings }, nil?: true
51
49
 
52
50
  # @!attribute business_name
53
51
  # The business's legal business name.
@@ -107,9 +105,7 @@ module ModernTreasury
107
105
  #
108
106
  # @return [Array<ModernTreasury::Models::LegalEntityIndustryClassification>, nil]
109
107
  optional :industry_classifications,
110
- -> {
111
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityIndustryClassification]
112
- }
108
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityIndustryClassification] }
113
109
 
114
110
  # @!attribute last_name
115
111
  # An individual's last name.
@@ -159,9 +155,7 @@ module ModernTreasury
159
155
  #
160
156
  # @return [Array<ModernTreasury::Models::ConnectionLegalEntityCreateParams::LegalEntity::PhoneNumber>, nil]
161
157
  optional :phone_numbers,
162
- -> {
163
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ConnectionLegalEntityCreateParams::LegalEntity::PhoneNumber]
164
- }
158
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ConnectionLegalEntityCreateParams::LegalEntity::PhoneNumber] }
165
159
 
166
160
  # @!attribute politically_exposed_person
167
161
  # Whether the individual is a politically exposed person.
@@ -197,8 +191,10 @@ module ModernTreasury
197
191
 
198
192
  # @!attribute wealth_and_employment_details
199
193
  #
200
- # @return [ModernTreasury::Models::WealthAndEmploymentDetails, nil]
201
- optional :wealth_and_employment_details, -> { ModernTreasury::WealthAndEmploymentDetails }, nil?: true
194
+ # @return [ModernTreasury::Models::LegalEntityWealthEmploymentDetail, nil]
195
+ optional :wealth_and_employment_details,
196
+ -> { ModernTreasury::LegalEntityWealthEmploymentDetail },
197
+ nil?: true
202
198
 
203
199
  # @!attribute website
204
200
  # The entity's primary website URL.
@@ -215,7 +211,7 @@ module ModernTreasury
215
211
  #
216
212
  # @param addresses [Array<ModernTreasury::Models::LegalEntityAddressCreateRequest>] A list of addresses for the entity.
217
213
  #
218
- # @param bank_settings [ModernTreasury::Models::BankSettings, nil]
214
+ # @param bank_settings [ModernTreasury::Models::LegalEntityBankSettings, nil]
219
215
  #
220
216
  # @param business_name [String, nil] The business's legal business name.
221
217
  #
@@ -261,7 +257,7 @@ module ModernTreasury
261
257
  #
262
258
  # @param suffix [String, nil] An individual's suffix.
263
259
  #
264
- # @param wealth_and_employment_details [ModernTreasury::Models::WealthAndEmploymentDetails, nil]
260
+ # @param wealth_and_employment_details [ModernTreasury::Models::LegalEntityWealthEmploymentDetail, nil]
265
261
  #
266
262
  # @param website [String, nil] The entity's primary website URL.
267
263
 
@@ -13,10 +13,7 @@ module ModernTreasury
13
13
  # The accounts for this counterparty.
14
14
  #
15
15
  # @return [Array<ModernTreasury::Models::Counterparty::Account>]
16
- required :accounts,
17
- -> {
18
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::Counterparty::Account]
19
- }
16
+ required :accounts, -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::Counterparty::Account] }
20
17
 
21
18
  # @!attribute created_at
22
19
  #
@@ -130,10 +127,7 @@ module ModernTreasury
130
127
  # @!attribute account_details
131
128
  #
132
129
  # @return [Array<ModernTreasury::Models::AccountDetail>, nil]
133
- optional :account_details,
134
- -> {
135
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::AccountDetail]
136
- }
130
+ optional :account_details, -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::AccountDetail] }
137
131
 
138
132
  # @!attribute account_type
139
133
  # Can be `checking`, `savings` or `other`.
@@ -144,10 +138,7 @@ module ModernTreasury
144
138
  # @!attribute contact_details
145
139
  #
146
140
  # @return [Array<ModernTreasury::Models::ContactDetail>, nil]
147
- optional :contact_details,
148
- -> {
149
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ContactDetail]
150
- }
141
+ optional :contact_details, -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ContactDetail] }
151
142
 
152
143
  # @!attribute created_at
153
144
  #
@@ -219,10 +210,7 @@ module ModernTreasury
219
210
  # @!attribute routing_details
220
211
  #
221
212
  # @return [Array<ModernTreasury::Models::RoutingDetail>, nil]
222
- optional :routing_details,
223
- -> {
224
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::RoutingDetail]
225
- }
213
+ optional :routing_details, -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::RoutingDetail] }
226
214
 
227
215
  # @!attribute updated_at
228
216
  #
@@ -32,9 +32,7 @@ module ModernTreasury
32
32
  #
33
33
  # @return [Array<Symbol, ModernTreasury::Models::CounterpartyCollectAccountParams::Field>, nil]
34
34
  optional :fields,
35
- -> {
36
- ModernTreasury::Internal::Type::ArrayOf[enum: ModernTreasury::CounterpartyCollectAccountParams::Field]
37
- }
35
+ -> { ModernTreasury::Internal::Type::ArrayOf[enum: ModernTreasury::CounterpartyCollectAccountParams::Field] }
38
36
 
39
37
  # @!attribute send_email
40
38
  # By default, Modern Treasury will send an email to your counterparty that
@@ -29,9 +29,7 @@ module ModernTreasury
29
29
  #
30
30
  # @return [Array<ModernTreasury::Models::CounterpartyCreateParams::Account>, nil]
31
31
  optional :accounts,
32
- -> {
33
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::Account]
34
- }
32
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::Account] }
35
33
 
36
34
  # @!attribute email
37
35
  # The counterparty's email.
@@ -149,9 +147,7 @@ module ModernTreasury
149
147
  #
150
148
  # @return [Array<ModernTreasury::Models::CounterpartyCreateParams::Account::AccountDetail>, nil]
151
149
  optional :account_details,
152
- -> {
153
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::Account::AccountDetail]
154
- }
150
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::Account::AccountDetail] }
155
151
 
156
152
  # @!attribute account_type
157
153
  # Can be `checking`, `savings` or `other`.
@@ -231,9 +227,7 @@ module ModernTreasury
231
227
  #
232
228
  # @return [Array<ModernTreasury::Models::CounterpartyCreateParams::Account::RoutingDetail>, nil]
233
229
  optional :routing_details,
234
- -> {
235
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::Account::RoutingDetail]
236
- }
230
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::Account::RoutingDetail] }
237
231
 
238
232
  # @!method initialize(account_details: nil, account_type: nil, contact_details: nil, external_id: nil, ledger_account: nil, metadata: nil, name: nil, party_address: nil, party_identifier: nil, party_name: nil, party_type: nil, plaid_processor_token: nil, routing_details: nil)
239
233
  # Some parameter documentations has been truncated, see
@@ -275,9 +269,7 @@ module ModernTreasury
275
269
  #
276
270
  # @return [Symbol, ModernTreasury::Models::CounterpartyCreateParams::Account::AccountDetail::AccountNumberType, nil]
277
271
  optional :account_number_type,
278
- enum: -> {
279
- ModernTreasury::CounterpartyCreateParams::Account::AccountDetail::AccountNumberType
280
- }
272
+ enum: -> { ModernTreasury::CounterpartyCreateParams::Account::AccountDetail::AccountNumberType }
281
273
 
282
274
  # @!method initialize(account_number:, account_number_type: nil)
283
275
  # @param account_number [String]
@@ -330,9 +322,7 @@ module ModernTreasury
330
322
  #
331
323
  # @return [Symbol, ModernTreasury::Models::CounterpartyCreateParams::Account::RoutingDetail::RoutingNumberType]
332
324
  required :routing_number_type,
333
- enum: -> {
334
- ModernTreasury::CounterpartyCreateParams::Account::RoutingDetail::RoutingNumberType
335
- }
325
+ enum: -> { ModernTreasury::CounterpartyCreateParams::Account::RoutingDetail::RoutingNumberType }
336
326
 
337
327
  # @!attribute payment_type
338
328
  #
@@ -392,6 +382,7 @@ module ModernTreasury
392
382
  DK_NETS = :dk_nets
393
383
  EFT = :eft
394
384
  ETHEREUM = :ethereum
385
+ GB_FPS = :gb_fps
395
386
  HU_ICS = :hu_ics
396
387
  INTERAC = :interac
397
388
  MASAV = :masav
@@ -448,14 +439,12 @@ module ModernTreasury
448
439
  #
449
440
  # @return [Array<ModernTreasury::Models::LegalEntityAddressCreateRequest>, nil]
450
441
  optional :addresses,
451
- -> {
452
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityAddressCreateRequest]
453
- }
442
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityAddressCreateRequest] }
454
443
 
455
444
  # @!attribute bank_settings
456
445
  #
457
- # @return [ModernTreasury::Models::BankSettings, nil]
458
- optional :bank_settings, -> { ModernTreasury::BankSettings }, nil?: true
446
+ # @return [ModernTreasury::Models::LegalEntityBankSettings, nil]
447
+ optional :bank_settings, -> { ModernTreasury::LegalEntityBankSettings }, nil?: true
459
448
 
460
449
  # @!attribute business_name
461
450
  # The business's legal business name.
@@ -515,9 +504,7 @@ module ModernTreasury
515
504
  #
516
505
  # @return [Array<ModernTreasury::Models::LegalEntityIndustryClassification>, nil]
517
506
  optional :industry_classifications,
518
- -> {
519
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityIndustryClassification]
520
- }
507
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LegalEntityIndustryClassification] }
521
508
 
522
509
  # @!attribute last_name
523
510
  # An individual's last name.
@@ -560,9 +547,7 @@ module ModernTreasury
560
547
  #
561
548
  # @return [Array<ModernTreasury::Models::CounterpartyCreateParams::LegalEntity::PhoneNumber>, nil]
562
549
  optional :phone_numbers,
563
- -> {
564
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::LegalEntity::PhoneNumber]
565
- }
550
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::CounterpartyCreateParams::LegalEntity::PhoneNumber] }
566
551
 
567
552
  # @!attribute politically_exposed_person
568
553
  # Whether the individual is a politically exposed person.
@@ -598,8 +583,10 @@ module ModernTreasury
598
583
 
599
584
  # @!attribute wealth_and_employment_details
600
585
  #
601
- # @return [ModernTreasury::Models::WealthAndEmploymentDetails, nil]
602
- optional :wealth_and_employment_details, -> { ModernTreasury::WealthAndEmploymentDetails }, nil?: true
586
+ # @return [ModernTreasury::Models::LegalEntityWealthEmploymentDetail, nil]
587
+ optional :wealth_and_employment_details,
588
+ -> { ModernTreasury::LegalEntityWealthEmploymentDetail },
589
+ nil?: true
603
590
 
604
591
  # @!attribute website
605
592
  # The entity's primary website URL.
@@ -616,7 +603,7 @@ module ModernTreasury
616
603
  #
617
604
  # @param addresses [Array<ModernTreasury::Models::LegalEntityAddressCreateRequest>] A list of addresses for the entity.
618
605
  #
619
- # @param bank_settings [ModernTreasury::Models::BankSettings, nil]
606
+ # @param bank_settings [ModernTreasury::Models::LegalEntityBankSettings, nil]
620
607
  #
621
608
  # @param business_name [String, nil] The business's legal business name.
622
609
  #
@@ -660,7 +647,7 @@ module ModernTreasury
660
647
  #
661
648
  # @param suffix [String, nil] An individual's suffix.
662
649
  #
663
- # @param wealth_and_employment_details [ModernTreasury::Models::WealthAndEmploymentDetails, nil]
650
+ # @param wealth_and_employment_details [ModernTreasury::Models::LegalEntityWealthEmploymentDetail, nil]
664
651
  #
665
652
  # @param website [String, nil] The entity's primary website URL.
666
653
 
@@ -682,9 +669,7 @@ module ModernTreasury
682
669
  #
683
670
  # @return [Array<Symbol, ModernTreasury::Models::CounterpartyCreateParams::LegalEntity::LegalEntityAssociation::RelationshipType>]
684
671
  required :relationship_types,
685
- -> {
686
- ModernTreasury::Internal::Type::ArrayOf[enum: ModernTreasury::CounterpartyCreateParams::LegalEntity::LegalEntityAssociation::RelationshipType]
687
- }
672
+ -> { ModernTreasury::Internal::Type::ArrayOf[enum: ModernTreasury::CounterpartyCreateParams::LegalEntity::LegalEntityAssociation::RelationshipType] }
688
673
 
689
674
  # @!attribute child_legal_entity
690
675
  # The child legal entity.
@@ -92,9 +92,7 @@ module ModernTreasury
92
92
  #
93
93
  # @return [Array<ModernTreasury::Models::ExpectedPaymentCreateParams::LineItem>, nil]
94
94
  optional :line_items,
95
- -> {
96
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ExpectedPaymentCreateParams::LineItem]
97
- }
95
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ExpectedPaymentCreateParams::LineItem] }
98
96
 
99
97
  # @!attribute metadata
100
98
  # Additional data represented as key-value pairs. Both the key and value must be
@@ -147,6 +147,7 @@ module ModernTreasury
147
147
  DK_NETS = :dk_nets
148
148
  EFT = :eft
149
149
  ETHEREUM = :ethereum
150
+ GB_FPS = :gb_fps
150
151
  HU_ICS = :hu_ics
151
152
  INTERAC = :interac
152
153
  MASAV = :masav
@@ -19,6 +19,7 @@ module ModernTreasury
19
19
  DK_NETS = :dk_nets
20
20
  EFT = :eft
21
21
  ETHEREUM = :ethereum
22
+ GB_FPS = :gb_fps
22
23
  HU_ICS = :hu_ics
23
24
  INTERAC = :interac
24
25
  MASAV = :masav
@@ -22,9 +22,7 @@ module ModernTreasury
22
22
  #
23
23
  # @return [Array<ModernTreasury::Models::ExternalAccountCreateParams::AccountDetail>, nil]
24
24
  optional :account_details,
25
- -> {
26
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ExternalAccountCreateParams::AccountDetail]
27
- }
25
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ExternalAccountCreateParams::AccountDetail] }
28
26
 
29
27
  # @!attribute account_type
30
28
  # Can be `checking`, `savings` or `other`.
@@ -96,9 +94,7 @@ module ModernTreasury
96
94
  #
97
95
  # @return [Array<ModernTreasury::Models::ExternalAccountCreateParams::RoutingDetail>, nil]
98
96
  optional :routing_details,
99
- -> {
100
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ExternalAccountCreateParams::RoutingDetail]
101
- }
97
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::ExternalAccountCreateParams::RoutingDetail] }
102
98
 
103
99
  # @!method initialize(counterparty_id:, body_external_id: nil, account_details: nil, account_type: nil, contact_details: nil, ledger_account: nil, metadata: nil, name: nil, party_address: nil, party_identifier: nil, party_name: nil, party_type: nil, plaid_processor_token: nil, routing_details: nil, request_options: {})
104
100
  # Some parameter documentations has been truncated, see
@@ -255,6 +251,7 @@ module ModernTreasury
255
251
  DK_NETS = :dk_nets
256
252
  EFT = :eft
257
253
  ETHEREUM = :ethereum
254
+ GB_FPS = :gb_fps
258
255
  HU_ICS = :hu_ics
259
256
  INTERAC = :interac
260
257
  MASAV = :masav
@@ -73,6 +73,7 @@ module ModernTreasury
73
73
  DK_NETS = :dk_nets
74
74
  EFT = :eft
75
75
  ETHEREUM = :ethereum
76
+ GB_FPS = :gb_fps
76
77
  HU_ICS = :hu_ics
77
78
  INTERAC = :interac
78
79
  MASAV = :masav
@@ -118,6 +118,7 @@ module ModernTreasury
118
118
  DK_NETS = :dk_nets
119
119
  EFT = :eft
120
120
  ETHEREUM = :ethereum
121
+ GB_FPS = :gb_fps
121
122
  HU_ICS = :hu_ics
122
123
  INTERAC = :interac
123
124
  MASAV = :masav
@@ -15,9 +15,7 @@ module ModernTreasury
15
15
  #
16
16
  # @return [Array<ModernTreasury::Models::InternalAccount::AccountCapability>]
17
17
  required :account_capabilities,
18
- -> {
19
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccount::AccountCapability]
20
- }
18
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccount::AccountCapability] }
21
19
 
22
20
  # @!attribute account_details
23
21
  # An array of account detail objects.
@@ -274,6 +272,7 @@ module ModernTreasury
274
272
  DK_NETS = :dk_nets
275
273
  EFT = :eft
276
274
  ETHEREUM = :ethereum
275
+ GB_FPS = :gb_fps
277
276
  HU_ICS = :hu_ics
278
277
  INTERAC = :interac
279
278
  MASAV = :masav
@@ -38,9 +38,7 @@ module ModernTreasury
38
38
  #
39
39
  # @return [Array<ModernTreasury::Models::InternalAccountCreateParams::AccountCapability>, nil]
40
40
  optional :account_capabilities,
41
- -> {
42
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccountCreateParams::AccountCapability]
43
- }
41
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccountCreateParams::AccountCapability] }
44
42
 
45
43
  # @!attribute account_type
46
44
  # The account type, used to provision the appropriate account at the financial
@@ -217,6 +215,7 @@ module ModernTreasury
217
215
  DK_NETS = :dk_nets
218
216
  EFT = :eft
219
217
  ETHEREUM = :ethereum
218
+ GB_FPS = :gb_fps
220
219
  HU_ICS = :hu_ics
221
220
  INTERAC = :interac
222
221
  MASAV = :masav
@@ -93,6 +93,7 @@ module ModernTreasury
93
93
  DK_NETS = :dk_nets
94
94
  EFT = :eft
95
95
  ETHEREUM = :ethereum
96
+ GB_FPS = :gb_fps
96
97
  HU_ICS = :hu_ics
97
98
  INTERAC = :interac
98
99
  MASAV = :masav
@@ -100,6 +100,7 @@ module ModernTreasury
100
100
  DK_NETS = :dk_nets
101
101
  EFT = :eft
102
102
  ETHEREUM = :ethereum
103
+ GB_FPS = :gb_fps
103
104
  HU_ICS = :hu_ics
104
105
  INTERAC = :interac
105
106
  MASAV = :masav
@@ -35,9 +35,7 @@ module ModernTreasury
35
35
  #
36
36
  # @return [Array<ModernTreasury::Models::InternalAccounts::BalanceReport::Balance>]
37
37
  required :balances,
38
- -> {
39
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccounts::BalanceReport::Balance]
40
- }
38
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccounts::BalanceReport::Balance] }
41
39
 
42
40
  # @!attribute created_at
43
41
  #
@@ -138,10 +136,7 @@ module ModernTreasury
138
136
  # 'previously_closed_book', or `other`.
139
137
  #
140
138
  # @return [Symbol, ModernTreasury::Models::InternalAccounts::BalanceReport::Balance::BalanceType]
141
- required :balance_type,
142
- enum: -> {
143
- ModernTreasury::InternalAccounts::BalanceReport::Balance::BalanceType
144
- }
139
+ required :balance_type, enum: -> { ModernTreasury::InternalAccounts::BalanceReport::Balance::BalanceType }
145
140
 
146
141
  # @!attribute created_at
147
142
  #
@@ -33,9 +33,7 @@ module ModernTreasury
33
33
  #
34
34
  # @return [Array<ModernTreasury::Models::InternalAccounts::BalanceReportCreateParams::Balance>]
35
35
  required :balances,
36
- -> {
37
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccounts::BalanceReportCreateParams::Balance]
38
- }
36
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::InternalAccounts::BalanceReportCreateParams::Balance] }
39
37
 
40
38
  # @!method initialize(as_of_date:, as_of_time:, balance_report_type:, balances:, request_options: {})
41
39
  # Some parameter documentations has been truncated, see
@@ -81,9 +79,7 @@ module ModernTreasury
81
79
  #
82
80
  # @return [Symbol, ModernTreasury::Models::InternalAccounts::BalanceReportCreateParams::Balance::BalanceType]
83
81
  required :balance_type,
84
- enum: -> {
85
- ModernTreasury::InternalAccounts::BalanceReportCreateParams::Balance::BalanceType
86
- }
82
+ enum: -> { ModernTreasury::InternalAccounts::BalanceReportCreateParams::Balance::BalanceType }
87
83
 
88
84
  # @!attribute vendor_code
89
85
  # The code used by the bank when reporting this specific balance.
@@ -28,9 +28,7 @@ module ModernTreasury
28
28
  # @return [Array(String, Symbol)]
29
29
 
30
30
  define_sorbet_constant!(:Variants) do
31
- T.type_alias do
32
- T.any(String, ModernTreasury::InternalAccounts::BalanceReportRetrieveParams::ID::TaggedSymbol)
33
- end
31
+ T.type_alias { T.any(String, ModernTreasury::InternalAccounts::BalanceReportRetrieveParams::ID::TaggedSymbol) }
34
32
  end
35
33
 
36
34
  # @!group
@@ -11,10 +11,7 @@ module ModernTreasury
11
11
  # Describes the condition that must be satisfied for the monitor to be triggered.
12
12
  #
13
13
  # @return [ModernTreasury::Models::LedgerAccountBalanceMonitorCreateParams::AlertCondition]
14
- required :alert_condition,
15
- -> {
16
- ModernTreasury::LedgerAccountBalanceMonitorCreateParams::AlertCondition
17
- }
14
+ required :alert_condition, -> { ModernTreasury::LedgerAccountBalanceMonitorCreateParams::AlertCondition }
18
15
 
19
16
  # @!attribute ledger_account_id
20
17
  # The ledger account associated with this balance monitor.
@@ -24,10 +24,7 @@ module ModernTreasury
24
24
  # filter by balance amount.
25
25
  #
26
26
  # @return [ModernTreasury::Models::LedgerAccountListParams::AvailableBalanceAmount, nil]
27
- optional :available_balance_amount,
28
- -> {
29
- ModernTreasury::LedgerAccountListParams::AvailableBalanceAmount
30
- }
27
+ optional :available_balance_amount, -> { ModernTreasury::LedgerAccountListParams::AvailableBalanceAmount }
31
28
 
32
29
  # @!attribute balances
33
30
  # Use `balances[effective_at_lower_bound]` and
@@ -50,8 +50,8 @@ module ModernTreasury
50
50
  # be included in the ledger account settlement. The default value is the
51
51
  # created_at timestamp of the ledger account settlement.
52
52
  #
53
- # @return [Time]
54
- required :effective_at_upper_bound, Time
53
+ # @return [Time, nil]
54
+ required :effective_at_upper_bound, Time, nil?: true
55
55
 
56
56
  # @!attribute ledger_id
57
57
  # The id of the ledger that this ledger account settlement belongs to.
@@ -127,7 +127,7 @@ module ModernTreasury
127
127
  #
128
128
  # @param description [String, nil] The description of the ledger account settlement.
129
129
  #
130
- # @param effective_at_upper_bound [Time] The exclusive upper bound of the effective_at timestamp of the ledger entries to
130
+ # @param effective_at_upper_bound [Time, nil] The exclusive upper bound of the effective_at timestamp of the ledger entries to
131
131
  #
132
132
  # @param ledger_id [String] The id of the ledger that this ledger account settlement belongs to.
133
133
  #
@@ -19,6 +19,12 @@ module ModernTreasury
19
19
  # @return [String, nil]
20
20
  optional :after_cursor, String, nil?: true
21
21
 
22
+ # @!attribute amount
23
+ # Use `gt` (>), `gte` (>=), `lt` (<), `lte` (<=), or `eq` (=) to filter by amount.
24
+ #
25
+ # @return [ModernTreasury::Models::LedgerEntryListParams::Amount, nil]
26
+ optional :amount, -> { ModernTreasury::LedgerEntryListParams::Amount }
27
+
22
28
  # @!attribute as_of_lock_version
23
29
  # Shows all ledger entries that were present on a ledger account at a particular
24
30
  # `lock_version`. You must also specify `ledger_account_id`.
@@ -133,9 +139,7 @@ module ModernTreasury
133
139
  #
134
140
  # @return [Array<Symbol, ModernTreasury::Models::LedgerEntryListParams::Status>, nil]
135
141
  optional :status,
136
- -> {
137
- ModernTreasury::Internal::Type::ArrayOf[enum: ModernTreasury::LedgerEntryListParams::Status]
138
- }
142
+ -> { ModernTreasury::Internal::Type::ArrayOf[enum: ModernTreasury::LedgerEntryListParams::Status] }
139
143
 
140
144
  # @!attribute updated_at
141
145
  # Use `gt` (>), `gte` (>=), `lt` (<), `lte` (<=), or `eq` (=) to filter by the
@@ -145,7 +149,7 @@ module ModernTreasury
145
149
  # @return [Hash{Symbol=>Time}, nil]
146
150
  optional :updated_at, ModernTreasury::Internal::Type::HashOf[Time]
147
151
 
148
- # @!method initialize(id: nil, after_cursor: nil, as_of_lock_version: nil, direction: nil, effective_at: nil, effective_date: nil, ledger_account_category_id: nil, ledger_account_id: nil, ledger_account_lock_version: nil, ledger_account_payout_id: nil, ledger_account_settlement_id: nil, ledger_account_statement_id: nil, ledger_transaction_id: nil, metadata: nil, order_by: nil, per_page: nil, show_balances: nil, show_deleted: nil, status: nil, updated_at: nil, request_options: {})
152
+ # @!method initialize(id: nil, after_cursor: nil, amount: nil, as_of_lock_version: nil, direction: nil, effective_at: nil, effective_date: nil, ledger_account_category_id: nil, ledger_account_id: nil, ledger_account_lock_version: nil, ledger_account_payout_id: nil, ledger_account_settlement_id: nil, ledger_account_statement_id: nil, ledger_transaction_id: nil, metadata: nil, order_by: nil, per_page: nil, show_balances: nil, show_deleted: nil, status: nil, updated_at: nil, request_options: {})
149
153
  # Some parameter documentations has been truncated, see
150
154
  # {ModernTreasury::Models::LedgerEntryListParams} for more details.
151
155
  #
@@ -153,6 +157,8 @@ module ModernTreasury
153
157
  #
154
158
  # @param after_cursor [String, nil]
155
159
  #
160
+ # @param amount [ModernTreasury::Models::LedgerEntryListParams::Amount] Use `gt` (>), `gte` (>=), `lt` (<), `lte` (<=), or `eq` (=) to filter by amount.
161
+ #
156
162
  # @param as_of_lock_version [Integer] Shows all ledger entries that were present on a ledger account at a particular `
157
163
  #
158
164
  # @param direction [Symbol, ModernTreasury::Models::TransactionDirection] If true, response will include ledger entries that were deleted. When you update
@@ -191,6 +197,42 @@ module ModernTreasury
191
197
  #
192
198
  # @param request_options [ModernTreasury::RequestOptions, Hash{Symbol=>Object}]
193
199
 
200
+ class Amount < ModernTreasury::Internal::Type::BaseModel
201
+ # @!attribute eq
202
+ #
203
+ # @return [Integer, nil]
204
+ optional :eq, Integer
205
+
206
+ # @!attribute gt
207
+ #
208
+ # @return [Integer, nil]
209
+ optional :gt, Integer
210
+
211
+ # @!attribute gte
212
+ #
213
+ # @return [Integer, nil]
214
+ optional :gte, Integer
215
+
216
+ # @!attribute lt
217
+ #
218
+ # @return [Integer, nil]
219
+ optional :lt, Integer
220
+
221
+ # @!attribute lte
222
+ #
223
+ # @return [Integer, nil]
224
+ optional :lte, Integer
225
+
226
+ # @!method initialize(eq: nil, gt: nil, gte: nil, lt: nil, lte: nil)
227
+ # Use `gt` (>), `gte` (>=), `lt` (<), `lte` (<=), or `eq` (=) to filter by amount.
228
+ #
229
+ # @param eq [Integer]
230
+ # @param gt [Integer]
231
+ # @param gte [Integer]
232
+ # @param lt [Integer]
233
+ # @param lte [Integer]
234
+ end
235
+
194
236
  class OrderBy < ModernTreasury::Internal::Type::BaseModel
195
237
  # @!attribute created_at
196
238
  #
@@ -14,9 +14,7 @@ module ModernTreasury
14
14
  #
15
15
  # @return [Array<ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry>]
16
16
  required :posted_ledger_entries,
17
- -> {
18
- ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry]
19
- }
17
+ -> { ModernTreasury::Internal::Type::ArrayOf[ModernTreasury::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry] }
20
18
 
21
19
  # @!attribute description
22
20
  # An optional free-form description for the posted ledger transaction. Maximum of
@@ -70,9 +68,7 @@ module ModernTreasury
70
68
  #
71
69
  # @return [Symbol, ModernTreasury::Models::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction]
72
70
  required :direction,
73
- enum: -> {
74
- ModernTreasury::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction
75
- }
71
+ enum: -> { ModernTreasury::LedgerTransactionCreatePartialPostParams::PostedLedgerEntry::Direction }
76
72
 
77
73
  # @!attribute ledger_account_id
78
74
  # The ledger account that this ledger entry is associated with.