lithic 0.20.0 → 0.21.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 (142) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +25 -0
  3. data/README.md +1 -1
  4. data/lib/lithic/models/account_activity_list_params.rb +1 -0
  5. data/lib/lithic/models/account_activity_list_response.rb +1 -0
  6. data/lib/lithic/models/account_activity_retrieve_transaction_response.rb +1 -0
  7. data/lib/lithic/models/auth_rules/auth_rule.rb +5 -0
  8. data/lib/lithic/models/auth_rules/report_stats.rb +1 -0
  9. data/lib/lithic/models/auth_rules/v2_create_params.rb +15 -0
  10. data/lib/lithic/models/auth_rules/v2_list_results_response.rb +1 -0
  11. data/lib/lithic/models/blockchain_recipient_retrieve_params.rb +20 -0
  12. data/lib/lithic/models/card_pin_updated_webhook_event.rb +87 -0
  13. data/lib/lithic/models/event.rb +5 -0
  14. data/lib/lithic/models/event_list_params.rb +3 -0
  15. data/lib/lithic/models/event_subscription.rb +3 -0
  16. data/lib/lithic/models/events/subscription_create_params.rb +3 -0
  17. data/lib/lithic/models/events/subscription_send_simulated_example_params.rb +1 -0
  18. data/lib/lithic/models/events/subscription_update_params.rb +3 -0
  19. data/lib/lithic/models/external_payment.rb +6 -0
  20. data/lib/lithic/models/external_payment_create_params.rb +1 -0
  21. data/lib/lithic/models/external_payment_list_params.rb +1 -0
  22. data/lib/lithic/models/financial_accounts/installment_plan.rb +311 -0
  23. data/lib/lithic/models/financial_accounts/installment_plan_list_params.rb +75 -0
  24. data/lib/lithic/models/financial_accounts/installment_plan_retrieve_params.rb +32 -0
  25. data/lib/lithic/models/financial_accounts/open_to_buy.rb +36 -0
  26. data/lib/lithic/models/financial_accounts/open_to_buy_retrieve_params.rb +22 -0
  27. data/lib/lithic/models/financial_accounts/open_to_buy_summary.rb +46 -0
  28. data/lib/lithic/models/financial_accounts/statements/statement_line_items.rb +10 -0
  29. data/lib/lithic/models/financial_accounts/transaction_category_balances.rb +34 -0
  30. data/lib/lithic/models/financial_event.rb +9 -0
  31. data/lib/lithic/models/management_operation_create_params.rb +4 -0
  32. data/lib/lithic/models/management_operation_transaction.rb +4 -0
  33. data/lib/lithic/models/parsed_webhook_event.rb +3 -1
  34. data/lib/lithic/models/payment.rb +1 -0
  35. data/lib/lithic/models/payment_create_stablecoin_params.rb +99 -0
  36. data/lib/lithic/models/payment_create_stablecoin_response.rb +19 -0
  37. data/lib/lithic/models/payment_list_params.rb +1 -0
  38. data/lib/lithic/models/payment_retry_params.rb +28 -1
  39. data/lib/lithic/models/payment_simulate_action_params.rb +1 -0
  40. data/lib/lithic/models/three_ds_authentication.rb +126 -1
  41. data/lib/lithic/models/transaction.rb +2 -0
  42. data/lib/lithic/models.rb +6 -0
  43. data/lib/lithic/resources/blockchain_recipients.rb +23 -0
  44. data/lib/lithic/resources/cards.rb +4 -2
  45. data/lib/lithic/resources/financial_accounts/installment_plans.rb +82 -0
  46. data/lib/lithic/resources/financial_accounts/open_to_buy.rb +48 -0
  47. data/lib/lithic/resources/financial_accounts.rb +8 -0
  48. data/lib/lithic/resources/payments.rb +71 -3
  49. data/lib/lithic/version.rb +1 -1
  50. data/lib/lithic.rb +13 -0
  51. data/rbi/lithic/models/account_activity_list_params.rbi +5 -0
  52. data/rbi/lithic/models/account_activity_list_response.rbi +5 -0
  53. data/rbi/lithic/models/account_activity_retrieve_transaction_response.rbi +5 -0
  54. data/rbi/lithic/models/auth_rules/auth_rule.rbi +7 -0
  55. data/rbi/lithic/models/auth_rules/report_stats.rbi +5 -0
  56. data/rbi/lithic/models/auth_rules/v2_create_params.rbi +33 -0
  57. data/rbi/lithic/models/auth_rules/v2_list_results_response.rbi +5 -0
  58. data/rbi/lithic/models/blockchain_recipient_retrieve_params.rbi +41 -0
  59. data/rbi/lithic/models/card_pin_updated_webhook_event.rbi +166 -0
  60. data/rbi/lithic/models/event.rbi +8 -0
  61. data/rbi/lithic/models/event_list_params.rbi +7 -0
  62. data/rbi/lithic/models/event_subscription.rbi +7 -0
  63. data/rbi/lithic/models/events/subscription_create_params.rbi +7 -0
  64. data/rbi/lithic/models/events/subscription_send_simulated_example_params.rbi +5 -0
  65. data/rbi/lithic/models/events/subscription_update_params.rbi +7 -0
  66. data/rbi/lithic/models/external_payment.rbi +30 -0
  67. data/rbi/lithic/models/external_payment_create_params.rbi +5 -0
  68. data/rbi/lithic/models/external_payment_list_params.rbi +5 -0
  69. data/rbi/lithic/models/financial_accounts/installment_plan.rbi +528 -0
  70. data/rbi/lithic/models/financial_accounts/installment_plan_list_params.rbi +155 -0
  71. data/rbi/lithic/models/financial_accounts/installment_plan_retrieve_params.rbi +56 -0
  72. data/rbi/lithic/models/financial_accounts/open_to_buy.rbi +64 -0
  73. data/rbi/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbi +43 -0
  74. data/rbi/lithic/models/financial_accounts/open_to_buy_summary.rbi +73 -0
  75. data/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi +50 -0
  76. data/rbi/lithic/models/financial_accounts/transaction_category_balances.rbi +81 -0
  77. data/rbi/lithic/models/financial_event.rbi +35 -0
  78. data/rbi/lithic/models/management_operation_create_params.rbi +20 -0
  79. data/rbi/lithic/models/management_operation_transaction.rbi +20 -0
  80. data/rbi/lithic/models/parsed_webhook_event.rbi +1 -0
  81. data/rbi/lithic/models/payment.rbi +2 -0
  82. data/rbi/lithic/models/payment_create_stablecoin_params.rbi +162 -0
  83. data/rbi/lithic/models/payment_create_stablecoin_response.rbi +34 -0
  84. data/rbi/lithic/models/payment_list_params.rbi +2 -0
  85. data/rbi/lithic/models/payment_retry_params.rbi +47 -2
  86. data/rbi/lithic/models/payment_simulate_action_params.rbi +5 -0
  87. data/rbi/lithic/models/three_ds_authentication.rbi +292 -0
  88. data/rbi/lithic/models/transaction.rbi +10 -0
  89. data/rbi/lithic/models.rbi +7 -0
  90. data/rbi/lithic/resources/blockchain_recipients.rbi +14 -0
  91. data/rbi/lithic/resources/cards.rbi +4 -2
  92. data/rbi/lithic/resources/financial_accounts/installment_plans.rbi +66 -0
  93. data/rbi/lithic/resources/financial_accounts/open_to_buy.rbi +40 -0
  94. data/rbi/lithic/resources/financial_accounts.rbi +6 -0
  95. data/rbi/lithic/resources/payments.rbi +68 -2
  96. data/rbi/lithic/resources/webhooks.rbi +1 -0
  97. data/sig/lithic/models/account_activity_list_params.rbs +2 -0
  98. data/sig/lithic/models/account_activity_list_response.rbs +2 -0
  99. data/sig/lithic/models/account_activity_retrieve_transaction_response.rbs +2 -0
  100. data/sig/lithic/models/auth_rules/auth_rule.rbs +2 -0
  101. data/sig/lithic/models/auth_rules/report_stats.rbs +2 -0
  102. data/sig/lithic/models/auth_rules/v2_create_params.rbs +6 -0
  103. data/sig/lithic/models/auth_rules/v2_list_results_response.rbs +2 -0
  104. data/sig/lithic/models/blockchain_recipient_retrieve_params.rbs +24 -0
  105. data/sig/lithic/models/card_pin_updated_webhook_event.rbs +60 -0
  106. data/sig/lithic/models/event.rbs +2 -0
  107. data/sig/lithic/models/event_list_params.rbs +2 -0
  108. data/sig/lithic/models/event_subscription.rbs +2 -0
  109. data/sig/lithic/models/events/subscription_create_params.rbs +2 -0
  110. data/sig/lithic/models/events/subscription_send_simulated_example_params.rbs +2 -0
  111. data/sig/lithic/models/events/subscription_update_params.rbs +2 -0
  112. data/sig/lithic/models/external_payment.rbs +12 -0
  113. data/sig/lithic/models/external_payment_create_params.rbs +2 -0
  114. data/sig/lithic/models/external_payment_list_params.rbs +2 -0
  115. data/sig/lithic/models/financial_accounts/installment_plan.rbs +227 -0
  116. data/sig/lithic/models/financial_accounts/installment_plan_list_params.rbs +69 -0
  117. data/sig/lithic/models/financial_accounts/installment_plan_retrieve_params.rbs +30 -0
  118. data/sig/lithic/models/financial_accounts/open_to_buy.rbs +27 -0
  119. data/sig/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbs +26 -0
  120. data/sig/lithic/models/financial_accounts/open_to_buy_summary.rbs +32 -0
  121. data/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs +20 -0
  122. data/sig/lithic/models/financial_accounts/transaction_category_balances.rbs +32 -0
  123. data/sig/lithic/models/financial_event.rbs +18 -0
  124. data/sig/lithic/models/management_operation_create_params.rbs +8 -0
  125. data/sig/lithic/models/management_operation_transaction.rbs +8 -0
  126. data/sig/lithic/models/parsed_webhook_event.rbs +1 -0
  127. data/sig/lithic/models/payment.rbs +2 -0
  128. data/sig/lithic/models/payment_create_stablecoin_params.rbs +84 -0
  129. data/sig/lithic/models/payment_create_stablecoin_response.rbs +15 -0
  130. data/sig/lithic/models/payment_list_params.rbs +2 -1
  131. data/sig/lithic/models/payment_retry_params.rbs +24 -1
  132. data/sig/lithic/models/payment_simulate_action_params.rbs +2 -0
  133. data/sig/lithic/models/three_ds_authentication.rbs +77 -0
  134. data/sig/lithic/models/transaction.rbs +4 -0
  135. data/sig/lithic/models.rbs +6 -0
  136. data/sig/lithic/resources/blockchain_recipients.rbs +5 -0
  137. data/sig/lithic/resources/financial_accounts/installment_plans.rbs +24 -0
  138. data/sig/lithic/resources/financial_accounts/open_to_buy.rbs +14 -0
  139. data/sig/lithic/resources/financial_accounts.rbs +4 -0
  140. data/sig/lithic/resources/payments.rbs +12 -0
  141. data/sig/lithic/resources/webhooks.rbs +1 -0
  142. metadata +41 -2
