dodopayments 2.14.0 → 2.15.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 +4 -3
- data/README.md +1 -1
- data/lib/dodopayments/models/abandoned_checkout_detected_webhook_event.rb +14 -1
- data/lib/dodopayments/models/abandoned_checkout_recovered_webhook_event.rb +14 -1
- data/lib/dodopayments/models/checkout_session_preview_response.rb +15 -1
- data/lib/dodopayments/models/credit_balance_low_webhook_event.rb +16 -1
- data/lib/dodopayments/models/credit_entitlements/credit_ledger_entry.rb +24 -1
- data/lib/dodopayments/models/dunning_recovered_webhook_event.rb +14 -1
- data/lib/dodopayments/models/dunning_started_webhook_event.rb +14 -1
- data/lib/dodopayments/models/entitlements/entitlement_grant.rb +9 -1
- data/lib/dodopayments/models/entitlements/grant_list_params.rb +1 -26
- data/lib/dodopayments/models/get_dispute.rb +35 -1
- data/lib/dodopayments/models/integration_config.rb +7 -7
- data/lib/dodopayments/models/integration_config_response.rb +7 -11
- data/lib/dodopayments/models/license_key.rb +9 -1
- data/lib/dodopayments/models/payment.rb +7 -5
- data/lib/dodopayments/models/payment_create_response.rb +3 -2
- data/lib/dodopayments/models/payouts/breakup/detail_list_response.rb +7 -6
- data/lib/dodopayments/models/payouts/breakup_retrieve_response.rb +3 -3
- data/lib/dodopayments/models/product.rb +24 -1
- data/lib/dodopayments/models/product_create_params.rb +28 -5
- data/lib/dodopayments/models/product_update_params.rb +24 -1
- data/lib/dodopayments/models/refund.rb +9 -1
- data/lib/dodopayments/models/subscription.rb +12 -4
- data/lib/dodopayments/models/subscription_list_response.rb +3 -3
- data/lib/dodopayments/models/subscription_preview_change_plan_response.rb +16 -1
- data/lib/dodopayments/models/subscription_retrieve_usage_history_response.rb +7 -2
- data/lib/dodopayments/models/theme_config.rb +1 -1
- data/lib/dodopayments/models/webhook_payload.rb +47 -3
- data/lib/dodopayments/resources/entitlements/grants.rb +1 -3
- data/lib/dodopayments/resources/products.rb +8 -4
- data/lib/dodopayments/version.rb +1 -1
- data/rbi/dodopayments/models/abandoned_checkout_detected_webhook_event.rbi +8 -0
- data/rbi/dodopayments/models/abandoned_checkout_recovered_webhook_event.rbi +8 -0
- data/rbi/dodopayments/models/checkout_session_preview_response.rbi +14 -0
- data/rbi/dodopayments/models/credit_balance_low_webhook_event.rbi +8 -0
- data/rbi/dodopayments/models/credit_entitlements/credit_ledger_entry.rbi +8 -0
- data/rbi/dodopayments/models/dunning_recovered_webhook_event.rbi +8 -0
- data/rbi/dodopayments/models/dunning_started_webhook_event.rbi +8 -0
- data/rbi/dodopayments/models/entitlements/entitlement_grant.rbi +8 -0
- data/rbi/dodopayments/models/entitlements/grant_list_params.rbi +0 -89
- data/rbi/dodopayments/models/get_dispute.rbi +52 -0
- data/rbi/dodopayments/models/integration_config.rbi +9 -9
- data/rbi/dodopayments/models/integration_config_response.rbi +9 -15
- data/rbi/dodopayments/models/license_key.rbi +8 -0
- data/rbi/dodopayments/models/payment.rbi +10 -6
- data/rbi/dodopayments/models/payment_create_response.rbi +4 -2
- data/rbi/dodopayments/models/payouts/breakup/detail_list_response.rbi +10 -8
- data/rbi/dodopayments/models/payouts/breakup_retrieve_response.rbi +4 -4
- data/rbi/dodopayments/models/product.rbi +36 -0
- data/rbi/dodopayments/models/product_create_params.rbi +58 -4
- data/rbi/dodopayments/models/product_update_params.rbi +54 -0
- data/rbi/dodopayments/models/refund.rbi +8 -0
- data/rbi/dodopayments/models/subscription.rbi +12 -4
- data/rbi/dodopayments/models/subscription_list_response.rbi +4 -4
- data/rbi/dodopayments/models/subscription_preview_change_plan_response.rbi +10 -0
- data/rbi/dodopayments/models/subscription_retrieve_usage_history_response.rbi +4 -2
- data/rbi/dodopayments/models/theme_config.rbi +1 -1
- data/rbi/dodopayments/models/webhook_payload.rbi +24 -0
- data/rbi/dodopayments/resources/entitlements/grants.rbi +0 -4
- data/rbi/dodopayments/resources/products.rbi +14 -2
- data/sig/dodopayments/models/abandoned_checkout_detected_webhook_event.rbs +5 -0
- data/sig/dodopayments/models/abandoned_checkout_recovered_webhook_event.rbs +5 -0
- data/sig/dodopayments/models/checkout_session_preview_response.rbs +5 -0
- data/sig/dodopayments/models/credit_balance_low_webhook_event.rbs +5 -0
- data/sig/dodopayments/models/credit_entitlements/credit_ledger_entry.rbs +5 -0
- data/sig/dodopayments/models/dunning_recovered_webhook_event.rbs +5 -0
- data/sig/dodopayments/models/dunning_started_webhook_event.rbs +5 -0
- data/sig/dodopayments/models/entitlements/entitlement_grant.rbs +5 -0
- data/sig/dodopayments/models/entitlements/grant_list_params.rbs +0 -34
- data/sig/dodopayments/models/get_dispute.rbs +22 -0
- data/sig/dodopayments/models/license_key.rbs +5 -0
- data/sig/dodopayments/models/product.rbs +16 -0
- data/sig/dodopayments/models/product_create_params.rbs +17 -1
- data/sig/dodopayments/models/product_update_params.rbs +16 -0
- data/sig/dodopayments/models/refund.rbs +5 -0
- data/sig/dodopayments/models/subscription.rbs +5 -0
- data/sig/dodopayments/models/theme_config.rbs +1 -1
- data/sig/dodopayments/models/webhook_payload.rbs +15 -0
- data/sig/dodopayments/resources/entitlements/grants.rbs +0 -1
- data/sig/dodopayments/resources/products.rbs +2 -0
- metadata +2 -2
|
@@ -26,8 +26,8 @@ module Dodopayments
|
|
|
26
26
|
sig { returns(String) }
|
|
27
27
|
attr_accessor :event_type
|
|
28
28
|
|
|
29
|
-
# Original amount in the original currency
|
|
30
|
-
# cents).
|
|
29
|
+
# Original amount in the original currency, in that currency's smallest unit
|
|
30
|
+
# (cents for USD, yen for JPY, fils for KWD).
|
|
31
31
|
sig { returns(Integer) }
|
|
32
32
|
attr_accessor :original_amount
|
|
33
33
|
|
|
@@ -35,8 +35,9 @@ module Dodopayments
|
|
|
35
35
|
sig { returns(String) }
|
|
36
36
|
attr_accessor :original_currency
|
|
37
37
|
|
|
38
|
-
# Amount in the payout's currency
|
|
39
|
-
# rounding to ensure sum matches
|
|
38
|
+
# Amount in the payout's currency, in that currency's smallest unit (cents for
|
|
39
|
+
# USD, yen for JPY, fils for KWD). Uses cumulative rounding to ensure sum matches
|
|
40
|
+
# payout total exactly.
|
|
40
41
|
sig { returns(Integer) }
|
|
41
42
|
attr_accessor :payout_currency_amount
|
|
42
43
|
|
|
@@ -75,13 +76,14 @@ module Dodopayments
|
|
|
75
76
|
# The type of balance ledger event (e.g., "payment", "refund", "dispute",
|
|
76
77
|
# "payment_fees").
|
|
77
78
|
event_type:,
|
|
78
|
-
# Original amount in the original currency
|
|
79
|
-
# cents).
|
|
79
|
+
# Original amount in the original currency, in that currency's smallest unit
|
|
80
|
+
# (cents for USD, yen for JPY, fils for KWD).
|
|
80
81
|
original_amount:,
|
|
81
82
|
# Original currency as ISO 4217 code (e.g., "USD", "EUR").
|
|
82
83
|
original_currency:,
|
|
83
|
-
# Amount in the payout's currency
|
|
84
|
-
# rounding to ensure sum matches
|
|
84
|
+
# Amount in the payout's currency, in that currency's smallest unit (cents for
|
|
85
|
+
# USD, yen for JPY, fils for KWD). Uses cumulative rounding to ensure sum matches
|
|
86
|
+
# payout total exactly.
|
|
85
87
|
payout_currency_amount:,
|
|
86
88
|
# USD equivalent of the original amount (in cents).
|
|
87
89
|
usd_equivalent_amount:,
|
|
@@ -17,8 +17,8 @@ module Dodopayments
|
|
|
17
17
|
sig { returns(String) }
|
|
18
18
|
attr_accessor :event_type
|
|
19
19
|
|
|
20
|
-
# Total amount for this event type in the payout's currency
|
|
21
|
-
# unit,
|
|
20
|
+
# Total amount for this event type in the payout's currency, in that currency's
|
|
21
|
+
# smallest unit (cents for USD, yen for JPY, fils for KWD).
|
|
22
22
|
sig { returns(Integer) }
|
|
23
23
|
attr_accessor :total
|
|
24
24
|
|
|
@@ -30,8 +30,8 @@ module Dodopayments
|
|
|
30
30
|
# The type of balance ledger event (e.g., "payment", "refund", "dispute",
|
|
31
31
|
# "payment_fees").
|
|
32
32
|
event_type:,
|
|
33
|
-
# Total amount for this event type in the payout's currency
|
|
34
|
-
# unit,
|
|
33
|
+
# Total amount for this event type in the payout's currency, in that currency's
|
|
34
|
+
# smallest unit (cents for USD, yen for JPY, fils for KWD).
|
|
35
35
|
total:
|
|
36
36
|
)
|
|
37
37
|
end
|
|
@@ -104,6 +104,13 @@ module Dodopayments
|
|
|
104
104
|
sig { returns(T.nilable(String)) }
|
|
105
105
|
attr_accessor :name
|
|
106
106
|
|
|
107
|
+
# Pricing mode for localized pricing. NULL means base-only (no localized rules
|
|
108
|
+
# apply).
|
|
109
|
+
sig do
|
|
110
|
+
returns(T.nilable(Dodopayments::Product::PricingMode::TaggedSymbol))
|
|
111
|
+
end
|
|
112
|
+
attr_accessor :pricing_mode
|
|
113
|
+
|
|
107
114
|
# The product collection ID this product belongs to, if any
|
|
108
115
|
sig { returns(T.nilable(String)) }
|
|
109
116
|
attr_accessor :product_collection_id
|
|
@@ -139,6 +146,7 @@ module Dodopayments
|
|
|
139
146
|
license_key_duration:
|
|
140
147
|
T.nilable(Dodopayments::LicenseKeyDuration::OrHash),
|
|
141
148
|
name: T.nilable(String),
|
|
149
|
+
pricing_mode: T.nilable(Dodopayments::Product::PricingMode::OrSymbol),
|
|
142
150
|
product_collection_id: T.nilable(String)
|
|
143
151
|
).returns(T.attached_class)
|
|
144
152
|
end
|
|
@@ -183,6 +191,9 @@ module Dodopayments
|
|
|
183
191
|
license_key_duration: nil,
|
|
184
192
|
# Name of the product, optional.
|
|
185
193
|
name: nil,
|
|
194
|
+
# Pricing mode for localized pricing. NULL means base-only (no localized rules
|
|
195
|
+
# apply).
|
|
196
|
+
pricing_mode: nil,
|
|
186
197
|
# The product collection ID this product belongs to, if any
|
|
187
198
|
product_collection_id: nil
|
|
188
199
|
)
|
|
@@ -213,12 +224,37 @@ module Dodopayments
|
|
|
213
224
|
license_key_activations_limit: T.nilable(Integer),
|
|
214
225
|
license_key_duration: T.nilable(Dodopayments::LicenseKeyDuration),
|
|
215
226
|
name: T.nilable(String),
|
|
227
|
+
pricing_mode:
|
|
228
|
+
T.nilable(Dodopayments::Product::PricingMode::TaggedSymbol),
|
|
216
229
|
product_collection_id: T.nilable(String)
|
|
217
230
|
}
|
|
218
231
|
)
|
|
219
232
|
end
|
|
220
233
|
def to_hash
|
|
221
234
|
end
|
|
235
|
+
|
|
236
|
+
# Pricing mode for localized pricing. NULL means base-only (no localized rules
|
|
237
|
+
# apply).
|
|
238
|
+
module PricingMode
|
|
239
|
+
extend Dodopayments::Internal::Type::Enum
|
|
240
|
+
|
|
241
|
+
TaggedSymbol =
|
|
242
|
+
T.type_alias { T.all(Symbol, Dodopayments::Product::PricingMode) }
|
|
243
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
244
|
+
|
|
245
|
+
BY_CURRENCY =
|
|
246
|
+
T.let(:by_currency, Dodopayments::Product::PricingMode::TaggedSymbol)
|
|
247
|
+
BY_COUNTRY =
|
|
248
|
+
T.let(:by_country, Dodopayments::Product::PricingMode::TaggedSymbol)
|
|
249
|
+
|
|
250
|
+
sig do
|
|
251
|
+
override.returns(
|
|
252
|
+
T::Array[Dodopayments::Product::PricingMode::TaggedSymbol]
|
|
253
|
+
)
|
|
254
|
+
end
|
|
255
|
+
def self.values
|
|
256
|
+
end
|
|
257
|
+
end
|
|
222
258
|
end
|
|
223
259
|
end
|
|
224
260
|
end
|
|
@@ -42,7 +42,7 @@ module Dodopayments
|
|
|
42
42
|
sig { returns(T.nilable(String)) }
|
|
43
43
|
attr_accessor :brand_id
|
|
44
44
|
|
|
45
|
-
# Optional credit entitlements to attach (max
|
|
45
|
+
# Optional credit entitlements to attach (max 5)
|
|
46
46
|
sig do
|
|
47
47
|
returns(T.nilable(T::Array[Dodopayments::AttachCreditEntitlement]))
|
|
48
48
|
end
|
|
@@ -72,7 +72,7 @@ module Dodopayments
|
|
|
72
72
|
end
|
|
73
73
|
attr_writer :digital_product_delivery
|
|
74
74
|
|
|
75
|
-
# Optional entitlements to attach to this product (max
|
|
75
|
+
# Optional entitlements to attach to this product (max 50)
|
|
76
76
|
sig do
|
|
77
77
|
returns(T.nilable(T::Array[Dodopayments::AttachProductEntitlement]))
|
|
78
78
|
end
|
|
@@ -124,6 +124,16 @@ module Dodopayments
|
|
|
124
124
|
sig { params(metadata: T::Hash[Symbol, String]).void }
|
|
125
125
|
attr_writer :metadata
|
|
126
126
|
|
|
127
|
+
# Pricing mode for localized pricing. When set, rules from
|
|
128
|
+
# /products/{id}/localized-prices apply at checkout. NULL means base-only
|
|
129
|
+
# (existing behavior).
|
|
130
|
+
sig do
|
|
131
|
+
returns(
|
|
132
|
+
T.nilable(Dodopayments::ProductCreateParams::PricingMode::OrSymbol)
|
|
133
|
+
)
|
|
134
|
+
end
|
|
135
|
+
attr_accessor :pricing_mode
|
|
136
|
+
|
|
127
137
|
sig do
|
|
128
138
|
params(
|
|
129
139
|
name: String,
|
|
@@ -151,6 +161,8 @@ module Dodopayments
|
|
|
151
161
|
T.nilable(Dodopayments::LicenseKeyDuration::OrHash),
|
|
152
162
|
license_key_enabled: T.nilable(T::Boolean),
|
|
153
163
|
metadata: T::Hash[Symbol, String],
|
|
164
|
+
pricing_mode:
|
|
165
|
+
T.nilable(Dodopayments::ProductCreateParams::PricingMode::OrSymbol),
|
|
154
166
|
request_options: Dodopayments::RequestOptions::OrHash
|
|
155
167
|
).returns(T.attached_class)
|
|
156
168
|
end
|
|
@@ -165,7 +177,7 @@ module Dodopayments
|
|
|
165
177
|
addons: nil,
|
|
166
178
|
# Brand id for the product, if not provided will default to primary brand
|
|
167
179
|
brand_id: nil,
|
|
168
|
-
# Optional credit entitlements to attach (max
|
|
180
|
+
# Optional credit entitlements to attach (max 5)
|
|
169
181
|
credit_entitlements: nil,
|
|
170
182
|
# Optional description of the product
|
|
171
183
|
description: nil,
|
|
@@ -173,7 +185,7 @@ module Dodopayments
|
|
|
173
185
|
#
|
|
174
186
|
# deprecated: use entitlements instead
|
|
175
187
|
digital_product_delivery: nil,
|
|
176
|
-
# Optional entitlements to attach to this product (max
|
|
188
|
+
# Optional entitlements to attach to this product (max 50)
|
|
177
189
|
entitlements: nil,
|
|
178
190
|
# Optional message displayed during license key activation
|
|
179
191
|
#
|
|
@@ -200,6 +212,10 @@ module Dodopayments
|
|
|
200
212
|
license_key_enabled: nil,
|
|
201
213
|
# Additional metadata for the product
|
|
202
214
|
metadata: nil,
|
|
215
|
+
# Pricing mode for localized pricing. When set, rules from
|
|
216
|
+
# /products/{id}/localized-prices apply at checkout. NULL means base-only
|
|
217
|
+
# (existing behavior).
|
|
218
|
+
pricing_mode: nil,
|
|
203
219
|
request_options: {}
|
|
204
220
|
)
|
|
205
221
|
end
|
|
@@ -231,6 +247,10 @@ module Dodopayments
|
|
|
231
247
|
license_key_duration: T.nilable(Dodopayments::LicenseKeyDuration),
|
|
232
248
|
license_key_enabled: T.nilable(T::Boolean),
|
|
233
249
|
metadata: T::Hash[Symbol, String],
|
|
250
|
+
pricing_mode:
|
|
251
|
+
T.nilable(
|
|
252
|
+
Dodopayments::ProductCreateParams::PricingMode::OrSymbol
|
|
253
|
+
),
|
|
234
254
|
request_options: Dodopayments::RequestOptions
|
|
235
255
|
}
|
|
236
256
|
)
|
|
@@ -280,6 +300,40 @@ module Dodopayments
|
|
|
280
300
|
def to_hash
|
|
281
301
|
end
|
|
282
302
|
end
|
|
303
|
+
|
|
304
|
+
# Pricing mode for localized pricing. When set, rules from
|
|
305
|
+
# /products/{id}/localized-prices apply at checkout. NULL means base-only
|
|
306
|
+
# (existing behavior).
|
|
307
|
+
module PricingMode
|
|
308
|
+
extend Dodopayments::Internal::Type::Enum
|
|
309
|
+
|
|
310
|
+
TaggedSymbol =
|
|
311
|
+
T.type_alias do
|
|
312
|
+
T.all(Symbol, Dodopayments::ProductCreateParams::PricingMode)
|
|
313
|
+
end
|
|
314
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
315
|
+
|
|
316
|
+
BY_CURRENCY =
|
|
317
|
+
T.let(
|
|
318
|
+
:by_currency,
|
|
319
|
+
Dodopayments::ProductCreateParams::PricingMode::TaggedSymbol
|
|
320
|
+
)
|
|
321
|
+
BY_COUNTRY =
|
|
322
|
+
T.let(
|
|
323
|
+
:by_country,
|
|
324
|
+
Dodopayments::ProductCreateParams::PricingMode::TaggedSymbol
|
|
325
|
+
)
|
|
326
|
+
|
|
327
|
+
sig do
|
|
328
|
+
override.returns(
|
|
329
|
+
T::Array[
|
|
330
|
+
Dodopayments::ProductCreateParams::PricingMode::TaggedSymbol
|
|
331
|
+
]
|
|
332
|
+
)
|
|
333
|
+
end
|
|
334
|
+
def self.values
|
|
335
|
+
end
|
|
336
|
+
end
|
|
283
337
|
end
|
|
284
338
|
end
|
|
285
339
|
end
|
|
@@ -132,6 +132,16 @@ module Dodopayments
|
|
|
132
132
|
end
|
|
133
133
|
attr_accessor :price
|
|
134
134
|
|
|
135
|
+
# Update the pricing mode. Omit to leave unchanged; set to null to clear (which
|
|
136
|
+
# archives all active localized rules for this product). Changing to a different
|
|
137
|
+
# non-null mode also archives any rules whose mode doesn't match the new mode.
|
|
138
|
+
sig do
|
|
139
|
+
returns(
|
|
140
|
+
T.nilable(Dodopayments::ProductUpdateParams::PricingMode::OrSymbol)
|
|
141
|
+
)
|
|
142
|
+
end
|
|
143
|
+
attr_accessor :pricing_mode
|
|
144
|
+
|
|
135
145
|
# Tax category of the product.
|
|
136
146
|
sig { returns(T.nilable(Dodopayments::TaxCategory::OrSymbol)) }
|
|
137
147
|
attr_accessor :tax_category
|
|
@@ -166,6 +176,8 @@ module Dodopayments
|
|
|
166
176
|
Dodopayments::Price::UsageBasedPrice::OrHash
|
|
167
177
|
)
|
|
168
178
|
),
|
|
179
|
+
pricing_mode:
|
|
180
|
+
T.nilable(Dodopayments::ProductUpdateParams::PricingMode::OrSymbol),
|
|
169
181
|
tax_category: T.nilable(Dodopayments::TaxCategory::OrSymbol),
|
|
170
182
|
request_options: Dodopayments::RequestOptions::OrHash
|
|
171
183
|
).returns(T.attached_class)
|
|
@@ -223,6 +235,10 @@ module Dodopayments
|
|
|
223
235
|
name: nil,
|
|
224
236
|
# Price details of the product.
|
|
225
237
|
price: nil,
|
|
238
|
+
# Update the pricing mode. Omit to leave unchanged; set to null to clear (which
|
|
239
|
+
# archives all active localized rules for this product). Changing to a different
|
|
240
|
+
# non-null mode also archives any rules whose mode doesn't match the new mode.
|
|
241
|
+
pricing_mode: nil,
|
|
226
242
|
# Tax category of the product.
|
|
227
243
|
tax_category: nil,
|
|
228
244
|
request_options: {}
|
|
@@ -259,6 +275,10 @@ module Dodopayments
|
|
|
259
275
|
Dodopayments::Price::UsageBasedPrice
|
|
260
276
|
)
|
|
261
277
|
),
|
|
278
|
+
pricing_mode:
|
|
279
|
+
T.nilable(
|
|
280
|
+
Dodopayments::ProductUpdateParams::PricingMode::OrSymbol
|
|
281
|
+
),
|
|
262
282
|
tax_category: T.nilable(Dodopayments::TaxCategory::OrSymbol),
|
|
263
283
|
request_options: Dodopayments::RequestOptions
|
|
264
284
|
}
|
|
@@ -320,6 +340,40 @@ module Dodopayments
|
|
|
320
340
|
def to_hash
|
|
321
341
|
end
|
|
322
342
|
end
|
|
343
|
+
|
|
344
|
+
# Update the pricing mode. Omit to leave unchanged; set to null to clear (which
|
|
345
|
+
# archives all active localized rules for this product). Changing to a different
|
|
346
|
+
# non-null mode also archives any rules whose mode doesn't match the new mode.
|
|
347
|
+
module PricingMode
|
|
348
|
+
extend Dodopayments::Internal::Type::Enum
|
|
349
|
+
|
|
350
|
+
TaggedSymbol =
|
|
351
|
+
T.type_alias do
|
|
352
|
+
T.all(Symbol, Dodopayments::ProductUpdateParams::PricingMode)
|
|
353
|
+
end
|
|
354
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
355
|
+
|
|
356
|
+
BY_CURRENCY =
|
|
357
|
+
T.let(
|
|
358
|
+
:by_currency,
|
|
359
|
+
Dodopayments::ProductUpdateParams::PricingMode::TaggedSymbol
|
|
360
|
+
)
|
|
361
|
+
BY_COUNTRY =
|
|
362
|
+
T.let(
|
|
363
|
+
:by_country,
|
|
364
|
+
Dodopayments::ProductUpdateParams::PricingMode::TaggedSymbol
|
|
365
|
+
)
|
|
366
|
+
|
|
367
|
+
sig do
|
|
368
|
+
override.returns(
|
|
369
|
+
T::Array[
|
|
370
|
+
Dodopayments::ProductUpdateParams::PricingMode::TaggedSymbol
|
|
371
|
+
]
|
|
372
|
+
)
|
|
373
|
+
end
|
|
374
|
+
def self.values
|
|
375
|
+
end
|
|
376
|
+
end
|
|
323
377
|
end
|
|
324
378
|
end
|
|
325
379
|
end
|
|
@@ -8,6 +8,10 @@ module Dodopayments
|
|
|
8
8
|
T.any(Dodopayments::Refund, Dodopayments::Internal::AnyHash)
|
|
9
9
|
end
|
|
10
10
|
|
|
11
|
+
# Brand id this refund belongs to
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
attr_accessor :brand_id
|
|
14
|
+
|
|
11
15
|
# The unique identifier of the business issuing the refund.
|
|
12
16
|
sig { returns(String) }
|
|
13
17
|
attr_accessor :business_id
|
|
@@ -59,6 +63,7 @@ module Dodopayments
|
|
|
59
63
|
|
|
60
64
|
sig do
|
|
61
65
|
params(
|
|
66
|
+
brand_id: String,
|
|
62
67
|
business_id: String,
|
|
63
68
|
created_at: Time,
|
|
64
69
|
customer: Dodopayments::CustomerLimitedDetails::OrHash,
|
|
@@ -73,6 +78,8 @@ module Dodopayments
|
|
|
73
78
|
).returns(T.attached_class)
|
|
74
79
|
end
|
|
75
80
|
def self.new(
|
|
81
|
+
# Brand id this refund belongs to
|
|
82
|
+
brand_id:,
|
|
76
83
|
# The unique identifier of the business issuing the refund.
|
|
77
84
|
business_id:,
|
|
78
85
|
# The timestamp of when the refund was created in UTC.
|
|
@@ -101,6 +108,7 @@ module Dodopayments
|
|
|
101
108
|
sig do
|
|
102
109
|
override.returns(
|
|
103
110
|
{
|
|
111
|
+
brand_id: String,
|
|
104
112
|
business_id: String,
|
|
105
113
|
created_at: Time,
|
|
106
114
|
customer: Dodopayments::CustomerLimitedDetails,
|
|
@@ -19,6 +19,10 @@ module Dodopayments
|
|
|
19
19
|
sig { params(billing: Dodopayments::BillingAddress::OrHash).void }
|
|
20
20
|
attr_writer :billing
|
|
21
21
|
|
|
22
|
+
# Brand id this subscription belongs to
|
|
23
|
+
sig { returns(String) }
|
|
24
|
+
attr_accessor :brand_id
|
|
25
|
+
|
|
22
26
|
# Indicates if the subscription will cancel at the next billing date
|
|
23
27
|
sig { returns(T::Boolean) }
|
|
24
28
|
attr_accessor :cancel_at_next_billing_date
|
|
@@ -87,8 +91,8 @@ module Dodopayments
|
|
|
87
91
|
sig { returns(Integer) }
|
|
88
92
|
attr_accessor :quantity
|
|
89
93
|
|
|
90
|
-
# Amount charged before tax for each recurring payment in
|
|
91
|
-
# (
|
|
94
|
+
# Amount charged before tax for each recurring payment in the currency's smallest
|
|
95
|
+
# unit (cents for USD, yen for JPY, fils for KWD)
|
|
92
96
|
sig { returns(Integer) }
|
|
93
97
|
attr_accessor :recurring_pre_tax_amount
|
|
94
98
|
|
|
@@ -179,6 +183,7 @@ module Dodopayments
|
|
|
179
183
|
params(
|
|
180
184
|
addons: T::Array[Dodopayments::AddonCartResponseItem::OrHash],
|
|
181
185
|
billing: Dodopayments::BillingAddress::OrHash,
|
|
186
|
+
brand_id: String,
|
|
182
187
|
cancel_at_next_billing_date: T::Boolean,
|
|
183
188
|
created_at: Time,
|
|
184
189
|
credit_entitlement_cart:
|
|
@@ -225,6 +230,8 @@ module Dodopayments
|
|
|
225
230
|
addons:,
|
|
226
231
|
# Billing address details for payments
|
|
227
232
|
billing:,
|
|
233
|
+
# Brand id this subscription belongs to
|
|
234
|
+
brand_id:,
|
|
228
235
|
# Indicates if the subscription will cancel at the next billing date
|
|
229
236
|
cancel_at_next_billing_date:,
|
|
230
237
|
# Timestamp when the subscription was created
|
|
@@ -256,8 +263,8 @@ module Dodopayments
|
|
|
256
263
|
product_id:,
|
|
257
264
|
# Number of units/items included in the subscription
|
|
258
265
|
quantity:,
|
|
259
|
-
# Amount charged before tax for each recurring payment in
|
|
260
|
-
# (
|
|
266
|
+
# Amount charged before tax for each recurring payment in the currency's smallest
|
|
267
|
+
# unit (cents for USD, yen for JPY, fils for KWD)
|
|
261
268
|
recurring_pre_tax_amount:,
|
|
262
269
|
# Current status of the subscription
|
|
263
270
|
status:,
|
|
@@ -304,6 +311,7 @@ module Dodopayments
|
|
|
304
311
|
{
|
|
305
312
|
addons: T::Array[Dodopayments::AddonCartResponseItem],
|
|
306
313
|
billing: Dodopayments::BillingAddress,
|
|
314
|
+
brand_id: String,
|
|
307
315
|
cancel_at_next_billing_date: T::Boolean,
|
|
308
316
|
created_at: Time,
|
|
309
317
|
credit_entitlement_cart:
|
|
@@ -80,8 +80,8 @@ module Dodopayments
|
|
|
80
80
|
sig { returns(Integer) }
|
|
81
81
|
attr_accessor :quantity
|
|
82
82
|
|
|
83
|
-
# Amount charged before tax for each recurring payment in
|
|
84
|
-
# (
|
|
83
|
+
# Amount charged before tax for each recurring payment in the currency's smallest
|
|
84
|
+
# unit (cents for USD, yen for JPY, fils for KWD)
|
|
85
85
|
sig { returns(Integer) }
|
|
86
86
|
attr_accessor :recurring_pre_tax_amount
|
|
87
87
|
|
|
@@ -217,8 +217,8 @@ module Dodopayments
|
|
|
217
217
|
product_id:,
|
|
218
218
|
# Number of units/items included in the subscription
|
|
219
219
|
quantity:,
|
|
220
|
-
# Amount charged before tax for each recurring payment in
|
|
221
|
-
# (
|
|
220
|
+
# Amount charged before tax for each recurring payment in the currency's smallest
|
|
221
|
+
# unit (cents for USD, yen for JPY, fils for KWD)
|
|
222
222
|
recurring_pre_tax_amount:,
|
|
223
223
|
# Current status of the subscription
|
|
224
224
|
status:,
|
|
@@ -477,6 +477,11 @@ module Dodopayments
|
|
|
477
477
|
sig { returns(Dodopayments::Currency::TaggedSymbol) }
|
|
478
478
|
attr_accessor :currency
|
|
479
479
|
|
|
480
|
+
# Net credit movement in the smallest currency unit (e.g. cents). **Negative** –
|
|
481
|
+
# credits were deducted from the customer's balance to offset the charge (typical
|
|
482
|
+
# on upgrades). **Positive** – credits were added to the customer's balance,
|
|
483
|
+
# either from a downgrade proration refund or from topping-up the wallet to meet a
|
|
484
|
+
# gateway minimum-charge threshold. **Zero** – no credit movement occurred.
|
|
480
485
|
sig { returns(Integer) }
|
|
481
486
|
attr_accessor :customer_credits
|
|
482
487
|
|
|
@@ -508,6 +513,11 @@ module Dodopayments
|
|
|
508
513
|
end
|
|
509
514
|
def self.new(
|
|
510
515
|
currency:,
|
|
516
|
+
# Net credit movement in the smallest currency unit (e.g. cents). **Negative** –
|
|
517
|
+
# credits were deducted from the customer's balance to offset the charge (typical
|
|
518
|
+
# on upgrades). **Positive** – credits were added to the customer's balance,
|
|
519
|
+
# either from a downgrade proration refund or from topping-up the wallet to meet a
|
|
520
|
+
# gateway minimum-charge threshold. **Zero** – no credit movement occurred.
|
|
511
521
|
customer_credits:,
|
|
512
522
|
settlement_amount:,
|
|
513
523
|
settlement_currency:,
|
|
@@ -101,7 +101,8 @@ module Dodopayments
|
|
|
101
101
|
sig { returns(String) }
|
|
102
102
|
attr_accessor :price_per_unit
|
|
103
103
|
|
|
104
|
-
# Total price charged for this meter in
|
|
104
|
+
# Total price charged for this meter in the currency's smallest unit (cents for
|
|
105
|
+
# USD, yen for JPY, fils for KWD)
|
|
105
106
|
sig { returns(Integer) }
|
|
106
107
|
attr_accessor :total_price
|
|
107
108
|
|
|
@@ -132,7 +133,8 @@ module Dodopayments
|
|
|
132
133
|
name:,
|
|
133
134
|
# Price per unit in string format for precision
|
|
134
135
|
price_per_unit:,
|
|
135
|
-
# Total price charged for this meter in
|
|
136
|
+
# Total price charged for this meter in the currency's smallest unit (cents for
|
|
137
|
+
# USD, yen for JPY, fils for KWD)
|
|
136
138
|
total_price:
|
|
137
139
|
)
|
|
138
140
|
end
|
|
@@ -121,7 +121,7 @@ module Dodopayments
|
|
|
121
121
|
MD = T.let(:md, Dodopayments::ThemeConfig::FontSize::TaggedSymbol)
|
|
122
122
|
LG = T.let(:lg, Dodopayments::ThemeConfig::FontSize::TaggedSymbol)
|
|
123
123
|
XL = T.let(:xl, Dodopayments::ThemeConfig::FontSize::TaggedSymbol)
|
|
124
|
-
|
|
124
|
+
FONT_SIZE_2XL =
|
|
125
125
|
T.let(:"2xl", Dodopayments::ThemeConfig::FontSize::TaggedSymbol)
|
|
126
126
|
|
|
127
127
|
sig do
|
|
@@ -256,6 +256,10 @@ module Dodopayments
|
|
|
256
256
|
sig { returns(String) }
|
|
257
257
|
attr_accessor :available_balance
|
|
258
258
|
|
|
259
|
+
# Brand id this credit entitlement belongs to
|
|
260
|
+
sig { returns(String) }
|
|
261
|
+
attr_accessor :brand_id
|
|
262
|
+
|
|
259
263
|
sig { returns(String) }
|
|
260
264
|
attr_accessor :credit_entitlement_id
|
|
261
265
|
|
|
@@ -283,6 +287,7 @@ module Dodopayments
|
|
|
283
287
|
sig do
|
|
284
288
|
params(
|
|
285
289
|
available_balance: String,
|
|
290
|
+
brand_id: String,
|
|
286
291
|
credit_entitlement_id: String,
|
|
287
292
|
credit_entitlement_name: String,
|
|
288
293
|
customer_id: String,
|
|
@@ -295,6 +300,8 @@ module Dodopayments
|
|
|
295
300
|
end
|
|
296
301
|
def self.new(
|
|
297
302
|
available_balance:,
|
|
303
|
+
# Brand id this credit entitlement belongs to
|
|
304
|
+
brand_id:,
|
|
298
305
|
credit_entitlement_id:,
|
|
299
306
|
credit_entitlement_name:,
|
|
300
307
|
customer_id:,
|
|
@@ -310,6 +317,7 @@ module Dodopayments
|
|
|
310
317
|
override.returns(
|
|
311
318
|
{
|
|
312
319
|
available_balance: String,
|
|
320
|
+
brand_id: String,
|
|
313
321
|
credit_entitlement_id: String,
|
|
314
322
|
credit_entitlement_name: String,
|
|
315
323
|
customer_id: String,
|
|
@@ -344,6 +352,10 @@ module Dodopayments
|
|
|
344
352
|
end
|
|
345
353
|
attr_accessor :abandonment_reason
|
|
346
354
|
|
|
355
|
+
# Brand id this abandoned checkout belongs to
|
|
356
|
+
sig { returns(String) }
|
|
357
|
+
attr_accessor :brand_id
|
|
358
|
+
|
|
347
359
|
sig { returns(String) }
|
|
348
360
|
attr_accessor :customer_id
|
|
349
361
|
|
|
@@ -368,6 +380,7 @@ module Dodopayments
|
|
|
368
380
|
abandoned_at: Time,
|
|
369
381
|
abandonment_reason:
|
|
370
382
|
Dodopayments::WebhookPayload::Data::AbandonedCheckout::AbandonmentReason::OrSymbol,
|
|
383
|
+
brand_id: String,
|
|
371
384
|
customer_id: String,
|
|
372
385
|
payment_id: String,
|
|
373
386
|
status:
|
|
@@ -379,6 +392,8 @@ module Dodopayments
|
|
|
379
392
|
def self.new(
|
|
380
393
|
abandoned_at:,
|
|
381
394
|
abandonment_reason:,
|
|
395
|
+
# Brand id this abandoned checkout belongs to
|
|
396
|
+
brand_id:,
|
|
382
397
|
customer_id:,
|
|
383
398
|
payment_id:,
|
|
384
399
|
status:,
|
|
@@ -393,6 +408,7 @@ module Dodopayments
|
|
|
393
408
|
abandoned_at: Time,
|
|
394
409
|
abandonment_reason:
|
|
395
410
|
Dodopayments::WebhookPayload::Data::AbandonedCheckout::AbandonmentReason::OrSymbol,
|
|
411
|
+
brand_id: String,
|
|
396
412
|
customer_id: String,
|
|
397
413
|
payload_type: Symbol,
|
|
398
414
|
payment_id: String,
|
|
@@ -498,6 +514,10 @@ module Dodopayments
|
|
|
498
514
|
)
|
|
499
515
|
end
|
|
500
516
|
|
|
517
|
+
# Brand id this dunning attempt belongs to
|
|
518
|
+
sig { returns(String) }
|
|
519
|
+
attr_accessor :brand_id
|
|
520
|
+
|
|
501
521
|
sig { returns(Time) }
|
|
502
522
|
attr_accessor :created_at
|
|
503
523
|
|
|
@@ -529,6 +549,7 @@ module Dodopayments
|
|
|
529
549
|
|
|
530
550
|
sig do
|
|
531
551
|
params(
|
|
552
|
+
brand_id: String,
|
|
532
553
|
created_at: Time,
|
|
533
554
|
customer_id: String,
|
|
534
555
|
status:
|
|
@@ -541,6 +562,8 @@ module Dodopayments
|
|
|
541
562
|
).returns(T.attached_class)
|
|
542
563
|
end
|
|
543
564
|
def self.new(
|
|
565
|
+
# Brand id this dunning attempt belongs to
|
|
566
|
+
brand_id:,
|
|
544
567
|
created_at:,
|
|
545
568
|
customer_id:,
|
|
546
569
|
status:,
|
|
@@ -554,6 +577,7 @@ module Dodopayments
|
|
|
554
577
|
sig do
|
|
555
578
|
override.returns(
|
|
556
579
|
{
|
|
580
|
+
brand_id: String,
|
|
557
581
|
created_at: Time,
|
|
558
582
|
customer_id: String,
|
|
559
583
|
payload_type: Symbol,
|
|
@@ -9,8 +9,6 @@ module Dodopayments
|
|
|
9
9
|
params(
|
|
10
10
|
id: String,
|
|
11
11
|
customer_id: String,
|
|
12
|
-
integration_type:
|
|
13
|
-
Dodopayments::Entitlements::GrantListParams::IntegrationType::OrSymbol,
|
|
14
12
|
page_number: Integer,
|
|
15
13
|
page_size: Integer,
|
|
16
14
|
status:
|
|
@@ -27,8 +25,6 @@ module Dodopayments
|
|
|
27
25
|
id,
|
|
28
26
|
# Filter by customer ID
|
|
29
27
|
customer_id: nil,
|
|
30
|
-
# Filter by integration type
|
|
31
|
-
integration_type: nil,
|
|
32
28
|
# Page number (default 0)
|
|
33
29
|
page_number: nil,
|
|
34
30
|
# Page size (default 10, max 100)
|