increase 1.33.0 → 1.35.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 (84) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +16 -0
  3. data/README.md +1 -1
  4. data/lib/increase/client.rb +12 -0
  5. data/lib/increase/models/card_push_transfer.rb +824 -0
  6. data/lib/increase/models/card_push_transfer_approve_params.rb +14 -0
  7. data/lib/increase/models/card_push_transfer_cancel_params.rb +14 -0
  8. data/lib/increase/models/card_push_transfer_create_params.rb +215 -0
  9. data/lib/increase/models/card_push_transfer_list_params.rb +159 -0
  10. data/lib/increase/models/card_push_transfer_retrieve_params.rb +14 -0
  11. data/lib/increase/models/card_token.rb +87 -0
  12. data/lib/increase/models/card_token_capabilities.rb +123 -0
  13. data/lib/increase/models/card_token_capabilities_params.rb +14 -0
  14. data/lib/increase/models/card_token_list_params.rb +83 -0
  15. data/lib/increase/models/card_token_retrieve_params.rb +14 -0
  16. data/lib/increase/models/card_validation.rb +759 -0
  17. data/lib/increase/models/card_validation_create_params.rb +116 -0
  18. data/lib/increase/models/card_validation_list_params.rb +150 -0
  19. data/lib/increase/models/card_validation_retrieve_params.rb +14 -0
  20. data/lib/increase/models/external_account.rb +3 -0
  21. data/lib/increase/models/external_account_create_params.rb +3 -0
  22. data/lib/increase/models/external_account_update_params.rb +3 -0
  23. data/lib/increase/models/simulations/card_token_create_params.rb +140 -0
  24. data/lib/increase/models.rb +30 -0
  25. data/lib/increase/resources/card_push_transfers.rb +167 -0
  26. data/lib/increase/resources/card_tokens.rb +86 -0
  27. data/lib/increase/resources/card_validations.rb +117 -0
  28. data/lib/increase/resources/simulations/card_tokens.rb +46 -0
  29. data/lib/increase/resources/simulations.rb +4 -0
  30. data/lib/increase/version.rb +1 -1
  31. data/lib/increase.rb +20 -0
  32. data/rbi/increase/client.rbi +9 -0
  33. data/rbi/increase/models/card_push_transfer.rbi +1450 -0
  34. data/rbi/increase/models/card_push_transfer_approve_params.rbi +30 -0
  35. data/rbi/increase/models/card_push_transfer_cancel_params.rbi +30 -0
  36. data/rbi/increase/models/card_push_transfer_create_params.rbi +325 -0
  37. data/rbi/increase/models/card_push_transfer_list_params.rbi +329 -0
  38. data/rbi/increase/models/card_push_transfer_retrieve_params.rbi +30 -0
  39. data/rbi/increase/models/card_token.rbi +108 -0
  40. data/rbi/increase/models/card_token_capabilities.rbi +250 -0
  41. data/rbi/increase/models/card_token_capabilities_params.rbi +30 -0
  42. data/rbi/increase/models/card_token_list_params.rbi +146 -0
  43. data/rbi/increase/models/card_token_retrieve_params.rbi +27 -0
  44. data/rbi/increase/models/card_validation.rbi +1438 -0
  45. data/rbi/increase/models/card_validation_create_params.rbi +155 -0
  46. data/rbi/increase/models/card_validation_list_params.rbi +295 -0
  47. data/rbi/increase/models/card_validation_retrieve_params.rbi +30 -0
  48. data/rbi/increase/models/external_account.rbi +7 -0
  49. data/rbi/increase/models/external_account_create_params.rbi +7 -0
  50. data/rbi/increase/models/external_account_update_params.rbi +7 -0
  51. data/rbi/increase/models/simulations/card_token_create_params.rbi +297 -0
  52. data/rbi/increase/models.rbi +32 -0
  53. data/rbi/increase/resources/card_push_transfers.rbi +157 -0
  54. data/rbi/increase/resources/card_tokens.rbi +62 -0
  55. data/rbi/increase/resources/card_validations.rbi +107 -0
  56. data/rbi/increase/resources/simulations/card_tokens.rbi +43 -0
  57. data/rbi/increase/resources/simulations.rbi +3 -0
  58. data/sig/increase/client.rbs +6 -0
  59. data/sig/increase/models/card_push_transfer.rbs +679 -0
  60. data/sig/increase/models/card_push_transfer_approve_params.rbs +15 -0
  61. data/sig/increase/models/card_push_transfer_cancel_params.rbs +15 -0
  62. data/sig/increase/models/card_push_transfer_create_params.rbs +172 -0
  63. data/sig/increase/models/card_push_transfer_list_params.rbs +163 -0
  64. data/sig/increase/models/card_push_transfer_retrieve_params.rbs +15 -0
  65. data/sig/increase/models/card_token.rbs +60 -0
  66. data/sig/increase/models/card_token_capabilities.rbs +104 -0
  67. data/sig/increase/models/card_token_capabilities_params.rbs +15 -0
  68. data/sig/increase/models/card_token_list_params.rbs +79 -0
  69. data/sig/increase/models/card_token_retrieve_params.rbs +15 -0
  70. data/sig/increase/models/card_validation.rbs +634 -0
  71. data/sig/increase/models/card_validation_create_params.rbs +91 -0
  72. data/sig/increase/models/card_validation_list_params.rbs +151 -0
  73. data/sig/increase/models/card_validation_retrieve_params.rbs +15 -0
  74. data/sig/increase/models/external_account.rbs +4 -1
  75. data/sig/increase/models/external_account_create_params.rbs +4 -1
  76. data/sig/increase/models/external_account_update_params.rbs +4 -1
  77. data/sig/increase/models/simulations/card_token_create_params.rbs +129 -0
  78. data/sig/increase/models.rbs +30 -0
  79. data/sig/increase/resources/card_push_transfers.rbs +53 -0
  80. data/sig/increase/resources/card_tokens.rbs +24 -0
  81. data/sig/increase/resources/card_validations.rbs +38 -0
  82. data/sig/increase/resources/simulations/card_tokens.rbs +18 -0
  83. data/sig/increase/resources/simulations.rbs +2 -0
  84. metadata +62 -2