@@ -0,0 +1,311 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Lithic
4
+ module Models
5
+ module FinancialAccounts
6
+ # @see Lithic::Resources::FinancialAccounts::InstallmentPlans#retrieve
7
+ class InstallmentPlan < Lithic::Internal::Type::BaseModel
8
+ # @!attribute token
9
+ # Globally unique identifier for an installment plan
10
+ #
11
+ # @return [String]
12
+ required :token, String
13
+
14
+ # @!attribute closed_at
15
+ # Date the plan was paid off or cancelled, or null while it is still open
16
+ #
17
+ # @return [Date, nil]
18
+ required :closed_at, Date, nil?: true
19
+
20
+ # @!attribute created
21
+ # Timestamp of when the installment plan was created
22
+ #
23
+ # @return [Time]
24
+ required :created, Time
25
+
26
+ # @!attribute fee_amount
27
+ # Enrollment fee charged when the plan was created in cents
28
+ #
29
+ # @return [Integer]
30
+ required :fee_amount, Integer
31
+
32
+ # @!attribute financial_account_token
33
+ # Globally unique identifier for a financial account
34
+ #
35
+ # @return [String]
36
+ required :financial_account_token, String
37
+
38
+ # @!attribute installment_plan_total
39
+ # Total owed on the plan in cents, the principal amount plus the enrollment fee
40
+ #
41
+ # @return [Integer]
42
+ required :installment_plan_total, Integer
43
+
44
+ # @!attribute installments
45
+ # Installments that make up the plan, oldest first
46
+ #
47
+ # @return [Array<Lithic::Models::FinancialAccounts::InstallmentPlan::Installment>]
48
+ required :installments,
49
+ -> { Lithic::Internal::Type::ArrayOf[Lithic::FinancialAccounts::InstallmentPlan::Installment] }
50
+
51
+ # @!attribute installments_outstanding
52
+ # Number of installments that still carry a balance
53
+ #
54
+ # @return [Integer]
55
+ required :installments_outstanding, Integer
56
+
57
+ # @!attribute installments_paid
58
+ # Number of installments that have been paid off
59
+ #
60
+ # @return [Integer]
61
+ required :installments_paid, Integer
62
+
63
+ # @!attribute num_installments
64
+ # Number of installments the plan is broken into
65
+ #
66
+ # @return [Integer]
67
+ required :num_installments, Integer
68
+
69
+ # @!attribute principal_amount
70
+ # Balance the plan was opened on in cents, excluding the enrollment fee
71
+ #
72
+ # @return [Integer]
73
+ required :principal_amount, Integer
74
+
75
+ # @!attribute source_amounts
76
+ # Balance the plan was opened on, broken out by category, or null if it was not
77
+ # recorded
78
+ #
79
+ # @return [Lithic::Models::FinancialAccounts::TransactionCategoryBalances, nil]
80
+ required :source_amounts, -> { Lithic::FinancialAccounts::TransactionCategoryBalances }, nil?: true
81
+
82
+ # @!attribute source_id
83
+ # Identifier of the record the plan was opened from, such as the closing statement
84
+ # for an unpaid balance
85
+ #
86
+ # @return [String]
87
+ required :source_id, String
88
+
89
+ # @!attribute source_type
90
+ #
91
+ # @return [Symbol, Lithic::Models::FinancialAccounts::InstallmentPlan::SourceType]
92
+ required :source_type, enum: -> { Lithic::FinancialAccounts::InstallmentPlan::SourceType }
93
+
94
+ # @!attribute start_date
95
+ # Date the plan was created
96
+ #
97
+ # @return [Date]
98
+ required :start_date, Date
99
+
100
+ # @!attribute state
101
+ # State of the installment plan. A plan is REBUILD_IN_PROGRESS while its loan
102
+ # tapes are being rebuilt, during which its payment totals are being recomputed
103
+ # and should not be treated as final
104
+ #
105
+ # @return [Symbol, Lithic::Models::FinancialAccounts::InstallmentPlan::State]
106
+ required :state, enum: -> { Lithic::FinancialAccounts::InstallmentPlan::State }
107
+
108
+ # @!attribute total_paid
109
+ # Amount paid towards the plan to date in cents
110
+ #
111
+ # @return [Integer]
112
+ required :total_paid, Integer
113
+
114
+ # @!attribute updated
115
+ # Timestamp of when the installment plan was updated
116
+ #
117
+ # @return [Time]
118
+ required :updated, Time
119
+
120
+ # @!method initialize(token:, closed_at:, created:, fee_amount:, financial_account_token:, installment_plan_total:, installments:, installments_outstanding:, installments_paid:, num_installments:, principal_amount:, source_amounts:, source_id:, source_type:, start_date:, state:, total_paid:, updated:)
121
+ # Some parameter documentations has been truncated, see
122
+ # {Lithic::Models::FinancialAccounts::InstallmentPlan} for more details.
123
+ #
124
+ # @param token [String] Globally unique identifier for an installment plan
125
+ #
126
+ # @param closed_at [Date, nil] Date the plan was paid off or cancelled, or null while it is still open
127
+ #
128
+ # @param created [Time] Timestamp of when the installment plan was created
129
+ #
130
+ # @param fee_amount [Integer] Enrollment fee charged when the plan was created in cents
131
+ #
132
+ # @param financial_account_token [String] Globally unique identifier for a financial account
133
+ #
134
+ # @param installment_plan_total [Integer] Total owed on the plan in cents, the principal amount plus the enrollment fee
135
+ #
136
+ # @param installments [Array<Lithic::Models::FinancialAccounts::InstallmentPlan::Installment>] Installments that make up the plan, oldest first
137
+ #
138
+ # @param installments_outstanding [Integer] Number of installments that still carry a balance
139
+ #
140
+ # @param installments_paid [Integer] Number of installments that have been paid off
141
+ #
142
+ # @param num_installments [Integer] Number of installments the plan is broken into
143
+ #
144
+ # @param principal_amount [Integer] Balance the plan was opened on in cents, excluding the enrollment fee
145
+ #
146
+ # @param source_amounts [Lithic::Models::FinancialAccounts::TransactionCategoryBalances, nil] Balance the plan was opened on, broken out by category, or null if it was not re
147
+ #
148
+ # @param source_id [String] Identifier of the record the plan was opened from, such as the closing statement
149
+ #
150
+ # @param source_type [Symbol, Lithic::Models::FinancialAccounts::InstallmentPlan::SourceType]
151
+ #
152
+ # @param start_date [Date] Date the plan was created
153
+ #
154
+ # @param state [Symbol, Lithic::Models::FinancialAccounts::InstallmentPlan::State] State of the installment plan. A plan is REBUILD_IN_PROGRESS while its loan tape
155
+ #
156
+ # @param total_paid [Integer] Amount paid towards the plan to date in cents
157
+ #
158
+ # @param updated [Time] Timestamp of when the installment plan was updated
159
+
160
+ class Installment < Lithic::Internal::Type::BaseModel
161
+ # @!attribute amount_due
162
+ # Amount the installment was opened for in cents
163
+ #
164
+ # @return [Integer]
165
+ required :amount_due, Integer
166
+
167
+ # @!attribute amount_due_details
168
+ #
169
+ # @return [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
170
+ required :amount_due_details, -> { Lithic::FinancialAccounts::TransactionCategoryBalances }
171
+
172
+ # @!attribute amount_outstanding
173
+ # Amount still owed on the installment in cents
174
+ #
175
+ # @return [Integer]
176
+ required :amount_outstanding, Integer
177
+
178
+ # @!attribute amount_outstanding_details
179
+ #
180
+ # @return [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
181
+ required :amount_outstanding_details, -> { Lithic::FinancialAccounts::TransactionCategoryBalances }
182
+
183
+ # @!attribute amount_paid
184
+ # Amount paid towards the installment in cents
185
+ #
186
+ # @return [Integer]
187
+ required :amount_paid, Integer
188
+
189
+ # @!attribute amount_paid_details
190
+ #
191
+ # @return [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
192
+ required :amount_paid_details, -> { Lithic::FinancialAccounts::TransactionCategoryBalances }
193
+
194
+ # @!attribute date_assessed
195
+ # Date the installment was actually assessed onto the account, or null if it has
196
+ # not been assessed yet
197
+ #
198
+ # @return [Date, nil]
199
+ required :date_assessed, Date, nil?: true
200
+
201
+ # @!attribute due_date
202
+ # Date the installment is scheduled to be assessed onto the account
203
+ #
204
+ # @return [Date]
205
+ required :due_date, Date
206
+
207
+ # @!attribute installment_num
208
+ # Position of this installment within the plan, starting at 0
209
+ #
210
+ # @return [Integer]
211
+ required :installment_num, Integer
212
+
213
+ # @!attribute payment_due_date
214
+ # Date the installment must be paid by before it is considered past due
215
+ #
216
+ # @return [Date]
217
+ required :payment_due_date, Date
218
+
219
+ # @!attribute payments
220
+ # Payments applied to this installment, oldest first
221
+ #
222
+ # @return [Array<Lithic::Models::FinancialAccounts::InstallmentPlan::Installment::Payment>]
223
+ required :payments,
224
+ -> { Lithic::Internal::Type::ArrayOf[Lithic::FinancialAccounts::InstallmentPlan::Installment::Payment] }
225
+
226
+ # @!method initialize(amount_due:, amount_due_details:, amount_outstanding:, amount_outstanding_details:, amount_paid:, amount_paid_details:, date_assessed:, due_date:, installment_num:, payment_due_date:, payments:)
227
+ # Some parameter documentations has been truncated, see
228
+ # {Lithic::Models::FinancialAccounts::InstallmentPlan::Installment} for more
229
+ # details.
230
+ #
231
+ # @param amount_due [Integer] Amount the installment was opened for in cents
232
+ #
233
+ # @param amount_due_details [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
234
+ #
235
+ # @param amount_outstanding [Integer] Amount still owed on the installment in cents
236
+ #
237
+ # @param amount_outstanding_details [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
238
+ #
239
+ # @param amount_paid [Integer] Amount paid towards the installment in cents
240
+ #
241
+ # @param amount_paid_details [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
242
+ #
243
+ # @param date_assessed [Date, nil] Date the installment was actually assessed onto the account, or null if it has n
244
+ #
245
+ # @param due_date [Date] Date the installment is scheduled to be assessed onto the account
246
+ #
247
+ # @param installment_num [Integer] Position of this installment within the plan, starting at 0
248
+ #
249
+ # @param payment_due_date [Date] Date the installment must be paid by before it is considered past due
250
+ #
251
+ # @param payments [Array<Lithic::Models::FinancialAccounts::InstallmentPlan::Installment::Payment>] Payments applied to this installment, oldest first
252
+
253
+ class Payment < Lithic::Internal::Type::BaseModel
254
+ # @!attribute amount
255
+ # Amount applied to the installment in cents
256
+ #
257
+ # @return [Integer]
258
+ required :amount, Integer
259
+
260
+ # @!attribute amount_details
261
+ #
262
+ # @return [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
263
+ required :amount_details, -> { Lithic::FinancialAccounts::TransactionCategoryBalances }
264
+
265
+ # @!attribute date
266
+ # Date the payment was applied to the installment
267
+ #
268
+ # @return [Date]
269
+ required :date, Date
270
+
271
+ # @!method initialize(amount:, amount_details:, date:)
272
+ # @param amount [Integer] Amount applied to the installment in cents
273
+ #
274
+ # @param amount_details [Lithic::Models::FinancialAccounts::TransactionCategoryBalances]
275
+ #
276
+ # @param date [Date] Date the payment was applied to the installment
277
+ end
278
+ end
279
+
280
+ # @see Lithic::Models::FinancialAccounts::InstallmentPlan#source_type
281
+ module SourceType
282
+ extend Lithic::Internal::Type::Enum
283
+
284
+ UNPAID_BALANCE = :UNPAID_BALANCE
285
+ TRANSACTION = :TRANSACTION
286
+
287
+ # @!method self.values
288
+ # @return [Array<Symbol>]
289
+ end
290
+
291
+ # State of the installment plan. A plan is REBUILD_IN_PROGRESS while its loan
292
+ # tapes are being rebuilt, during which its payment totals are being recomputed
293
+ # and should not be treated as final
294
+ #
295
+ # @see Lithic::Models::FinancialAccounts::InstallmentPlan#state
296
+ module State
297
+ extend Lithic::Internal::Type::Enum
298
+
299
+ PENDING = :PENDING
300
+ ACTIVE = :ACTIVE
301
+ REBUILD_IN_PROGRESS = :REBUILD_IN_PROGRESS
302
+ FULLY_PAID = :FULLY_PAID
303
+ CANCELLED = :CANCELLED
304
+
305
+ # @!method self.values
306
+ # @return [Array<Symbol>]
307
+ end
308
+ end
309
+ end
310
+ end
311
+ end
@@ -0,0 +1,75 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Lithic
4
+ module Models
5
+ module FinancialAccounts
6
+ # @see Lithic::Resources::FinancialAccounts::InstallmentPlans#list
7
+ class InstallmentPlanListParams < Lithic::Internal::Type::BaseModel
8
+ extend Lithic::Internal::Type::RequestParameters::Converter
9
+ include Lithic::Internal::Type::RequestParameters
10
+
11
+ # @!attribute financial_account_token
12
+ # Globally unique identifier for financial account.
13
+ #
14
+ # @return [String]
15
+ required :financial_account_token, String
16
+
17
+ # @!attribute ending_before
18
+ # A cursor representing an item's token before which a page of results should end.
19
+ # Used to retrieve the previous page of results before this item.
20
+ #
21
+ # @return [String, nil]
22
+ optional :ending_before, String
23
+
24
+ # @!attribute page_size
25
+ # Page size (for pagination).
26
+ #
27
+ # @return [Integer, nil]
28
+ optional :page_size, Integer
29
+
30
+ # @!attribute starting_after
31
+ # A cursor representing an item's token after which a page of results should
32
+ # begin. Used to retrieve the next page of results after this item.
33
+ #
34
+ # @return [String, nil]
35
+ optional :starting_after, String
36
+
37
+ # @!attribute state
38
+ # Only installment plans in this state will be included.
39
+ #
40
+ # @return [Symbol, Lithic::Models::FinancialAccounts::InstallmentPlanListParams::State, nil]
41
+ optional :state, enum: -> { Lithic::FinancialAccounts::InstallmentPlanListParams::State }, nil?: true
42
+
43
+ # @!method initialize(financial_account_token:, ending_before: nil, page_size: nil, starting_after: nil, state: nil, request_options: {})
44
+ # Some parameter documentations has been truncated, see
45
+ # {Lithic::Models::FinancialAccounts::InstallmentPlanListParams} for more details.
46
+ #
47
+ # @param financial_account_token [String] Globally unique identifier for financial account.
48
+ #
49
+ # @param ending_before [String] A cursor representing an item's token before which a page of results should end.
50
+ #
51
+ # @param page_size [Integer] Page size (for pagination).
52
+ #
53
+ # @param starting_after [String] A cursor representing an item's token after which a page of results should begin
54
+ #
55
+ # @param state [Symbol, Lithic::Models::FinancialAccounts::InstallmentPlanListParams::State, nil] Only installment plans in this state will be included.
56
+ #
57
+ # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}]
58
+
59
+ # Only installment plans in this state will be included.
60
+ module State
61
+ extend Lithic::Internal::Type::Enum
62
+
63
+ PENDING = :PENDING
64
+ ACTIVE = :ACTIVE
65
+ REBUILD_IN_PROGRESS = :REBUILD_IN_PROGRESS
66
+ FULLY_PAID = :FULLY_PAID
67
+ CANCELLED = :CANCELLED
68
+
69
+ # @!method self.values
70
+ # @return [Array<Symbol>]
71
+ end
72
+ end
73
+ end
74
+ end
75
+ end
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Lithic
4
+ module Models
5
+ module FinancialAccounts
6
+ # @see Lithic::Resources::FinancialAccounts::InstallmentPlans#retrieve
7
+ class InstallmentPlanRetrieveParams < Lithic::Internal::Type::BaseModel
8
+ extend Lithic::Internal::Type::RequestParameters::Converter
9
+ include Lithic::Internal::Type::RequestParameters
10
+
11
+ # @!attribute financial_account_token
12
+ # Globally unique identifier for financial account.
13
+ #
14
+ # @return [String]
15
+ required :financial_account_token, String
16
+
17
+ # @!attribute installment_plan_token
18
+ # Globally unique identifier for installment plan.
19
+ #
20
+ # @return [String]
21
+ required :installment_plan_token, String
22
+
23
+ # @!method initialize(financial_account_token:, installment_plan_token:, request_options: {})
24
+ # @param financial_account_token [String] Globally unique identifier for financial account.
25
+ #
26
+ # @param installment_plan_token [String] Globally unique identifier for installment plan.
27
+ #
28
+ # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}]
29
+ end
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,36 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Lithic
4
+ module Models
5
+ module FinancialAccounts
6
+ # @see Lithic::Resources::FinancialAccounts::OpenToBuy#retrieve
7
+ class FinancialAccountsOpenToBuy < Lithic::Internal::Type::BaseModel
8
+ # @!attribute open_to_buy
9
+ # Funds available for card spend backed by this Security Account, in the
10
+ # currency's smallest unit (e.g., cents for USD). Equal to the sum of the amounts
11
+ # in `summary`, and reaches zero once outstanding spend has consumed all available
12
+ # funding
13
+ #
14
+ # @return [Integer]
15
+ required :open_to_buy, Integer
16
+
17
+ # @!attribute summary
18
+ # Balances that open to buy is derived from
19
+ #
20
+ # @return [Lithic::Models::FinancialAccounts::OpenToBuySummary]
21
+ required :summary, -> { Lithic::FinancialAccounts::OpenToBuySummary }
22
+
23
+ # @!method initialize(open_to_buy:, summary:)
24
+ # Some parameter documentations has been truncated, see
25
+ # {Lithic::Models::FinancialAccounts::FinancialAccountsOpenToBuy} for more
26
+ # details.
27
+ #
28
+ # Open to Buy
29
+ #
30
+ # @param open_to_buy [Integer] Funds available for card spend backed by this Security Account, in the currency'
31
+ #
32
+ # @param summary [Lithic::Models::FinancialAccounts::OpenToBuySummary] Balances that open to buy is derived from
33
+ end
34
+ end
35
+ end
36
+ end
@@ -0,0 +1,22 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Lithic
4
+ module Models
5
+ module FinancialAccounts
6
+ # @see Lithic::Resources::FinancialAccounts::OpenToBuy#retrieve
7
+ class OpenToBuyRetrieveParams < Lithic::Internal::Type::BaseModel
8
+ extend Lithic::Internal::Type::RequestParameters::Converter
9
+ include Lithic::Internal::Type::RequestParameters
10
+
11
+ # @!attribute financial_account_token
12
+ #
13
+ # @return [String]
14
+ required :financial_account_token, String
15
+
16
+ # @!method initialize(financial_account_token:, request_options: {})
17
+ # @param financial_account_token [String]
18
+ # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}]
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,46 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Lithic
4
+ module Models
5
+ module FinancialAccounts
6
+ class OpenToBuySummary < Lithic::Internal::Type::BaseModel
7
+ # @!attribute security
8
+ # Available balance of the Security Account backing card spend, in the currency's
9
+ # smallest unit (e.g., cents for USD)
10
+ #
11
+ # @return [Integer]
12
+ required :security, Integer
13
+
14
+ # @!attribute settled_funds
15
+ # Funding that has moved out of the Security Account to cover card spend Lithic
16
+ # has already paid out to the networks, in the currency's smallest unit (e.g.,
17
+ # cents for USD). Open to buy counts it alongside `security`, and it clears once
18
+ # collected from your business clients. Only Commercial Charge tracks this
19
+ # separately, so this is `null` for every other program setup
20
+ #
21
+ # @return [Integer, nil]
22
+ required :settled_funds, Integer, nil?: true
23
+
24
+ # @!attribute total_outstanding_spend
25
+ # Customer card spend that has not yet been collected, in the currency's smallest
26
+ # unit (e.g., cents for USD). Reported as a negative amount, because it reduces
27
+ # open to buy
28
+ #
29
+ # @return [Integer]
30
+ required :total_outstanding_spend, Integer
31
+
32
+ # @!method initialize(security:, settled_funds:, total_outstanding_spend:)
33
+ # Some parameter documentations has been truncated, see
34
+ # {Lithic::Models::FinancialAccounts::OpenToBuySummary} for more details.
35
+ #
36
+ # Open to Buy Summary
37
+ #
38
+ # @param security [Integer] Available balance of the Security Account backing card spend, in the currency's
39
+ #
40
+ # @param settled_funds [Integer, nil] Funding that has moved out of the Security Account to cover card spend Lithic ha
41
+ #
42
+ # @param total_outstanding_spend [Integer] Customer card spend that has not yet been collected, in the currency's
43
+ end
44
+ end
45
+ end
46
+ end
@@ -162,6 +162,7 @@ module Lithic
162
162
  EXTERNAL_CHECK = :EXTERNAL_CHECK
