dodopayments 2.30.0 → 2.32.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 +16 -0
- data/README.md +1 -1
- data/lib/dodopayments/models/checkout_session_flags.rb +4 -2
- data/lib/dodopayments/models/checkout_session_request.rb +14 -4
- data/lib/dodopayments/models/customers/email_policies.rb +3 -2
- data/lib/dodopayments/models/refund.rb +22 -1
- data/lib/dodopayments/models/refund_list_item.rb +22 -1
- data/lib/dodopayments/models/refund_network_reference_type.rb +19 -0
- data/lib/dodopayments/models/subscription.rb +10 -1
- data/lib/dodopayments/models/subscription_cancelled_by.rb +54 -0
- data/lib/dodopayments/models/subscription_list_response.rb +10 -1
- data/lib/dodopayments/models/subscription_preview_change_plan_response.rb +18 -7
- data/lib/dodopayments/models/update_subscription_plan_req.rb +37 -1
- data/lib/dodopayments/models.rb +4 -0
- data/lib/dodopayments/resources/checkout_sessions.rb +4 -4
- data/lib/dodopayments/resources/subscriptions.rb +10 -2
- data/lib/dodopayments/version.rb +1 -1
- data/lib/dodopayments.rb +2 -0
- data/rbi/dodopayments/models/checkout_session_flags.rbi +8 -4
- data/rbi/dodopayments/models/checkout_session_request.rbi +25 -8
- data/rbi/dodopayments/models/customers/email_policies.rbi +4 -2
- data/rbi/dodopayments/models/refund.rbi +26 -0
- data/rbi/dodopayments/models/refund_list_item.rbi +26 -0
- data/rbi/dodopayments/models/refund_network_reference_type.rbi +41 -0
- data/rbi/dodopayments/models/subscription.rbi +18 -0
- data/rbi/dodopayments/models/subscription_cancelled_by.rbi +107 -0
- data/rbi/dodopayments/models/subscription_list_response.rbi +18 -0
- data/rbi/dodopayments/models/subscription_preview_change_plan_response.rbi +24 -10
- data/rbi/dodopayments/models/update_subscription_plan_req.rbi +62 -3
- data/rbi/dodopayments/models.rbi +4 -0
- data/rbi/dodopayments/resources/checkout_sessions.rbi +24 -4
- data/rbi/dodopayments/resources/subscriptions.rbi +52 -0
- data/sig/dodopayments/models/checkout_session_request.rbs +4 -6
- data/sig/dodopayments/models/refund.rbs +10 -0
- data/sig/dodopayments/models/refund_list_item.rbs +10 -0
- data/sig/dodopayments/models/refund_network_reference_type.rbs +20 -0
- data/sig/dodopayments/models/subscription.rbs +5 -0
- data/sig/dodopayments/models/subscription_cancelled_by.rbs +43 -0
- data/sig/dodopayments/models/subscription_list_response.rbs +5 -0
- data/sig/dodopayments/models/subscription_preview_change_plan_response.rbs +5 -0
- data/sig/dodopayments/models/update_subscription_plan_req.rbs +15 -3
- data/sig/dodopayments/models.rbs +4 -0
- data/sig/dodopayments/resources/checkout_sessions.rbs +2 -2
- data/sig/dodopayments/resources/subscriptions.rbs +4 -0
- metadata +8 -2
|
@@ -30,7 +30,7 @@ module Dodopayments
|
|
|
30
30
|
mandate_min_amount_inr_paise: T.nilable(Integer),
|
|
31
31
|
metadata:
|
|
32
32
|
T.nilable(T::Hash[Symbol, Dodopayments::MetadataItem::Variants]),
|
|
33
|
-
minimal_address: T::Boolean,
|
|
33
|
+
minimal_address: T.nilable(T::Boolean),
|
|
34
34
|
payment_method_id: T.nilable(String),
|
|
35
35
|
product_collection_id: T.nilable(String),
|
|
36
36
|
return_url: T.nilable(String),
|
|
@@ -55,7 +55,14 @@ module Dodopayments
|
|
|
55
55
|
allowed_payment_method_types: nil,
|
|
56
56
|
# Billing address information for the session
|
|
57
57
|
billing_address: nil,
|
|
58
|
-
#
|
|
58
|
+
# The currency to charge the customer in.
|
|
59
|
+
#
|
|
60
|
+
# Adaptive pricing must be enabled for the business. The customer then pays in
|
|
61
|
+
# this currency. If you do not set it, the currency comes from the billing
|
|
62
|
+
# country.
|
|
63
|
+
#
|
|
64
|
+
# If adaptive pricing is disabled, the API discards this field. The currency then
|
|
65
|
+
# comes from the product price, or from the billing country.
|
|
59
66
|
billing_currency: nil,
|
|
60
67
|
# The URL to redirect the customer if they cancel or go back from the checkout. If
|
|
61
68
|
# not provided, the back button will not be displayed.
|
|
@@ -94,6 +101,9 @@ module Dodopayments
|
|
|
94
101
|
metadata: nil,
|
|
95
102
|
# If true, only zipcode is required when confirm is true; other address fields
|
|
96
103
|
# remain optional
|
|
104
|
+
#
|
|
105
|
+
# Default is true when `feature_flags.single_page` is true. Otherwise, default is
|
|
106
|
+
# false.
|
|
97
107
|
minimal_address: nil,
|
|
98
108
|
# Optional payment method ID to use for this checkout session. Only allowed when
|
|
99
109
|
# `confirm` is true. If provided, existing customer id must also be provided.
|
|
@@ -154,7 +164,7 @@ module Dodopayments
|
|
|
154
164
|
mandate_min_amount_inr_paise: T.nilable(Integer),
|
|
155
165
|
metadata:
|
|
156
166
|
T.nilable(T::Hash[Symbol, Dodopayments::MetadataItem::Variants]),
|
|
157
|
-
minimal_address: T::Boolean,
|
|
167
|
+
minimal_address: T.nilable(T::Boolean),
|
|
158
168
|
payment_method_id: T.nilable(String),
|
|
159
169
|
product_collection_id: T.nilable(String),
|
|
160
170
|
return_url: T.nilable(String),
|
|
@@ -179,7 +189,14 @@ module Dodopayments
|
|
|
179
189
|
allowed_payment_method_types: nil,
|
|
180
190
|
# Billing address information for the session
|
|
181
191
|
billing_address: nil,
|
|
182
|
-
#
|
|
192
|
+
# The currency to charge the customer in.
|
|
193
|
+
#
|
|
194
|
+
# Adaptive pricing must be enabled for the business. The customer then pays in
|
|
195
|
+
# this currency. If you do not set it, the currency comes from the billing
|
|
196
|
+
# country.
|
|
197
|
+
#
|
|
198
|
+
# If adaptive pricing is disabled, the API discards this field. The currency then
|
|
199
|
+
# comes from the product price, or from the billing country.
|
|
183
200
|
billing_currency: nil,
|
|
184
201
|
# The URL to redirect the customer if they cancel or go back from the checkout. If
|
|
185
202
|
# not provided, the back button will not be displayed.
|
|
@@ -218,6 +235,9 @@ module Dodopayments
|
|
|
218
235
|
metadata: nil,
|
|
219
236
|
# If true, only zipcode is required when confirm is true; other address fields
|
|
220
237
|
# remain optional
|
|
238
|
+
#
|
|
239
|
+
# Default is true when `feature_flags.single_page` is true. Otherwise, default is
|
|
240
|
+
# false.
|
|
221
241
|
minimal_address: nil,
|
|
222
242
|
# Optional payment method ID to use for this checkout session. Only allowed when
|
|
223
243
|
# `confirm` is true. If provided, existing customer id must also be provided.
|
|
@@ -280,6 +280,7 @@ module Dodopayments
|
|
|
280
280
|
quantity: Integer,
|
|
281
281
|
adaptive_currency_fees_inclusive: T.nilable(T::Boolean),
|
|
282
282
|
addons: T.nilable(T::Array[Dodopayments::AttachAddon::OrHash]),
|
|
283
|
+
cancel_older_payment_link: T::Boolean,
|
|
283
284
|
cancel_scheduled_change_plan: T::Boolean,
|
|
284
285
|
collect_via_payment_link: T::Boolean,
|
|
285
286
|
discount_code: T.nilable(String),
|
|
@@ -292,6 +293,7 @@ module Dodopayments
|
|
|
292
293
|
T.nilable(
|
|
293
294
|
Dodopayments::UpdateSubscriptionPlanReq::OnPaymentFailure::OrSymbol
|
|
294
295
|
),
|
|
296
|
+
return_url: T.nilable(String),
|
|
295
297
|
request_options: Dodopayments::RequestOptions::OrHash
|
|
296
298
|
).returns(Dodopayments::Models::SubscriptionChangePlanResponse)
|
|
297
299
|
end
|
|
@@ -310,6 +312,19 @@ module Dodopayments
|
|
|
310
312
|
# Addons for the new plan. Note : Leaving this empty would remove any existing
|
|
311
313
|
# addons
|
|
312
314
|
addons: nil,
|
|
315
|
+
# Cancel the payment link of a pending plan change, so that this change can
|
|
316
|
+
# replace it.
|
|
317
|
+
#
|
|
318
|
+
# The link is cancelled only if the customer has not started to pay. A paid or
|
|
319
|
+
# in-progress payment gives a `409`. A failed cancel gives a `503`, and a retry is
|
|
320
|
+
# safe.
|
|
321
|
+
#
|
|
322
|
+
# The request is validated before the cancel. A later failure, for example an
|
|
323
|
+
# amount below the minimum, leaves the subscription on its current plan with no
|
|
324
|
+
# open link. A retry is safe.
|
|
325
|
+
#
|
|
326
|
+
# The preview route shares this request body and ignores this field.
|
|
327
|
+
cancel_older_payment_link: nil,
|
|
313
328
|
# Replace a scheduled plan change with this one.
|
|
314
329
|
#
|
|
315
330
|
# The scheduled change is cancelled by the transaction that applies this change. A
|
|
@@ -356,6 +371,17 @@ module Dodopayments
|
|
|
356
371
|
#
|
|
357
372
|
# If not specified, uses the business-level default setting.
|
|
358
373
|
on_payment_failure: nil,
|
|
374
|
+
# The URL that receives the customer after they pay the payment link. Needs
|
|
375
|
+
# `collect_via_payment_link: true`. Without it, the request gets a `422`. A change
|
|
376
|
+
# that collects no money issues no link and does not use the URL. The preview
|
|
377
|
+
# route validates this field but does not use it.
|
|
378
|
+
#
|
|
379
|
+
# The redirect adds `subscription_id`, `payment_id` and `status`. The `status`
|
|
380
|
+
# value is the status of the plan-change payment. It is not the status of the
|
|
381
|
+
# subscription. When that payment fails, the subscription stays active on its
|
|
382
|
+
# current plan. To try again, call this endpoint again to get a new link. The new
|
|
383
|
+
# plan can apply after the redirect, when the payment webhook arrives.
|
|
384
|
+
return_url: nil,
|
|
359
385
|
request_options: {}
|
|
360
386
|
)
|
|
361
387
|
end
|
|
@@ -410,6 +436,7 @@ module Dodopayments
|
|
|
410
436
|
quantity: Integer,
|
|
411
437
|
adaptive_currency_fees_inclusive: T.nilable(T::Boolean),
|
|
412
438
|
addons: T.nilable(T::Array[Dodopayments::AttachAddon::OrHash]),
|
|
439
|
+
cancel_older_payment_link: T::Boolean,
|
|
413
440
|
cancel_scheduled_change_plan: T::Boolean,
|
|
414
441
|
collect_via_payment_link: T::Boolean,
|
|
415
442
|
discount_code: T.nilable(String),
|
|
@@ -422,6 +449,7 @@ module Dodopayments
|
|
|
422
449
|
T.nilable(
|
|
423
450
|
Dodopayments::UpdateSubscriptionPlanReq::OnPaymentFailure::OrSymbol
|
|
424
451
|
),
|
|
452
|
+
return_url: T.nilable(String),
|
|
425
453
|
request_options: Dodopayments::RequestOptions::OrHash
|
|
426
454
|
).returns(Dodopayments::Models::SubscriptionPreviewChangePlanResponse)
|
|
427
455
|
end
|
|
@@ -440,6 +468,19 @@ module Dodopayments
|
|
|
440
468
|
# Addons for the new plan. Note : Leaving this empty would remove any existing
|
|
441
469
|
# addons
|
|
442
470
|
addons: nil,
|
|
471
|
+
# Cancel the payment link of a pending plan change, so that this change can
|
|
472
|
+
# replace it.
|
|
473
|
+
#
|
|
474
|
+
# The link is cancelled only if the customer has not started to pay. A paid or
|
|
475
|
+
# in-progress payment gives a `409`. A failed cancel gives a `503`, and a retry is
|
|
476
|
+
# safe.
|
|
477
|
+
#
|
|
478
|
+
# The request is validated before the cancel. A later failure, for example an
|
|
479
|
+
# amount below the minimum, leaves the subscription on its current plan with no
|
|
480
|
+
# open link. A retry is safe.
|
|
481
|
+
#
|
|
482
|
+
# The preview route shares this request body and ignores this field.
|
|
483
|
+
cancel_older_payment_link: nil,
|
|
443
484
|
# Replace a scheduled plan change with this one.
|
|
444
485
|
#
|
|
445
486
|
# The scheduled change is cancelled by the transaction that applies this change. A
|
|
@@ -486,6 +527,17 @@ module Dodopayments
|
|
|
486
527
|
#
|
|
487
528
|
# If not specified, uses the business-level default setting.
|
|
488
529
|
on_payment_failure: nil,
|
|
530
|
+
# The URL that receives the customer after they pay the payment link. Needs
|
|
531
|
+
# `collect_via_payment_link: true`. Without it, the request gets a `422`. A change
|
|
532
|
+
# that collects no money issues no link and does not use the URL. The preview
|
|
533
|
+
# route validates this field but does not use it.
|
|
534
|
+
#
|
|
535
|
+
# The redirect adds `subscription_id`, `payment_id` and `status`. The `status`
|
|
536
|
+
# value is the status of the plan-change payment. It is not the status of the
|
|
537
|
+
# subscription. When that payment fails, the subscription stays active on its
|
|
538
|
+
# current plan. To try again, call this endpoint again to get a new link. The new
|
|
539
|
+
# plan can apply after the redirect, when the payment webhook arrives.
|
|
540
|
+
return_url: nil,
|
|
489
541
|
request_options: {}
|
|
490
542
|
)
|
|
491
543
|
end
|
|
@@ -18,7 +18,7 @@ module Dodopayments
|
|
|
18
18
|
:force_3ds => bool?,
|
|
19
19
|
mandate_min_amount_inr_paise: Integer?,
|
|
20
20
|
metadata: Dodopayments::Models::metadata?,
|
|
21
|
-
minimal_address: bool
|
|
21
|
+
minimal_address: bool?,
|
|
22
22
|
payment_method_id: String?,
|
|
23
23
|
product_collection_id: String?,
|
|
24
24
|
return_url: String?,
|
|
@@ -71,9 +71,7 @@ module Dodopayments
|
|
|
71
71
|
|
|
72
72
|
attr_accessor metadata: Dodopayments::Models::metadata?
|
|
73
73
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
def minimal_address=: (bool) -> bool
|
|
74
|
+
attr_accessor minimal_address: bool?
|
|
77
75
|
|
|
78
76
|
attr_accessor payment_method_id: String?
|
|
79
77
|
|
|
@@ -110,7 +108,7 @@ module Dodopayments
|
|
|
110
108
|
?force_3ds: bool?,
|
|
111
109
|
?mandate_min_amount_inr_paise: Integer?,
|
|
112
110
|
?metadata: Dodopayments::Models::metadata?,
|
|
113
|
-
?minimal_address: bool
|
|
111
|
+
?minimal_address: bool?,
|
|
114
112
|
?payment_method_id: String?,
|
|
115
113
|
?product_collection_id: String?,
|
|
116
114
|
?return_url: String?,
|
|
@@ -137,7 +135,7 @@ module Dodopayments
|
|
|
137
135
|
:force_3ds => bool?,
|
|
138
136
|
mandate_min_amount_inr_paise: Integer?,
|
|
139
137
|
metadata: Dodopayments::Models::metadata?,
|
|
140
|
-
minimal_address: bool
|
|
138
|
+
minimal_address: bool?,
|
|
141
139
|
payment_method_id: String?,
|
|
142
140
|
product_collection_id: String?,
|
|
143
141
|
return_url: String?,
|
|
@@ -13,6 +13,8 @@ module Dodopayments
|
|
|
13
13
|
status: Dodopayments::Models::refund_status,
|
|
14
14
|
amount: Integer?,
|
|
15
15
|
currency: Dodopayments::Models::currency?,
|
|
16
|
+
network_reference: String?,
|
|
17
|
+
network_reference_type: Dodopayments::Models::refund_network_reference_type?,
|
|
16
18
|
reason: String?
|
|
17
19
|
}
|
|
18
20
|
|
|
@@ -39,6 +41,10 @@ module Dodopayments
|
|
|
39
41
|
|
|
40
42
|
attr_accessor currency: Dodopayments::Models::currency?
|
|
41
43
|
|
|
44
|
+
attr_accessor network_reference: String?
|
|
45
|
+
|
|
46
|
+
attr_accessor network_reference_type: Dodopayments::Models::refund_network_reference_type?
|
|
47
|
+
|
|
42
48
|
attr_accessor reason: String?
|
|
43
49
|
|
|
44
50
|
def initialize: (
|
|
@@ -53,6 +59,8 @@ module Dodopayments
|
|
|
53
59
|
status: Dodopayments::Models::refund_status,
|
|
54
60
|
?amount: Integer?,
|
|
55
61
|
?currency: Dodopayments::Models::currency?,
|
|
62
|
+
?network_reference: String?,
|
|
63
|
+
?network_reference_type: Dodopayments::Models::refund_network_reference_type?,
|
|
56
64
|
?reason: String?
|
|
57
65
|
) -> void
|
|
58
66
|
|
|
@@ -68,6 +76,8 @@ module Dodopayments
|
|
|
68
76
|
status: Dodopayments::Models::refund_status,
|
|
69
77
|
amount: Integer?,
|
|
70
78
|
currency: Dodopayments::Models::currency?,
|
|
79
|
+
network_reference: String?,
|
|
80
|
+
network_reference_type: Dodopayments::Models::refund_network_reference_type?,
|
|
71
81
|
reason: String?
|
|
72
82
|
}
|
|
73
83
|
end
|
|
@@ -10,6 +10,8 @@ module Dodopayments
|
|
|
10
10
|
status: Dodopayments::Models::refund_status,
|
|
11
11
|
amount: Integer?,
|
|
12
12
|
currency: Dodopayments::Models::currency?,
|
|
13
|
+
network_reference: String?,
|
|
14
|
+
network_reference_type: Dodopayments::Models::refund_network_reference_type?,
|
|
13
15
|
reason: String?
|
|
14
16
|
}
|
|
15
17
|
|
|
@@ -30,6 +32,10 @@ module Dodopayments
|
|
|
30
32
|
|
|
31
33
|
attr_accessor currency: Dodopayments::Models::currency?
|
|
32
34
|
|
|
35
|
+
attr_accessor network_reference: String?
|
|
36
|
+
|
|
37
|
+
attr_accessor network_reference_type: Dodopayments::Models::refund_network_reference_type?
|
|
38
|
+
|
|
33
39
|
attr_accessor reason: String?
|
|
34
40
|
|
|
35
41
|
def initialize: (
|
|
@@ -41,6 +47,8 @@ module Dodopayments
|
|
|
41
47
|
status: Dodopayments::Models::refund_status,
|
|
42
48
|
?amount: Integer?,
|
|
43
49
|
?currency: Dodopayments::Models::currency?,
|
|
50
|
+
?network_reference: String?,
|
|
51
|
+
?network_reference_type: Dodopayments::Models::refund_network_reference_type?,
|
|
44
52
|
?reason: String?
|
|
45
53
|
) -> void
|
|
46
54
|
|
|
@@ -53,6 +61,8 @@ module Dodopayments
|
|
|
53
61
|
status: Dodopayments::Models::refund_status,
|
|
54
62
|
amount: Integer?,
|
|
55
63
|
currency: Dodopayments::Models::currency?,
|
|
64
|
+
network_reference: String?,
|
|
65
|
+
network_reference_type: Dodopayments::Models::refund_network_reference_type?,
|
|
56
66
|
reason: String?
|
|
57
67
|
}
|
|
58
68
|
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
module Dodopayments
|
|
2
|
+
module Models
|
|
3
|
+
type refund_network_reference_type =
|
|
4
|
+
:acquirer_reference_number
|
|
5
|
+
| :system_trace_audit_number
|
|
6
|
+
| :retrieval_reference_number
|
|
7
|
+
| :other
|
|
8
|
+
|
|
9
|
+
module RefundNetworkReferenceType
|
|
10
|
+
extend Dodopayments::Internal::Type::Enum
|
|
11
|
+
|
|
12
|
+
ACQUIRER_REFERENCE_NUMBER: :acquirer_reference_number
|
|
13
|
+
SYSTEM_TRACE_AUDIT_NUMBER: :system_trace_audit_number
|
|
14
|
+
RETRIEVAL_REFERENCE_NUMBER: :retrieval_reference_number
|
|
15
|
+
OTHER: :other
|
|
16
|
+
|
|
17
|
+
def self?.values: -> ::Array[Dodopayments::Models::refund_network_reference_type]
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
@@ -31,6 +31,7 @@ module Dodopayments
|
|
|
31
31
|
cancellation_comment: String?,
|
|
32
32
|
cancellation_feedback: Dodopayments::Models::cancellation_feedback?,
|
|
33
33
|
cancelled_at: Time?,
|
|
34
|
+
cancelled_by: Dodopayments::SubscriptionCancelledBy?,
|
|
34
35
|
custom_field_responses: ::Array[Dodopayments::CustomFieldResponse]?,
|
|
35
36
|
customer_business_name: String?,
|
|
36
37
|
discount_cycles_remaining: Integer?,
|
|
@@ -103,6 +104,8 @@ module Dodopayments
|
|
|
103
104
|
|
|
104
105
|
attr_accessor cancelled_at: Time?
|
|
105
106
|
|
|
107
|
+
attr_accessor cancelled_by: Dodopayments::SubscriptionCancelledBy?
|
|
108
|
+
|
|
106
109
|
attr_accessor custom_field_responses: ::Array[Dodopayments::CustomFieldResponse]?
|
|
107
110
|
|
|
108
111
|
attr_accessor customer_business_name: String?
|
|
@@ -155,6 +158,7 @@ module Dodopayments
|
|
|
155
158
|
?cancellation_comment: String?,
|
|
156
159
|
?cancellation_feedback: Dodopayments::Models::cancellation_feedback?,
|
|
157
160
|
?cancelled_at: Time?,
|
|
161
|
+
?cancelled_by: Dodopayments::SubscriptionCancelledBy?,
|
|
158
162
|
?custom_field_responses: ::Array[Dodopayments::CustomFieldResponse]?,
|
|
159
163
|
?customer_business_name: String?,
|
|
160
164
|
?discount_cycles_remaining: Integer?,
|
|
@@ -198,6 +202,7 @@ module Dodopayments
|
|
|
198
202
|
cancellation_comment: String?,
|
|
199
203
|
cancellation_feedback: Dodopayments::Models::cancellation_feedback?,
|
|
200
204
|
cancelled_at: Time?,
|
|
205
|
+
cancelled_by: Dodopayments::SubscriptionCancelledBy?,
|
|
201
206
|
custom_field_responses: ::Array[Dodopayments::CustomFieldResponse]?,
|
|
202
207
|
customer_business_name: String?,
|
|
203
208
|
discount_cycles_remaining: Integer?,
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
module Dodopayments
|
|
2
|
+
module Models
|
|
3
|
+
type subscription_cancelled_by =
|
|
4
|
+
{
|
|
5
|
+
actor_type: Dodopayments::Models::SubscriptionCancelledBy::actor_type,
|
|
6
|
+
email: String?,
|
|
7
|
+
name: String?
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
class SubscriptionCancelledBy < Dodopayments::Internal::Type::BaseModel
|
|
11
|
+
attr_accessor actor_type: Dodopayments::Models::SubscriptionCancelledBy::actor_type
|
|
12
|
+
|
|
13
|
+
attr_accessor email: String?
|
|
14
|
+
|
|
15
|
+
attr_accessor name: String?
|
|
16
|
+
|
|
17
|
+
def initialize: (
|
|
18
|
+
actor_type: Dodopayments::Models::SubscriptionCancelledBy::actor_type,
|
|
19
|
+
?email: String?,
|
|
20
|
+
?name: String?
|
|
21
|
+
) -> void
|
|
22
|
+
|
|
23
|
+
def to_hash: -> {
|
|
24
|
+
actor_type: Dodopayments::Models::SubscriptionCancelledBy::actor_type,
|
|
25
|
+
email: String?,
|
|
26
|
+
name: String?
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
type actor_type = :customer | :merchant_user | :api_key | :dodo_team
|
|
30
|
+
|
|
31
|
+
module ActorType
|
|
32
|
+
extend Dodopayments::Internal::Type::Enum
|
|
33
|
+
|
|
34
|
+
CUSTOMER: :customer
|
|
35
|
+
MERCHANT_USER: :merchant_user
|
|
36
|
+
API_KEY: :api_key
|
|
37
|
+
DODO_TEAM: :dodo_team
|
|
38
|
+
|
|
39
|
+
def self?.values: -> ::Array[Dodopayments::Models::SubscriptionCancelledBy::actor_type]
|
|
40
|
+
end
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
end
|
|
@@ -25,6 +25,7 @@ module Dodopayments
|
|
|
25
25
|
tax_inclusive: bool,
|
|
26
26
|
trial_period_days: Integer,
|
|
27
27
|
cancelled_at: Time?,
|
|
28
|
+
cancelled_by: Dodopayments::SubscriptionCancelledBy?,
|
|
28
29
|
customer_business_name: String?,
|
|
29
30
|
discount_cycles_remaining: Integer?,
|
|
30
31
|
discount_id: String?,
|
|
@@ -83,6 +84,8 @@ module Dodopayments
|
|
|
83
84
|
|
|
84
85
|
attr_accessor cancelled_at: Time?
|
|
85
86
|
|
|
87
|
+
attr_accessor cancelled_by: Dodopayments::SubscriptionCancelledBy?
|
|
88
|
+
|
|
86
89
|
attr_accessor customer_business_name: String?
|
|
87
90
|
|
|
88
91
|
attr_accessor discount_cycles_remaining: Integer?
|
|
@@ -125,6 +128,7 @@ module Dodopayments
|
|
|
125
128
|
tax_inclusive: bool,
|
|
126
129
|
trial_period_days: Integer,
|
|
127
130
|
?cancelled_at: Time?,
|
|
131
|
+
?cancelled_by: Dodopayments::SubscriptionCancelledBy?,
|
|
128
132
|
?customer_business_name: String?,
|
|
129
133
|
?discount_cycles_remaining: Integer?,
|
|
130
134
|
?discount_id: String?,
|
|
@@ -160,6 +164,7 @@ module Dodopayments
|
|
|
160
164
|
tax_inclusive: bool,
|
|
161
165
|
trial_period_days: Integer,
|
|
162
166
|
cancelled_at: Time?,
|
|
167
|
+
cancelled_by: Dodopayments::SubscriptionCancelledBy?,
|
|
163
168
|
customer_business_name: String?,
|
|
164
169
|
discount_cycles_remaining: Integer?,
|
|
165
170
|
discount_id: String?,
|
|
@@ -283,6 +283,7 @@ module Dodopayments
|
|
|
283
283
|
{
|
|
284
284
|
currency: Dodopayments::Models::currency,
|
|
285
285
|
customer_credits: Integer,
|
|
286
|
+
customer_credits_currency: Dodopayments::Models::currency,
|
|
286
287
|
settlement_amount: Integer,
|
|
287
288
|
settlement_currency: Dodopayments::Models::currency,
|
|
288
289
|
total_amount: Integer,
|
|
@@ -295,6 +296,8 @@ module Dodopayments
|
|
|
295
296
|
|
|
296
297
|
attr_accessor customer_credits: Integer
|
|
297
298
|
|
|
299
|
+
attr_accessor customer_credits_currency: Dodopayments::Models::currency
|
|
300
|
+
|
|
298
301
|
attr_accessor settlement_amount: Integer
|
|
299
302
|
|
|
300
303
|
attr_accessor settlement_currency: Dodopayments::Models::currency
|
|
@@ -308,6 +311,7 @@ module Dodopayments
|
|
|
308
311
|
def initialize: (
|
|
309
312
|
currency: Dodopayments::Models::currency,
|
|
310
313
|
customer_credits: Integer,
|
|
314
|
+
customer_credits_currency: Dodopayments::Models::currency,
|
|
311
315
|
settlement_amount: Integer,
|
|
312
316
|
settlement_currency: Dodopayments::Models::currency,
|
|
313
317
|
total_amount: Integer,
|
|
@@ -318,6 +322,7 @@ module Dodopayments
|
|
|
318
322
|
def to_hash: -> {
|
|
319
323
|
currency: Dodopayments::Models::currency,
|
|
320
324
|
customer_credits: Integer,
|
|
325
|
+
customer_credits_currency: Dodopayments::Models::currency,
|
|
321
326
|
settlement_amount: Integer,
|
|
322
327
|
settlement_currency: Dodopayments::Models::currency,
|
|
323
328
|
total_amount: Integer,
|
|
@@ -7,13 +7,15 @@ module Dodopayments
|
|
|
7
7
|
quantity: Integer,
|
|
8
8
|
adaptive_currency_fees_inclusive: bool?,
|
|
9
9
|
addons: ::Array[Dodopayments::AttachAddon]?,
|
|
10
|
+
cancel_older_payment_link: bool,
|
|
10
11
|
cancel_scheduled_change_plan: bool,
|
|
11
12
|
collect_via_payment_link: bool,
|
|
12
13
|
discount_code: String?,
|
|
13
14
|
discount_codes: ::Array[String]?,
|
|
14
15
|
effective_at: Dodopayments::Models::UpdateSubscriptionPlanReq::effective_at,
|
|
15
16
|
metadata: Dodopayments::Models::metadata?,
|
|
16
|
-
on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure
|
|
17
|
+
on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure?,
|
|
18
|
+
return_url: String?
|
|
17
19
|
}
|
|
18
20
|
|
|
19
21
|
class UpdateSubscriptionPlanReq < Dodopayments::Internal::Type::BaseModel
|
|
@@ -27,6 +29,10 @@ module Dodopayments
|
|
|
27
29
|
|
|
28
30
|
attr_accessor addons: ::Array[Dodopayments::AttachAddon]?
|
|
29
31
|
|
|
32
|
+
attr_reader cancel_older_payment_link: bool?
|
|
33
|
+
|
|
34
|
+
def cancel_older_payment_link=: (bool) -> bool
|
|
35
|
+
|
|
30
36
|
attr_reader cancel_scheduled_change_plan: bool?
|
|
31
37
|
|
|
32
38
|
def cancel_scheduled_change_plan=: (bool) -> bool
|
|
@@ -49,19 +55,23 @@ module Dodopayments
|
|
|
49
55
|
|
|
50
56
|
attr_accessor on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure?
|
|
51
57
|
|
|
58
|
+
attr_accessor return_url: String?
|
|
59
|
+
|
|
52
60
|
def initialize: (
|
|
53
61
|
product_id: String,
|
|
54
62
|
proration_billing_mode: Dodopayments::Models::UpdateSubscriptionPlanReq::proration_billing_mode,
|
|
55
63
|
quantity: Integer,
|
|
56
64
|
?adaptive_currency_fees_inclusive: bool?,
|
|
57
65
|
?addons: ::Array[Dodopayments::AttachAddon]?,
|
|
66
|
+
?cancel_older_payment_link: bool,
|
|
58
67
|
?cancel_scheduled_change_plan: bool,
|
|
59
68
|
?collect_via_payment_link: bool,
|
|
60
69
|
?discount_code: String?,
|
|
61
70
|
?discount_codes: ::Array[String]?,
|
|
62
71
|
?effective_at: Dodopayments::Models::UpdateSubscriptionPlanReq::effective_at,
|
|
63
72
|
?metadata: Dodopayments::Models::metadata?,
|
|
64
|
-
?on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure
|
|
73
|
+
?on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure?,
|
|
74
|
+
?return_url: String?
|
|
65
75
|
) -> void
|
|
66
76
|
|
|
67
77
|
def to_hash: -> {
|
|
@@ -70,13 +80,15 @@ module Dodopayments
|
|
|
70
80
|
quantity: Integer,
|
|
71
81
|
adaptive_currency_fees_inclusive: bool?,
|
|
72
82
|
addons: ::Array[Dodopayments::AttachAddon]?,
|
|
83
|
+
cancel_older_payment_link: bool,
|
|
73
84
|
cancel_scheduled_change_plan: bool,
|
|
74
85
|
collect_via_payment_link: bool,
|
|
75
86
|
discount_code: String?,
|
|
76
87
|
discount_codes: ::Array[String]?,
|
|
77
88
|
effective_at: Dodopayments::Models::UpdateSubscriptionPlanReq::effective_at,
|
|
78
89
|
metadata: Dodopayments::Models::metadata?,
|
|
79
|
-
on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure
|
|
90
|
+
on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure?,
|
|
91
|
+
return_url: String?
|
|
80
92
|
}
|
|
81
93
|
|
|
82
94
|
type proration_billing_mode =
|
data/sig/dodopayments/models.rbs
CHANGED
|
@@ -421,6 +421,8 @@ module Dodopayments
|
|
|
421
421
|
|
|
422
422
|
class RefundListParams = Dodopayments::Models::RefundListParams
|
|
423
423
|
|
|
424
|
+
module RefundNetworkReferenceType = Dodopayments::Models::RefundNetworkReferenceType
|
|
425
|
+
|
|
424
426
|
class RefundRetrieveParams = Dodopayments::Models::RefundRetrieveParams
|
|
425
427
|
|
|
426
428
|
module RefundStatus = Dodopayments::Models::RefundStatus
|
|
@@ -435,6 +437,8 @@ module Dodopayments
|
|
|
435
437
|
|
|
436
438
|
class SubscriptionCancelChangePlanParams = Dodopayments::Models::SubscriptionCancelChangePlanParams
|
|
437
439
|
|
|
440
|
+
class SubscriptionCancelledBy = Dodopayments::Models::SubscriptionCancelledBy
|
|
441
|
+
|
|
438
442
|
class SubscriptionCancelledWebhookEvent = Dodopayments::Models::SubscriptionCancelledWebhookEvent
|
|
439
443
|
|
|
440
444
|
class SubscriptionChangePlanParams = Dodopayments::Models::SubscriptionChangePlanParams
|
|
@@ -18,7 +18,7 @@ module Dodopayments
|
|
|
18
18
|
?force_3ds: bool?,
|
|
19
19
|
?mandate_min_amount_inr_paise: Integer?,
|
|
20
20
|
?metadata: Dodopayments::Models::metadata?,
|
|
21
|
-
?minimal_address: bool
|
|
21
|
+
?minimal_address: bool?,
|
|
22
22
|
?payment_method_id: String?,
|
|
23
23
|
?product_collection_id: String?,
|
|
24
24
|
?return_url: String?,
|
|
@@ -51,7 +51,7 @@ module Dodopayments
|
|
|
51
51
|
?force_3ds: bool?,
|
|
52
52
|
?mandate_min_amount_inr_paise: Integer?,
|
|
53
53
|
?metadata: Dodopayments::Models::metadata?,
|
|
54
|
-
?minimal_address: bool
|
|
54
|
+
?minimal_address: bool?,
|
|
55
55
|
?payment_method_id: String?,
|
|
56
56
|
?product_collection_id: String?,
|
|
57
57
|
?return_url: String?,
|
|
@@ -80,6 +80,7 @@ module Dodopayments
|
|
|
80
80
|
quantity: Integer,
|
|
81
81
|
?adaptive_currency_fees_inclusive: bool?,
|
|
82
82
|
?addons: ::Array[Dodopayments::AttachAddon]?,
|
|
83
|
+
?cancel_older_payment_link: bool,
|
|
83
84
|
?cancel_scheduled_change_plan: bool,
|
|
84
85
|
?collect_via_payment_link: bool,
|
|
85
86
|
?discount_code: String?,
|
|
@@ -87,6 +88,7 @@ module Dodopayments
|
|
|
87
88
|
?effective_at: Dodopayments::Models::UpdateSubscriptionPlanReq::effective_at,
|
|
88
89
|
?metadata: Dodopayments::Models::metadata?,
|
|
89
90
|
?on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure?,
|
|
91
|
+
?return_url: String?,
|
|
90
92
|
?request_options: Dodopayments::request_opts
|
|
91
93
|
) -> Dodopayments::Models::SubscriptionChangePlanResponse
|
|
92
94
|
|
|
@@ -108,6 +110,7 @@ module Dodopayments
|
|
|
108
110
|
quantity: Integer,
|
|
109
111
|
?adaptive_currency_fees_inclusive: bool?,
|
|
110
112
|
?addons: ::Array[Dodopayments::AttachAddon]?,
|
|
113
|
+
?cancel_older_payment_link: bool,
|
|
111
114
|
?cancel_scheduled_change_plan: bool,
|
|
112
115
|
?collect_via_payment_link: bool,
|
|
113
116
|
?discount_code: String?,
|
|
@@ -115,6 +118,7 @@ module Dodopayments
|
|
|
115
118
|
?effective_at: Dodopayments::Models::UpdateSubscriptionPlanReq::effective_at,
|
|
116
119
|
?metadata: Dodopayments::Models::metadata?,
|
|
117
120
|
?on_payment_failure: Dodopayments::Models::UpdateSubscriptionPlanReq::on_payment_failure?,
|
|
121
|
+
?return_url: String?,
|
|
118
122
|
?request_options: Dodopayments::request_opts
|
|
119
123
|
) -> Dodopayments::Models::SubscriptionPreviewChangePlanResponse
|
|
120
124
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dodopayments
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.32.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dodo Payments
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-10-06 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: cgi
|
|
@@ -389,6 +389,7 @@ files:
|
|
|
389
389
|
- lib/dodopayments/models/refund_failed_webhook_event.rb
|
|
390
390
|
- lib/dodopayments/models/refund_list_item.rb
|
|
391
391
|
- lib/dodopayments/models/refund_list_params.rb
|
|
392
|
+
- lib/dodopayments/models/refund_network_reference_type.rb
|
|
392
393
|
- lib/dodopayments/models/refund_retrieve_params.rb
|
|
393
394
|
- lib/dodopayments/models/refund_status.rb
|
|
394
395
|
- lib/dodopayments/models/refund_succeeded_webhook_event.rb
|
|
@@ -396,6 +397,7 @@ files:
|
|
|
396
397
|
- lib/dodopayments/models/subscription.rb
|
|
397
398
|
- lib/dodopayments/models/subscription_active_webhook_event.rb
|
|
398
399
|
- lib/dodopayments/models/subscription_cancel_change_plan_params.rb
|
|
400
|
+
- lib/dodopayments/models/subscription_cancelled_by.rb
|
|
399
401
|
- lib/dodopayments/models/subscription_cancelled_webhook_event.rb
|
|
400
402
|
- lib/dodopayments/models/subscription_change_plan_params.rb
|
|
401
403
|
- lib/dodopayments/models/subscription_change_plan_response.rb
|
|
@@ -825,6 +827,7 @@ files:
|
|
|
825
827
|
- rbi/dodopayments/models/refund_failed_webhook_event.rbi
|
|
826
828
|
- rbi/dodopayments/models/refund_list_item.rbi
|
|
827
829
|
- rbi/dodopayments/models/refund_list_params.rbi
|
|
830
|
+
- rbi/dodopayments/models/refund_network_reference_type.rbi
|
|
828
831
|
- rbi/dodopayments/models/refund_retrieve_params.rbi
|
|
829
832
|
- rbi/dodopayments/models/refund_status.rbi
|
|
830
833
|
- rbi/dodopayments/models/refund_succeeded_webhook_event.rbi
|
|
@@ -832,6 +835,7 @@ files:
|
|
|
832
835
|
- rbi/dodopayments/models/subscription.rbi
|
|
833
836
|
- rbi/dodopayments/models/subscription_active_webhook_event.rbi
|
|
834
837
|
- rbi/dodopayments/models/subscription_cancel_change_plan_params.rbi
|
|
838
|
+
- rbi/dodopayments/models/subscription_cancelled_by.rbi
|
|
835
839
|
- rbi/dodopayments/models/subscription_cancelled_webhook_event.rbi
|
|
836
840
|
- rbi/dodopayments/models/subscription_change_plan_params.rbi
|
|
837
841
|
- rbi/dodopayments/models/subscription_change_plan_response.rbi
|
|
@@ -1260,6 +1264,7 @@ files:
|
|
|
1260
1264
|
- sig/dodopayments/models/refund_failed_webhook_event.rbs
|
|
1261
1265
|
- sig/dodopayments/models/refund_list_item.rbs
|
|
1262
1266
|
- sig/dodopayments/models/refund_list_params.rbs
|
|
1267
|
+
- sig/dodopayments/models/refund_network_reference_type.rbs
|
|
1263
1268
|
- sig/dodopayments/models/refund_retrieve_params.rbs
|
|
1264
1269
|
- sig/dodopayments/models/refund_status.rbs
|
|
1265
1270
|
- sig/dodopayments/models/refund_succeeded_webhook_event.rbs
|
|
@@ -1267,6 +1272,7 @@ files:
|
|
|
1267
1272
|
- sig/dodopayments/models/subscription.rbs
|
|
1268
1273
|
- sig/dodopayments/models/subscription_active_webhook_event.rbs
|
|
1269
1274
|
- sig/dodopayments/models/subscription_cancel_change_plan_params.rbs
|
|
1275
|
+
- sig/dodopayments/models/subscription_cancelled_by.rbs
|
|
1270
1276
|
- sig/dodopayments/models/subscription_cancelled_webhook_event.rbs
|
|
1271
1277
|
- sig/dodopayments/models/subscription_change_plan_params.rbs
|
|
1272
1278
|
- sig/dodopayments/models/subscription_change_plan_response.rbs
|