increase 1.79.0 → 1.80.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -0
- data/README.md +1 -1
- data/lib/increase/client.rb +0 -4
- data/lib/increase/errors.rb +25 -11
- data/lib/increase/internal/page.rb +1 -1
- data/lib/increase/internal/transport/base_client.rb +11 -7
- data/lib/increase/internal/type/base_page.rb +1 -1
- data/lib/increase/internal/util.rb +1 -1
- data/lib/increase/models/transaction.rb +3 -27
- data/lib/increase/models.rb +0 -8
- data/lib/increase/resources/simulations.rb +0 -4
- data/lib/increase/version.rb +1 -1
- data/lib/increase.rb +0 -7
- data/rbi/increase/client.rbi +0 -3
- data/rbi/increase/errors.rbi +29 -2
- data/rbi/increase/internal/transport/base_client.rbi +4 -5
- data/rbi/increase/internal/type/base_page.rbi +1 -1
- data/rbi/increase/internal/util.rbi +1 -1
- data/rbi/increase/models/transaction.rbi +5 -39
- data/rbi/increase/models.rbi +0 -8
- data/rbi/increase/resources/simulations.rbi +0 -3
- data/sig/increase/client.rbs +0 -2
- data/sig/increase/errors.rbs +7 -0
- data/sig/increase/models/transaction.rbs +4 -28
- data/sig/increase/models.rbs +0 -8
- data/sig/increase/resources/simulations.rbs +0 -2
- metadata +1 -22
- data/lib/increase/models/card_dispute.rb +0 -302
- data/lib/increase/models/card_dispute_create_params.rb +0 -45
- data/lib/increase/models/card_dispute_list_params.rb +0 -144
- data/lib/increase/models/card_dispute_retrieve_params.rb +0 -14
- data/lib/increase/models/simulations/card_dispute_action_params.rb +0 -55
- data/lib/increase/resources/card_disputes.rb +0 -97
- data/lib/increase/resources/simulations/card_disputes.rb +0 -45
- data/rbi/increase/models/card_dispute.rbi +0 -425
- data/rbi/increase/models/card_dispute_create_params.rbi +0 -70
- data/rbi/increase/models/card_dispute_list_params.rbi +0 -289
- data/rbi/increase/models/card_dispute_retrieve_params.rbi +0 -30
- data/rbi/increase/models/simulations/card_dispute_action_params.rbi +0 -124
- data/rbi/increase/resources/card_disputes.rbi +0 -78
- data/rbi/increase/resources/simulations/card_disputes.rbi +0 -38
- data/sig/increase/models/card_dispute.rbs +0 -207
- data/sig/increase/models/card_dispute_create_params.rbs +0 -34
- data/sig/increase/models/card_dispute_list_params.rbs +0 -146
- data/sig/increase/models/card_dispute_retrieve_params.rbs +0 -15
- data/sig/increase/models/simulations/card_dispute_action_params.rbs +0 -59
- data/sig/increase/resources/card_disputes.rbs +0 -28
- data/sig/increase/resources/simulations/card_disputes.rbs +0 -16
@@ -1,45 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
module Increase
|
4
|
-
module Resources
|
5
|
-
class Simulations
|
6
|
-
class CardDisputes
|
7
|
-
# After a [Card Dispute](#card-disputes) is created in production, the dispute
|
8
|
-
# will be reviewed. Since no review happens in sandbox, this endpoint simulates
|
9
|
-
# moving a Card Dispute into a rejected or accepted state. A Card Dispute can only
|
10
|
-
# be actioned one time and must have a status of `pending_reviewing`.
|
11
|
-
#
|
12
|
-
# @overload action(card_dispute_id, status:, explanation: nil, request_options: {})
|
13
|
-
#
|
14
|
-
# @param card_dispute_id [String] The dispute you would like to action.
|
15
|
-
#
|
16
|
-
# @param status [Symbol, Increase::Models::Simulations::CardDisputeActionParams::Status] The status to move the dispute to.
|
17
|
-
#
|
18
|
-
# @param explanation [String] Why the dispute was rejected. Not required for accepting disputes.
|
19
|
-
#
|
20
|
-
# @param request_options [Increase::RequestOptions, Hash{Symbol=>Object}, nil]
|
21
|
-
#
|
22
|
-
# @return [Increase::Models::CardDispute]
|
23
|
-
#
|
24
|
-
# @see Increase::Models::Simulations::CardDisputeActionParams
|
25
|
-
def action(card_dispute_id, params)
|
26
|
-
parsed, options = Increase::Simulations::CardDisputeActionParams.dump_request(params)
|
27
|
-
@client.request(
|
28
|
-
method: :post,
|
29
|
-
path: ["simulations/card_disputes/%1$s/action", card_dispute_id],
|
30
|
-
body: parsed,
|
31
|
-
model: Increase::CardDispute,
|
32
|
-
options: options
|
33
|
-
)
|
34
|
-
end
|
35
|
-
|
36
|
-
# @api private
|
37
|
-
#
|
38
|
-
# @param client [Increase::Client]
|
39
|
-
def initialize(client:)
|
40
|
-
@client = client
|
41
|
-
end
|
42
|
-
end
|
43
|
-
end
|
44
|
-
end
|
45
|
-
end
|
@@ -1,425 +0,0 @@
|
|
1
|
-
# typed: strong
|
2
|
-
|
3
|
-
module Increase
|
4
|
-
module Models
|
5
|
-
class CardDispute < Increase::Internal::Type::BaseModel
|
6
|
-
OrHash =
|
7
|
-
T.type_alias do
|
8
|
-
T.any(Increase::CardDispute, Increase::Internal::AnyHash)
|
9
|
-
end
|
10
|
-
|
11
|
-
# The Card Dispute identifier.
|
12
|
-
sig { returns(String) }
|
13
|
-
attr_accessor :id
|
14
|
-
|
15
|
-
# If the Card Dispute's status is `accepted`, this will contain details of the
|
16
|
-
# successful dispute.
|
17
|
-
sig { returns(T.nilable(Increase::CardDispute::Acceptance)) }
|
18
|
-
attr_reader :acceptance
|
19
|
-
|
20
|
-
sig do
|
21
|
-
params(
|
22
|
-
acceptance: T.nilable(Increase::CardDispute::Acceptance::OrHash)
|
23
|
-
).void
|
24
|
-
end
|
25
|
-
attr_writer :acceptance
|
26
|
-
|
27
|
-
# The amount of the dispute, if provided, or the transaction amount otherwise.
|
28
|
-
sig { returns(T.nilable(Integer)) }
|
29
|
-
attr_accessor :amount
|
30
|
-
|
31
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
32
|
-
# the Card Dispute was created.
|
33
|
-
sig { returns(Time) }
|
34
|
-
attr_accessor :created_at
|
35
|
-
|
36
|
-
# The identifier of the Transaction that was disputed.
|
37
|
-
sig { returns(String) }
|
38
|
-
attr_accessor :disputed_transaction_id
|
39
|
-
|
40
|
-
# Why you disputed the Transaction in question.
|
41
|
-
sig { returns(String) }
|
42
|
-
attr_accessor :explanation
|
43
|
-
|
44
|
-
# The idempotency key you chose for this object. This value is unique across
|
45
|
-
# Increase and is used to ensure that a request is only processed once. Learn more
|
46
|
-
# about [idempotency](https://increase.com/documentation/idempotency-keys).
|
47
|
-
sig { returns(T.nilable(String)) }
|
48
|
-
attr_accessor :idempotency_key
|
49
|
-
|
50
|
-
# If the Card Dispute's status is `lost`, this will contain details of the lost
|
51
|
-
# dispute.
|
52
|
-
sig { returns(T.nilable(Increase::CardDispute::Loss)) }
|
53
|
-
attr_reader :loss
|
54
|
-
|
55
|
-
sig { params(loss: T.nilable(Increase::CardDispute::Loss::OrHash)).void }
|
56
|
-
attr_writer :loss
|
57
|
-
|
58
|
-
# If the Card Dispute's status is `rejected`, this will contain details of the
|
59
|
-
# unsuccessful dispute.
|
60
|
-
sig { returns(T.nilable(Increase::CardDispute::Rejection)) }
|
61
|
-
attr_reader :rejection
|
62
|
-
|
63
|
-
sig do
|
64
|
-
params(
|
65
|
-
rejection: T.nilable(Increase::CardDispute::Rejection::OrHash)
|
66
|
-
).void
|
67
|
-
end
|
68
|
-
attr_writer :rejection
|
69
|
-
|
70
|
-
# The results of the Dispute investigation.
|
71
|
-
sig { returns(Increase::CardDispute::Status::TaggedSymbol) }
|
72
|
-
attr_accessor :status
|
73
|
-
|
74
|
-
# A constant representing the object's type. For this resource it will always be
|
75
|
-
# `card_dispute`.
|
76
|
-
sig { returns(Increase::CardDispute::Type::TaggedSymbol) }
|
77
|
-
attr_accessor :type
|
78
|
-
|
79
|
-
# If the Card Dispute's status is `won`, this will contain details of the won
|
80
|
-
# dispute.
|
81
|
-
sig { returns(T.nilable(Increase::CardDispute::Win)) }
|
82
|
-
attr_reader :win
|
83
|
-
|
84
|
-
sig { params(win: T.nilable(Increase::CardDispute::Win::OrHash)).void }
|
85
|
-
attr_writer :win
|
86
|
-
|
87
|
-
# If unauthorized activity occurs on a card, you can create a Card Dispute and
|
88
|
-
# we'll return the funds if appropriate.
|
89
|
-
sig do
|
90
|
-
params(
|
91
|
-
id: String,
|
92
|
-
acceptance: T.nilable(Increase::CardDispute::Acceptance::OrHash),
|
93
|
-
amount: T.nilable(Integer),
|
94
|
-
created_at: Time,
|
95
|
-
disputed_transaction_id: String,
|
96
|
-
explanation: String,
|
97
|
-
idempotency_key: T.nilable(String),
|
98
|
-
loss: T.nilable(Increase::CardDispute::Loss::OrHash),
|
99
|
-
rejection: T.nilable(Increase::CardDispute::Rejection::OrHash),
|
100
|
-
status: Increase::CardDispute::Status::OrSymbol,
|
101
|
-
type: Increase::CardDispute::Type::OrSymbol,
|
102
|
-
win: T.nilable(Increase::CardDispute::Win::OrHash)
|
103
|
-
).returns(T.attached_class)
|
104
|
-
end
|
105
|
-
def self.new(
|
106
|
-
# The Card Dispute identifier.
|
107
|
-
id:,
|
108
|
-
# If the Card Dispute's status is `accepted`, this will contain details of the
|
109
|
-
# successful dispute.
|
110
|
-
acceptance:,
|
111
|
-
# The amount of the dispute, if provided, or the transaction amount otherwise.
|
112
|
-
amount:,
|
113
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
114
|
-
# the Card Dispute was created.
|
115
|
-
created_at:,
|
116
|
-
# The identifier of the Transaction that was disputed.
|
117
|
-
disputed_transaction_id:,
|
118
|
-
# Why you disputed the Transaction in question.
|
119
|
-
explanation:,
|
120
|
-
# The idempotency key you chose for this object. This value is unique across
|
121
|
-
# Increase and is used to ensure that a request is only processed once. Learn more
|
122
|
-
# about [idempotency](https://increase.com/documentation/idempotency-keys).
|
123
|
-
idempotency_key:,
|
124
|
-
# If the Card Dispute's status is `lost`, this will contain details of the lost
|
125
|
-
# dispute.
|
126
|
-
loss:,
|
127
|
-
# If the Card Dispute's status is `rejected`, this will contain details of the
|
128
|
-
# unsuccessful dispute.
|
129
|
-
rejection:,
|
130
|
-
# The results of the Dispute investigation.
|
131
|
-
status:,
|
132
|
-
# A constant representing the object's type. For this resource it will always be
|
133
|
-
# `card_dispute`.
|
134
|
-
type:,
|
135
|
-
# If the Card Dispute's status is `won`, this will contain details of the won
|
136
|
-
# dispute.
|
137
|
-
win:
|
138
|
-
)
|
139
|
-
end
|
140
|
-
|
141
|
-
sig do
|
142
|
-
override.returns(
|
143
|
-
{
|
144
|
-
id: String,
|
145
|
-
acceptance: T.nilable(Increase::CardDispute::Acceptance),
|
146
|
-
amount: T.nilable(Integer),
|
147
|
-
created_at: Time,
|
148
|
-
disputed_transaction_id: String,
|
149
|
-
explanation: String,
|
150
|
-
idempotency_key: T.nilable(String),
|
151
|
-
loss: T.nilable(Increase::CardDispute::Loss),
|
152
|
-
rejection: T.nilable(Increase::CardDispute::Rejection),
|
153
|
-
status: Increase::CardDispute::Status::TaggedSymbol,
|
154
|
-
type: Increase::CardDispute::Type::TaggedSymbol,
|
155
|
-
win: T.nilable(Increase::CardDispute::Win)
|
156
|
-
}
|
157
|
-
)
|
158
|
-
end
|
159
|
-
def to_hash
|
160
|
-
end
|
161
|
-
|
162
|
-
class Acceptance < Increase::Internal::Type::BaseModel
|
163
|
-
OrHash =
|
164
|
-
T.type_alias do
|
165
|
-
T.any(
|
166
|
-
Increase::CardDispute::Acceptance,
|
167
|
-
Increase::Internal::AnyHash
|
168
|
-
)
|
169
|
-
end
|
170
|
-
|
171
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
172
|
-
# the Card Dispute was accepted.
|
173
|
-
sig { returns(Time) }
|
174
|
-
attr_accessor :accepted_at
|
175
|
-
|
176
|
-
# The identifier of the Card Dispute that was accepted.
|
177
|
-
sig { returns(String) }
|
178
|
-
attr_accessor :card_dispute_id
|
179
|
-
|
180
|
-
# The identifier of the Transaction that was created to return the disputed funds
|
181
|
-
# to your account.
|
182
|
-
sig { returns(String) }
|
183
|
-
attr_accessor :transaction_id
|
184
|
-
|
185
|
-
# If the Card Dispute's status is `accepted`, this will contain details of the
|
186
|
-
# successful dispute.
|
187
|
-
sig do
|
188
|
-
params(
|
189
|
-
accepted_at: Time,
|
190
|
-
card_dispute_id: String,
|
191
|
-
transaction_id: String
|
192
|
-
).returns(T.attached_class)
|
193
|
-
end
|
194
|
-
def self.new(
|
195
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
196
|
-
# the Card Dispute was accepted.
|
197
|
-
accepted_at:,
|
198
|
-
# The identifier of the Card Dispute that was accepted.
|
199
|
-
card_dispute_id:,
|
200
|
-
# The identifier of the Transaction that was created to return the disputed funds
|
201
|
-
# to your account.
|
202
|
-
transaction_id:
|
203
|
-
)
|
204
|
-
end
|
205
|
-
|
206
|
-
sig do
|
207
|
-
override.returns(
|
208
|
-
{
|
209
|
-
accepted_at: Time,
|
210
|
-
card_dispute_id: String,
|
211
|
-
transaction_id: String
|
212
|
-
}
|
213
|
-
)
|
214
|
-
end
|
215
|
-
def to_hash
|
216
|
-
end
|
217
|
-
end
|
218
|
-
|
219
|
-
class Loss < Increase::Internal::Type::BaseModel
|
220
|
-
OrHash =
|
221
|
-
T.type_alias do
|
222
|
-
T.any(Increase::CardDispute::Loss, Increase::Internal::AnyHash)
|
223
|
-
end
|
224
|
-
|
225
|
-
# The identifier of the Card Dispute that was lost.
|
226
|
-
sig { returns(String) }
|
227
|
-
attr_accessor :card_dispute_id
|
228
|
-
|
229
|
-
# Why the Card Dispute was lost.
|
230
|
-
sig { returns(String) }
|
231
|
-
attr_accessor :explanation
|
232
|
-
|
233
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
234
|
-
# the Card Dispute was lost.
|
235
|
-
sig { returns(Time) }
|
236
|
-
attr_accessor :lost_at
|
237
|
-
|
238
|
-
# The identifier of the Transaction that was created to debit the disputed funds
|
239
|
-
# from your account.
|
240
|
-
sig { returns(String) }
|
241
|
-
attr_accessor :transaction_id
|
242
|
-
|
243
|
-
# If the Card Dispute's status is `lost`, this will contain details of the lost
|
244
|
-
# dispute.
|
245
|
-
sig do
|
246
|
-
params(
|
247
|
-
card_dispute_id: String,
|
248
|
-
explanation: String,
|
249
|
-
lost_at: Time,
|
250
|
-
transaction_id: String
|
251
|
-
).returns(T.attached_class)
|
252
|
-
end
|
253
|
-
def self.new(
|
254
|
-
# The identifier of the Card Dispute that was lost.
|
255
|
-
card_dispute_id:,
|
256
|
-
# Why the Card Dispute was lost.
|
257
|
-
explanation:,
|
258
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
259
|
-
# the Card Dispute was lost.
|
260
|
-
lost_at:,
|
261
|
-
# The identifier of the Transaction that was created to debit the disputed funds
|
262
|
-
# from your account.
|
263
|
-
transaction_id:
|
264
|
-
)
|
265
|
-
end
|
266
|
-
|
267
|
-
sig do
|
268
|
-
override.returns(
|
269
|
-
{
|
270
|
-
card_dispute_id: String,
|
271
|
-
explanation: String,
|
272
|
-
lost_at: Time,
|
273
|
-
transaction_id: String
|
274
|
-
}
|
275
|
-
)
|
276
|
-
end
|
277
|
-
def to_hash
|
278
|
-
end
|
279
|
-
end
|
280
|
-
|
281
|
-
class Rejection < Increase::Internal::Type::BaseModel
|
282
|
-
OrHash =
|
283
|
-
T.type_alias do
|
284
|
-
T.any(Increase::CardDispute::Rejection, Increase::Internal::AnyHash)
|
285
|
-
end
|
286
|
-
|
287
|
-
# The identifier of the Card Dispute that was rejected.
|
288
|
-
sig { returns(String) }
|
289
|
-
attr_accessor :card_dispute_id
|
290
|
-
|
291
|
-
# Why the Card Dispute was rejected.
|
292
|
-
sig { returns(String) }
|
293
|
-
attr_accessor :explanation
|
294
|
-
|
295
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
296
|
-
# the Card Dispute was rejected.
|
297
|
-
sig { returns(Time) }
|
298
|
-
attr_accessor :rejected_at
|
299
|
-
|
300
|
-
# If the Card Dispute's status is `rejected`, this will contain details of the
|
301
|
-
# unsuccessful dispute.
|
302
|
-
sig do
|
303
|
-
params(
|
304
|
-
card_dispute_id: String,
|
305
|
-
explanation: String,
|
306
|
-
rejected_at: Time
|
307
|
-
).returns(T.attached_class)
|
308
|
-
end
|
309
|
-
def self.new(
|
310
|
-
# The identifier of the Card Dispute that was rejected.
|
311
|
-
card_dispute_id:,
|
312
|
-
# Why the Card Dispute was rejected.
|
313
|
-
explanation:,
|
314
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
315
|
-
# the Card Dispute was rejected.
|
316
|
-
rejected_at:
|
317
|
-
)
|
318
|
-
end
|
319
|
-
|
320
|
-
sig do
|
321
|
-
override.returns(
|
322
|
-
{ card_dispute_id: String, explanation: String, rejected_at: Time }
|
323
|
-
)
|
324
|
-
end
|
325
|
-
def to_hash
|
326
|
-
end
|
327
|
-
end
|
328
|
-
|
329
|
-
# The results of the Dispute investigation.
|
330
|
-
module Status
|
331
|
-
extend Increase::Internal::Type::Enum
|
332
|
-
|
333
|
-
TaggedSymbol =
|
334
|
-
T.type_alias { T.all(Symbol, Increase::CardDispute::Status) }
|
335
|
-
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
336
|
-
|
337
|
-
# The Card Dispute is pending review.
|
338
|
-
PENDING_REVIEWING =
|
339
|
-
T.let(:pending_reviewing, Increase::CardDispute::Status::TaggedSymbol)
|
340
|
-
|
341
|
-
# Increase has requested more information related to the Card Dispute from you.
|
342
|
-
PENDING_USER_INFORMATION =
|
343
|
-
T.let(
|
344
|
-
:pending_user_information,
|
345
|
-
Increase::CardDispute::Status::TaggedSymbol
|
346
|
-
)
|
347
|
-
|
348
|
-
# The Card Dispute has been accepted and your funds have been returned. The card dispute will eventually transition into `won` or `lost` depending on the outcome.
|
349
|
-
ACCEPTED = T.let(:accepted, Increase::CardDispute::Status::TaggedSymbol)
|
350
|
-
|
351
|
-
# The Card Dispute has been rejected.
|
352
|
-
REJECTED = T.let(:rejected, Increase::CardDispute::Status::TaggedSymbol)
|
353
|
-
|
354
|
-
# The Card Dispute has been lost and funds previously credited from the acceptance have been debited.
|
355
|
-
LOST = T.let(:lost, Increase::CardDispute::Status::TaggedSymbol)
|
356
|
-
|
357
|
-
# The Card Dispute has been won and no further action can be taken.
|
358
|
-
WON = T.let(:won, Increase::CardDispute::Status::TaggedSymbol)
|
359
|
-
|
360
|
-
sig do
|
361
|
-
override.returns(
|
362
|
-
T::Array[Increase::CardDispute::Status::TaggedSymbol]
|
363
|
-
)
|
364
|
-
end
|
365
|
-
def self.values
|
366
|
-
end
|
367
|
-
end
|
368
|
-
|
369
|
-
# A constant representing the object's type. For this resource it will always be
|
370
|
-
# `card_dispute`.
|
371
|
-
module Type
|
372
|
-
extend Increase::Internal::Type::Enum
|
373
|
-
|
374
|
-
TaggedSymbol =
|
375
|
-
T.type_alias { T.all(Symbol, Increase::CardDispute::Type) }
|
376
|
-
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
377
|
-
|
378
|
-
CARD_DISPUTE =
|
379
|
-
T.let(:card_dispute, Increase::CardDispute::Type::TaggedSymbol)
|
380
|
-
|
381
|
-
sig do
|
382
|
-
override.returns(T::Array[Increase::CardDispute::Type::TaggedSymbol])
|
383
|
-
end
|
384
|
-
def self.values
|
385
|
-
end
|
386
|
-
end
|
387
|
-
|
388
|
-
class Win < Increase::Internal::Type::BaseModel
|
389
|
-
OrHash =
|
390
|
-
T.type_alias do
|
391
|
-
T.any(Increase::CardDispute::Win, Increase::Internal::AnyHash)
|
392
|
-
end
|
393
|
-
|
394
|
-
# The identifier of the Card Dispute that was won.
|
395
|
-
sig { returns(String) }
|
396
|
-
attr_accessor :card_dispute_id
|
397
|
-
|
398
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
399
|
-
# the Card Dispute was won.
|
400
|
-
sig { returns(Time) }
|
401
|
-
attr_accessor :won_at
|
402
|
-
|
403
|
-
# If the Card Dispute's status is `won`, this will contain details of the won
|
404
|
-
# dispute.
|
405
|
-
sig do
|
406
|
-
params(card_dispute_id: String, won_at: Time).returns(
|
407
|
-
T.attached_class
|
408
|
-
)
|
409
|
-
end
|
410
|
-
def self.new(
|
411
|
-
# The identifier of the Card Dispute that was won.
|
412
|
-
card_dispute_id:,
|
413
|
-
# The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
|
414
|
-
# the Card Dispute was won.
|
415
|
-
won_at:
|
416
|
-
)
|
417
|
-
end
|
418
|
-
|
419
|
-
sig { override.returns({ card_dispute_id: String, won_at: Time }) }
|
420
|
-
def to_hash
|
421
|
-
end
|
422
|
-
end
|
423
|
-
end
|
424
|
-
end
|
425
|
-
end
|
@@ -1,70 +0,0 @@
|
|
1
|
-
# typed: strong
|
2
|
-
|
3
|
-
module Increase
|
4
|
-
module Models
|
5
|
-
class CardDisputeCreateParams < 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::CardDisputeCreateParams, Increase::Internal::AnyHash)
|
12
|
-
end
|
13
|
-
|
14
|
-
# The Transaction you wish to dispute. This Transaction must have a `source_type`
|
15
|
-
# of `card_settlement`.
|
16
|
-
sig { returns(String) }
|
17
|
-
attr_accessor :disputed_transaction_id
|
18
|
-
|
19
|
-
# Why you are disputing this Transaction.
|
20
|
-
sig { returns(String) }
|
21
|
-
attr_accessor :explanation
|
22
|
-
|
23
|
-
# The monetary amount of the part of the transaction that is being disputed. This
|
24
|
-
# is optional and will default to the full amount of the transaction if not
|
25
|
-
# provided. If provided, the amount must be less than or equal to the amount of
|
26
|
-
# the transaction.
|
27
|
-
sig { returns(T.nilable(Integer)) }
|
28
|
-
attr_reader :amount
|
29
|
-
|
30
|
-
sig { params(amount: Integer).void }
|
31
|
-
attr_writer :amount
|
32
|
-
|
33
|
-
sig do
|
34
|
-
params(
|
35
|
-
disputed_transaction_id: String,
|
36
|
-
explanation: String,
|
37
|
-
amount: Integer,
|
38
|
-
request_options: Increase::RequestOptions::OrHash
|
39
|
-
).returns(T.attached_class)
|
40
|
-
end
|
41
|
-
def self.new(
|
42
|
-
# The Transaction you wish to dispute. This Transaction must have a `source_type`
|
43
|
-
# of `card_settlement`.
|
44
|
-
disputed_transaction_id:,
|
45
|
-
# Why you are disputing this Transaction.
|
46
|
-
explanation:,
|
47
|
-
# The monetary amount of the part of the transaction that is being disputed. This
|
48
|
-
# is optional and will default to the full amount of the transaction if not
|
49
|
-
# provided. If provided, the amount must be less than or equal to the amount of
|
50
|
-
# the transaction.
|
51
|
-
amount: nil,
|
52
|
-
request_options: {}
|
53
|
-
)
|
54
|
-
end
|
55
|
-
|
56
|
-
sig do
|
57
|
-
override.returns(
|
58
|
-
{
|
59
|
-
disputed_transaction_id: String,
|
60
|
-
explanation: String,
|
61
|
-
amount: Integer,
|
62
|
-
request_options: Increase::RequestOptions
|
63
|
-
}
|
64
|
-
)
|
65
|
-
end
|
66
|
-
def to_hash
|
67
|
-
end
|
68
|
-
end
|
69
|
-
end
|
70
|
-
end
|