163
163
  EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW
164
164
  EXTERNAL_RTP = :EXTERNAL_RTP
165
+ EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN
165
166
  EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER
166
167
  EXTERNAL_WIRE = :EXTERNAL_WIRE
167
168
  MANAGEMENT_ADJUSTMENT = :MANAGEMENT_ADJUSTMENT
@@ -234,6 +235,11 @@ module Lithic
234
235
  EXTERNAL_RTP_RELEASED = :EXTERNAL_RTP_RELEASED
235
236
  EXTERNAL_RTP_REVERSED = :EXTERNAL_RTP_REVERSED
236
237
  EXTERNAL_RTP_SETTLED = :EXTERNAL_RTP_SETTLED
238
+ EXTERNAL_STABLECOIN_CANCELED = :EXTERNAL_STABLECOIN_CANCELED
239
+ EXTERNAL_STABLECOIN_INITIATED = :EXTERNAL_STABLECOIN_INITIATED
240
+ EXTERNAL_STABLECOIN_RELEASED = :EXTERNAL_STABLECOIN_RELEASED
241
+ EXTERNAL_STABLECOIN_REVERSED = :EXTERNAL_STABLECOIN_REVERSED
242
+ EXTERNAL_STABLECOIN_SETTLED = :EXTERNAL_STABLECOIN_SETTLED
237
243
  EXTERNAL_TRANSFER_CANCELED = :EXTERNAL_TRANSFER_CANCELED