@@ -0,0 +1,155 @@
1
+ # typed: strong
2
+
3
+ module Increase
4
+ module Models
5
+ class CardValidationCreateParams < Increase::Internal::Type::BaseModel
6
+ extend Increase::Internal::Type::RequestParameters::Converter
7
+ include Increase::Internal::Type::RequestParameters
8
+
9
+ OrHash =
10
+ T.type_alias do
11
+ T.any(
12
+ Increase::CardValidationCreateParams,
13
+ Increase::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ # The identifier of the Account from which to send the validation.
18
+ sig { returns(String) }
19
+ attr_accessor :account_id
20
+
21
+ # The Increase identifier for the Card Token that represents the card number
22
+ # you're validating.
23
+ sig { returns(String) }
24
+ attr_accessor :card_token_id
25
+
26
+ # A four-digit code (MCC) identifying the type of business or service provided by
27
+ # the merchant.
28
+ sig { returns(String) }
29
+ attr_accessor :merchant_category_code
30
+
31
+ # The city where the merchant (typically your business) is located.
32
+ sig { returns(String) }
33
+ attr_accessor :merchant_city_name
34
+
35
+ # The merchant name that will appear in the cardholder’s statement descriptor.
36
+ # Typically your business name.
37
+ sig { returns(String) }
38
+ attr_accessor :merchant_name
39
+
40
+ # The postal code for the merchant’s (typically your business’s) location.
41
+ sig { returns(String) }
42
+ attr_accessor :merchant_postal_code
43
+
44
+ # The U.S. state where the merchant (typically your business) is located.
45
+ sig { returns(String) }
46
+ attr_accessor :merchant_state
47
+
48
+ # The cardholder's first name.
49
+ sig { returns(T.nilable(String)) }
50
+ attr_reader :cardholder_first_name
51
+
52
+ sig { params(cardholder_first_name: String).void }
53
+ attr_writer :cardholder_first_name
54
+
55
+ # The cardholder's last name.
56
+ sig { returns(T.nilable(String)) }
57
+ attr_reader :cardholder_last_name
58
+
59
+ sig { params(cardholder_last_name: String).void }
60
+ attr_writer :cardholder_last_name
61
+
62
+ # The cardholder's middle name.
63
+ sig { returns(T.nilable(String)) }
64
+ attr_reader :cardholder_middle_name
65
+
66
+ sig { params(cardholder_middle_name: String).void }
67
+ attr_writer :cardholder_middle_name
68
+
69
+ # The postal code of the cardholder's address.
70
+ sig { returns(T.nilable(String)) }
71
+ attr_reader :cardholder_postal_code
72
+
73
+ sig { params(cardholder_postal_code: String).void }
74
+ attr_writer :cardholder_postal_code
75
+
76
+ # The cardholder's street address.
77
+ sig { returns(T.nilable(String)) }
78
+ attr_reader :cardholder_street_address
79
+
80
+ sig { params(cardholder_street_address: String).void }
81
+ attr_writer :cardholder_street_address
82
+
83
+ sig do
84
+ params(
85
+ account_id: String,
86
+ card_token_id: String,
87
+ merchant_category_code: String,
88
+ merchant_city_name: String,
89
+ merchant_name: String,
90
+ merchant_postal_code: String,
91
+ merchant_state: String,
92
+ cardholder_first_name: String,
93
+ cardholder_last_name: String,
94
+ cardholder_middle_name: String,
95
+ cardholder_postal_code: String,
96
+ cardholder_street_address: String,
97
+ request_options: Increase::RequestOptions::OrHash
98
+ ).returns(T.attached_class)
99
+ end
100
+ def self.new(
101
+ # The identifier of the Account from which to send the validation.
102
+ account_id:,
103
+ # The Increase identifier for the Card Token that represents the card number
104
+ # you're validating.
105
+ card_token_id:,
106
+ # A four-digit code (MCC) identifying the type of business or service provided by
107
+ # the merchant.
108
+ merchant_category_code:,
109
+ # The city where the merchant (typically your business) is located.
110
+ merchant_city_name:,
111
+ # The merchant name that will appear in the cardholder’s statement descriptor.
112
+ # Typically your business name.
113
+ merchant_name:,
114
+ # The postal code for the merchant’s (typically your business’s) location.
115
+ merchant_postal_code:,
116
+ # The U.S. state where the merchant (typically your business) is located.
117
+ merchant_state:,
118
+ # The cardholder's first name.
119
+ cardholder_first_name: nil,
120
+ # The cardholder's last name.
121
+ cardholder_last_name: nil,
122
+ # The cardholder's middle name.
123
+ cardholder_middle_name: nil,
124
+ # The postal code of the cardholder's address.
125
+ cardholder_postal_code: nil,
126
+ # The cardholder's street address.
127
+ cardholder_street_address: nil,
128
+ request_options: {}
129
+ )
130
+ end
131
+
132
+ sig do
133
+ override.returns(
134
+ {
135
+ account_id: String,
136
+ card_token_id: String,
137
+ merchant_category_code: String,
138
+ merchant_city_name: String,
139
+ merchant_name: String,
140
+ merchant_postal_code: String,
141
+ merchant_state: String,
142
+ cardholder_first_name: String,
143
+ cardholder_last_name: String,
144
+ cardholder_middle_name: String,
145
+ cardholder_postal_code: String,
146
+ cardholder_street_address: String,
147
+ request_options: Increase::RequestOptions
148
+ }
149
+ )
150
+ end
151
+ def to_hash
152
+ end
153
+ end
154
+ end
155
+ end
@@ -0,0 +1,295 @@
1
+ # typed: strong
2
+
3
+ module Increase
4
+ module Models
5
+ class CardValidationListParams < Increase::Internal::Type::BaseModel
6
+ extend Increase::Internal::Type::RequestParameters::Converter
7
+ include Increase::Internal::Type::RequestParameters
8
+
9
+ OrHash =
10
+ T.type_alias do
11
+ T.any(Increase::CardValidationListParams, Increase::Internal::AnyHash)
12
+ end
13
+
14
+ # Filter Card Validations to ones belonging to the specified Account.
15
+ sig { returns(T.nilable(String)) }
16
+ attr_reader :account_id
17
+
18
+ sig { params(account_id: String).void }
19
+ attr_writer :account_id
20
+
21
+ sig { returns(T.nilable(Increase::CardValidationListParams::CreatedAt)) }
22
+ attr_reader :created_at
23
+
24
+ sig do
25
+ params(
26
+ created_at: Increase::CardValidationListParams::CreatedAt::OrHash
27
+ ).void
28
+ end
29
+ attr_writer :created_at
30
+
31
+ # Return the page of entries after this one.
32
+ sig { returns(T.nilable(String)) }
33
+ attr_reader :cursor
34
+
35
+ sig { params(cursor: String).void }
36
+ attr_writer :cursor
37
+
38
+ # Filter records to the one with the specified `idempotency_key` you chose for
39
+ # that object. This value is unique across Increase and is used to ensure that a
40
+ # request is only processed once. Learn more about
41
+ # [idempotency](https://increase.com/documentation/idempotency-keys).
42
+ sig { returns(T.nilable(String)) }
43
+ attr_reader :idempotency_key
44
+
45
+ sig { params(idempotency_key: String).void }
46
+ attr_writer :idempotency_key
47
+
48
+ # Limit the size of the list that is returned. The default (and maximum) is 100
49
+ # objects.
50
+ sig { returns(T.nilable(Integer)) }
51
+ attr_reader :limit
52
+
53
+ sig { params(limit: Integer).void }
54
+ attr_writer :limit
55
+
56
+ sig { returns(T.nilable(Increase::CardValidationListParams::Status)) }
57
+ attr_reader :status
58
+
59
+ sig do
60
+ params(status: Increase::CardValidationListParams::Status::OrHash).void
61
+ end
62
+ attr_writer :status
63
+
64
+ sig do
65
+ params(
66
+ account_id: String,
67
+ created_at: Increase::CardValidationListParams::CreatedAt::OrHash,
68
+ cursor: String,
69
+ idempotency_key: String,
70
+ limit: Integer,
71
+ status: Increase::CardValidationListParams::Status::OrHash,
72
+ request_options: Increase::RequestOptions::OrHash
73
+ ).returns(T.attached_class)
74
+ end
75
+ def self.new(
76
+ # Filter Card Validations to ones belonging to the specified Account.
77
+ account_id: nil,
78
+ created_at: nil,
79
+ # Return the page of entries after this one.
80
+ cursor: nil,
81
+ # Filter records to the one with the specified `idempotency_key` you chose for
82
+ # that object. This value is unique across Increase and is used to ensure that a
83
+ # request is only processed once. Learn more about
84
+ # [idempotency](https://increase.com/documentation/idempotency-keys).
85
+ idempotency_key: nil,
86
+ # Limit the size of the list that is returned. The default (and maximum) is 100
87
+ # objects.
88
+ limit: nil,
89
+ status: nil,
90
+ request_options: {}
91
+ )
92
+ end
93
+
94
+ sig do
95
+ override.returns(
96
+ {
97
+ account_id: String,
98
+ created_at: Increase::CardValidationListParams::CreatedAt,
99
+ cursor: String,
100
+ idempotency_key: String,
101
+ limit: Integer,
102
+ status: Increase::CardValidationListParams::Status,
103
+ request_options: Increase::RequestOptions
104
+ }
105
+ )
106
+ end
107
+ def to_hash
108
+ end
109
+
110
+ class CreatedAt < Increase::Internal::Type::BaseModel
111
+ OrHash =
112
+ T.type_alias do
113
+ T.any(
114
+ Increase::CardValidationListParams::CreatedAt,
115
+ Increase::Internal::AnyHash
116
+ )
117
+ end
118
+
119
+ # Return results after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
120
+ # timestamp.
121
+ sig { returns(T.nilable(Time)) }
122
+ attr_reader :after
123
+
124
+ sig { params(after: Time).void }
125
+ attr_writer :after
126
+
127
+ # Return results before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
128
+ # timestamp.
129
+ sig { returns(T.nilable(Time)) }
130
+ attr_reader :before
131
+
132
+ sig { params(before: Time).void }
133
+ attr_writer :before
134
+
135
+ # Return results on or after this
136
+ # [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
137
+ sig { returns(T.nilable(Time)) }
138
+ attr_reader :on_or_after
139
+
140
+ sig { params(on_or_after: Time).void }
141
+ attr_writer :on_or_after
142
+
143
+ # Return results on or before this
144
+ # [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
145
+ sig { returns(T.nilable(Time)) }
146
+ attr_reader :on_or_before
147
+
148
+ sig { params(on_or_before: Time).void }
149
+ attr_writer :on_or_before
150
+
151
+ sig do
152
+ params(
153
+ after: Time,
154
+ before: Time,
155
+ on_or_after: Time,
156
+ on_or_before: Time
157
+ ).returns(T.attached_class)
158
+ end
159
+ def self.new(
160
+ # Return results after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
161
+ # timestamp.
162
+ after: nil,
163
+ # Return results before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
164
+ # timestamp.
165
+ before: nil,
166
+ # Return results on or after this
167
+ # [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
168
+ on_or_after: nil,
169
+ # Return results on or before this
170
+ # [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
171
+ on_or_before: nil
172
+ )
173
+ end
174
+
175
+ sig do
176
+ override.returns(
177
+ { after: Time, before: Time, on_or_after: Time, on_or_before: Time }
178
+ )
179
+ end
180
+ def to_hash
181
+ end
182
+ end
183
+
184
+ class Status < Increase::Internal::Type::BaseModel
185
+ OrHash =
186
+ T.type_alias do
187
+ T.any(
188
+ Increase::CardValidationListParams::Status,
189
+ Increase::Internal::AnyHash
190
+ )
191
+ end
192
+
193
+ # Filter Card Validations by status. For GET requests, this should be encoded as a
194
+ # comma-delimited string, such as `?in=one,two,three`.
195
+ sig do
196
+ returns(
197
+ T.nilable(
198
+ T::Array[Increase::CardValidationListParams::Status::In::OrSymbol]
199
+ )
200
+ )
201
+ end
202
+ attr_reader :in_
203
+
204
+ sig do
205
+ params(
206
+ in_:
207
+ T::Array[Increase::CardValidationListParams::Status::In::OrSymbol]
208
+ ).void
209
+ end
210
+ attr_writer :in_
211
+
212
+ sig do
213
+ params(
214
+ in_:
215
+ T::Array[Increase::CardValidationListParams::Status::In::OrSymbol]
216
+ ).returns(T.attached_class)
217
+ end
218
+ def self.new(
219
+ # Filter Card Validations by status. For GET requests, this should be encoded as a
220
+ # comma-delimited string, such as `?in=one,two,three`.
221
+ in_: nil
222
+ )
223
+ end
224
+
225
+ sig do
226
+ override.returns(
227
+ {
228
+ in_:
229
+ T::Array[
230
+ Increase::CardValidationListParams::Status::In::OrSymbol
231
+ ]
232
+ }
233
+ )
234
+ end
235
+ def to_hash
236
+ end
237
+
238
+ module In
239
+ extend Increase::Internal::Type::Enum
240
+
241
+ TaggedSymbol =
242
+ T.type_alias do
243
+ T.all(Symbol, Increase::CardValidationListParams::Status::In)
244
+ end
245
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
246
+
247
+ # The validation requires attention from an Increase operator.
248
+ REQUIRES_ATTENTION =
249
+ T.let(
250
+ :requires_attention,
251
+ Increase::CardValidationListParams::Status::In::TaggedSymbol
252
+ )
253
+
254
+ # The validation is queued to be submitted to the card network.
255
+ PENDING_SUBMISSION =
256
+ T.let(
257
+ :pending_submission,
258
+ Increase::CardValidationListParams::Status::In::TaggedSymbol
259
+ )
260
+
261
+ # The validation has been submitted and is pending a response from the card network.
262
+ SUBMITTED =
263
+ T.let(
264
+ :submitted,
265
+ Increase::CardValidationListParams::Status::In::TaggedSymbol
266
+ )
267
+
268
+ # The validation has been sent successfully and is complete.
269
+ COMPLETE =
270
+ T.let(
271
+ :complete,
272
+ Increase::CardValidationListParams::Status::In::TaggedSymbol
273
+ )
274
+
275
+ # The validation was declined by the network or the recipient's bank.
276
+ DECLINED =
277
+ T.let(
278
+ :declined,
279
+ Increase::CardValidationListParams::Status::In::TaggedSymbol
280
+ )
281
+
282
+ sig do
283
+ override.returns(
284
+ T::Array[
285
+ Increase::CardValidationListParams::Status::In::TaggedSymbol
286
+ ]
287
+ )
288
+ end
289
+ def self.values
290
+ end
291
+ end
292
+ end
293
+ end
294
+ end
295
+ end
@@ -0,0 +1,30 @@
1
+ # typed: strong
2
+
3
+ module Increase
4
+ module Models
5
+ class CardValidationRetrieveParams < Increase::Internal::Type::BaseModel
6
+ extend Increase::Internal::Type::RequestParameters::Converter
7
+ include Increase::Internal::Type::RequestParameters
8
+
9
+ OrHash =
10
+ T.type_alias do
11
+ T.any(
12
+ Increase::CardValidationRetrieveParams,
13
+ Increase::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig do
18
+ params(request_options: Increase::RequestOptions::OrHash).returns(
19
+ T.attached_class
20
+ )
21
+ end
22
+ def self.new(request_options: {})
23
+ end
24
+
25
+ sig { override.returns({ request_options: Increase::RequestOptions }) }
26
+ def to_hash
27
+ end
28
+ end
29
+ end
30
+ end
@@ -172,6 +172,13 @@ module Increase
172
172
  SAVINGS =
173
173
  T.let(:savings, Increase::ExternalAccount::Funding::TaggedSymbol)
174
174
 
175
+ # A general ledger account.
176
+ GENERAL_LEDGER =
177
+ T.let(
178
+ :general_ledger,
179
+ Increase::ExternalAccount::Funding::TaggedSymbol
180
+ )
181
+
175
182
  # A different type of account.
176
183
  OTHER = T.let(:other, Increase::ExternalAccount::Funding::TaggedSymbol)
177
184
 
@@ -169,6 +169,13 @@ module Increase
169
169
  Increase::ExternalAccountCreateParams::Funding::TaggedSymbol
170
170
  )
171
171
 
172
+ # A general ledger account.
173
+ GENERAL_LEDGER =
174
+ T.let(
175
+ :general_ledger,
176
+ Increase::ExternalAccountCreateParams::Funding::TaggedSymbol
177
+ )
178
+
172
179
  # A different type of account.
173
180
  OTHER =
174
181
  T.let(
@@ -166,6 +166,13 @@ module Increase
166
166
  Increase::ExternalAccountUpdateParams::Funding::TaggedSymbol
167
167
  )
168
168
 
169
+ # A general ledger account.
170
+ GENERAL_LEDGER =
171
+ T.let(
172
+ :general_ledger,
173
+ Increase::ExternalAccountUpdateParams::Funding::TaggedSymbol
174
+ )
175
+
169
176
  # A different type of account.
170
177
  OTHER =
171
178
  T.let(