238
244
  EXTERNAL_TRANSFER_INITIATED = :EXTERNAL_TRANSFER_INITIATED
239
245
  EXTERNAL_TRANSFER_RELEASED = :EXTERNAL_TRANSFER_RELEASED
@@ -244,8 +250,12 @@ module Lithic
244
250
  EXTERNAL_WIRE_RELEASED = :EXTERNAL_WIRE_RELEASED
245
251
  EXTERNAL_WIRE_REVERSED = :EXTERNAL_WIRE_REVERSED
246
252
  EXTERNAL_WIRE_SETTLED = :EXTERNAL_WIRE_SETTLED
253
+ FEE = :FEE
254
+ FEE_REVERSAL = :FEE_REVERSAL
247
255
  FINANCIAL_AUTHORIZATION = :FINANCIAL_AUTHORIZATION
248
256
  FINANCIAL_CREDIT_AUTHORIZATION = :FINANCIAL_CREDIT_AUTHORIZATION
257
+ INSTALLMENT_FEE = :INSTALLMENT_FEE
258
+ INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL
249
259
  INTEREST = :INTEREST
250
260
  INTEREST_REVERSAL = :INTEREST_REVERSAL
251
261
  INTERNAL_ADJUSTMENT = :INTERNAL_ADJUSTMENT
@@ -0,0 +1,34 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Lithic
4
+ module Models
5
+ module FinancialAccounts
6
+ class TransactionCategoryBalances < Lithic::Internal::Type::BaseModel
7
+ # @!attribute balance_transfers
8
+ # Amounts attributable to balance transfers
9
+ #
10
+ # @return [Lithic::Models::FinancialAccounts::CategoryBalances]
11
+ required :balance_transfers, -> { Lithic::FinancialAccounts::CategoryBalances }
12
+
13
+ # @!attribute cash_advances
14
+ # Amounts attributable to cash advances
15
+ #
16
+ # @return [Lithic::Models::FinancialAccounts::CategoryBalances]
17
+ required :cash_advances, -> { Lithic::FinancialAccounts::CategoryBalances }
18
+
19
+ # @!attribute purchases
20
+ # Amounts attributable to purchases
21
+ #
22
+ # @return [Lithic::Models::FinancialAccounts::CategoryBalances]
23
+ required :purchases, -> { Lithic::FinancialAccounts::CategoryBalances }
24
+
25
+ # @!method initialize(balance_transfers:, cash_advances:, purchases:)
26
+ # @param balance_transfers [Lithic::Models::FinancialAccounts::CategoryBalances] Amounts attributable to balance transfers
27
+ #
28
+ # @param cash_advances [Lithic::Models::FinancialAccounts::CategoryBalances] Amounts attributable to cash advances
29
+ #
30
+ # @param purchases [Lithic::Models::FinancialAccounts::CategoryBalances] Amounts attributable to purchases
31
+ end
32
+ end
33
+ end
34
+ end
@@ -121,6 +121,11 @@ module Lithic
121
121
  EXTERNAL_RTP_RELEASED = :EXTERNAL_RTP_RELEASED
122
122
  EXTERNAL_RTP_REVERSED = :EXTERNAL_RTP_REVERSED
123
123
  EXTERNAL_RTP_SETTLED = :EXTERNAL_RTP_SETTLED
124
+ EXTERNAL_STABLECOIN_CANCELED = :EXTERNAL_STABLECOIN_CANCELED
125
+ EXTERNAL_STABLECOIN_INITIATED = :EXTERNAL_STABLECOIN_INITIATED
126
+ EXTERNAL_STABLECOIN_RELEASED = :EXTERNAL_STABLECOIN_RELEASED
127
+ EXTERNAL_STABLECOIN_REVERSED = :EXTERNAL_STABLECOIN_REVERSED
128
+ EXTERNAL_STABLECOIN_SETTLED = :EXTERNAL_STABLECOIN_SETTLED
124
129
  EXTERNAL_TRANSFER_CANCELED = :EXTERNAL_TRANSFER_CANCELED
125
130
  EXTERNAL_TRANSFER_INITIATED = :EXTERNAL_TRANSFER_INITIATED
126
131
  EXTERNAL_TRANSFER_RELEASED = :EXTERNAL_TRANSFER_RELEASED
@@ -131,8 +136,12 @@ module Lithic
131
136
  EXTERNAL_WIRE_RELEASED = :EXTERNAL_WIRE_RELEASED
132
137
  EXTERNAL_WIRE_REVERSED = :EXTERNAL_WIRE_REVERSED
133
138
  EXTERNAL_WIRE_SETTLED = :EXTERNAL_WIRE_SETTLED
139
+ FEE = :FEE
140
+ FEE_REVERSAL = :FEE_REVERSAL
134
141
  FINANCIAL_AUTHORIZATION = :FINANCIAL_AUTHORIZATION
135
142
  FINANCIAL_CREDIT_AUTHORIZATION = :FINANCIAL_CREDIT_AUTHORIZATION
143
+ INSTALLMENT_FEE = :INSTALLMENT_FEE
144
+ INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL
136
145
  INTEREST = :INTEREST
137
146
  INTEREST_REVERSAL = :INTEREST_REVERSAL
138
147
  INTERNAL_ADJUSTMENT = :INTERNAL_ADJUSTMENT
@@ -126,6 +126,8 @@ module Lithic
126
126
  CURRENCY_CONVERSION_REVERSAL = :CURRENCY_CONVERSION_REVERSAL
127
127
  INTEREST = :INTEREST
128
128
  INTEREST_REVERSAL = :INTEREST_REVERSAL
129
+ INSTALLMENT_FEE = :INSTALLMENT_FEE
130
+ INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL
129
131
  LATE_PAYMENT = :LATE_PAYMENT
130
132
  LATE_PAYMENT_REVERSAL = :LATE_PAYMENT_REVERSAL
131
133
  BILLING_ERROR = :BILLING_ERROR
@@ -144,6 +146,8 @@ module Lithic
144
146
  QUARTERLY_REVERSAL = :QUARTERLY_REVERSAL
145
147
  MONTHLY = :MONTHLY
146
148
  MONTHLY_REVERSAL = :MONTHLY_REVERSAL
149
+ FEE = :FEE
150
+ FEE_REVERSAL = :FEE_REVERSAL
147
151
 
148
152
  # @!method self.values
149
153
  # @return [Array<Symbol>]
@@ -259,6 +259,8 @@ module Lithic
259
259
  CURRENCY_CONVERSION_REVERSAL = :CURRENCY_CONVERSION_REVERSAL
260
260
  INTEREST = :INTEREST
261
261
  INTEREST_REVERSAL = :INTEREST_REVERSAL
262
+ INSTALLMENT_FEE = :INSTALLMENT_FEE
263
+ INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL
262
264
  LATE_PAYMENT = :LATE_PAYMENT
263
265
  LATE_PAYMENT_REVERSAL = :LATE_PAYMENT_REVERSAL
264
266
  BILLING_ERROR = :BILLING_ERROR
@@ -277,6 +279,8 @@ module Lithic
277
279
  QUARTERLY_REVERSAL = :QUARTERLY_REVERSAL
278
280
  MONTHLY = :MONTHLY
279
281
  MONTHLY_REVERSAL = :MONTHLY_REVERSAL
282
+ FEE = :FEE
283
+ FEE_REVERSAL = :FEE_REVERSAL
280
284
 
281
285
  # @!method self.values
282
286
  # @return [Array<Symbol>]