dodopayments 1.18.3 → 1.20.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 +44 -0
- data/README.md +5 -5
- data/lib/dodopayments/client.rb +12 -9
- data/lib/dodopayments/errors.rb +9 -9
- data/lib/dodopayments/file_part.rb +5 -5
- data/lib/dodopayments/internal/transport/base_client.rb +1 -1
- data/lib/dodopayments/internal/type/boolean.rb +10 -11
- data/lib/dodopayments/internal/type/converter.rb +3 -0
- data/lib/dodopayments/internal/type/enum.rb +10 -11
- data/lib/dodopayments/internal/type/file_input.rb +22 -11
- data/lib/dodopayments/internal/type/unknown.rb +10 -11
- data/lib/dodopayments/internal/util.rb +3 -3
- data/lib/dodopayments/models/addon_cart_response_item.rb +23 -0
- data/lib/dodopayments/models/addon_create_params.rb +58 -0
- data/lib/dodopayments/models/addon_list_params.rb +30 -0
- data/lib/dodopayments/models/addon_response.rb +93 -0
- data/lib/dodopayments/models/addon_retrieve_params.rb +14 -0
- data/lib/dodopayments/models/addon_update_images_params.rb +14 -0
- data/lib/dodopayments/models/addon_update_images_response.rb +22 -0
- data/lib/dodopayments/models/addon_update_params.rb +66 -0
- data/lib/dodopayments/models/currency.rb +158 -0
- data/lib/dodopayments/models/misc_list_supported_countries_response.rb +1 -0
- data/lib/dodopayments/models/payment.rb +14 -315
- data/lib/dodopayments/models/payment_create_params.rb +3 -158
- data/lib/dodopayments/models/payment_list_response.rb +3 -157
- data/lib/dodopayments/models/payout_list_response.rb +3 -157
- data/lib/dodopayments/models/price.rb +6 -314
- data/lib/dodopayments/models/product.rb +3 -19
- data/lib/dodopayments/models/product_create_params.rb +3 -17
- data/lib/dodopayments/models/product_list_response.rb +6 -176
- data/lib/dodopayments/models/product_update_params.rb +3 -17
- data/lib/dodopayments/models/refund.rb +3 -157
- data/lib/dodopayments/models/subscription.rb +21 -158
- data/lib/dodopayments/models/subscription_create_params.rb +30 -159
- data/lib/dodopayments/models/subscription_create_response.rb +10 -1
- data/lib/dodopayments/models/subscription_list_response.rb +179 -0
- data/lib/dodopayments/models/subscription_update_params.rb +19 -1
- data/lib/dodopayments/models/tax_category.rb +19 -0
- data/lib/dodopayments/request_options.rb +4 -5
- data/lib/dodopayments/resources/addons.rb +141 -0
- data/lib/dodopayments/resources/payments.rb +1 -1
- data/lib/dodopayments/resources/products.rb +2 -2
- data/lib/dodopayments/resources/subscriptions.rb +9 -5
- data/lib/dodopayments/version.rb +1 -1
- data/lib/dodopayments.rb +12 -0
- data/rbi/{lib/dodopayments → dodopayments}/client.rbi +7 -5
- data/rbi/{lib/dodopayments → dodopayments}/errors.rbi +1 -1
- data/rbi/{lib/dodopayments → dodopayments}/internal/transport/base_client.rbi +2 -2
- data/rbi/{lib/dodopayments → dodopayments}/internal/type/request_parameters.rbi +1 -1
- data/rbi/dodopayments/models/addon_cart_response_item.rbi +20 -0
- data/rbi/dodopayments/models/addon_create_params.rbi +69 -0
- data/rbi/dodopayments/models/addon_list_params.rbi +45 -0
- data/rbi/dodopayments/models/addon_response.rbi +103 -0
- data/rbi/dodopayments/models/addon_retrieve_params.rbi +19 -0
- data/rbi/dodopayments/models/addon_update_images_params.rbi +19 -0
- data/rbi/dodopayments/models/addon_update_images_response.rbi +19 -0
- data/rbi/dodopayments/models/addon_update_params.rbi +77 -0
- data/rbi/dodopayments/models/currency.rbi +161 -0
- data/rbi/dodopayments/models/payment.rbi +227 -0
- data/rbi/dodopayments/models/payment_create_params.rbi +189 -0
- data/rbi/dodopayments/models/payment_list_response.rbi +88 -0
- data/rbi/dodopayments/models/payout_list_response.rbi +155 -0
- data/rbi/dodopayments/models/price.rbi +218 -0
- data/rbi/{lib/dodopayments → dodopayments}/models/product.rbi +3 -20
- data/rbi/{lib/dodopayments → dodopayments}/models/product_create_params.rbi +3 -21
- data/rbi/dodopayments/models/product_list_response.rbi +153 -0
- data/rbi/{lib/dodopayments → dodopayments}/models/product_update_params.rbi +3 -21
- data/rbi/dodopayments/models/refund.rbi +83 -0
- data/rbi/dodopayments/models/subscription.rbi +198 -0
- data/rbi/dodopayments/models/subscription_create_params.rbi +282 -0
- data/rbi/{lib/dodopayments → dodopayments}/models/subscription_create_response.rbi +8 -0
- data/rbi/dodopayments/models/subscription_list_response.rbi +190 -0
- data/rbi/{lib/dodopayments → dodopayments}/models/subscription_update_params.rbi +37 -1
- data/rbi/dodopayments/models/tax_category.rbi +22 -0
- data/rbi/{lib/dodopayments → dodopayments}/request_options.rbi +2 -0
- data/rbi/dodopayments/resources/addons.rbi +97 -0
- data/rbi/{lib/dodopayments → dodopayments}/resources/customers/customer_portal.rbi +1 -1
- data/rbi/{lib/dodopayments → dodopayments}/resources/customers.rbi +4 -7
- data/rbi/{lib/dodopayments → dodopayments}/resources/discounts.rbi +5 -14
- data/rbi/{lib/dodopayments → dodopayments}/resources/disputes.rbi +2 -5
- data/rbi/{lib/dodopayments → dodopayments}/resources/invoices/payments.rbi +1 -7
- data/rbi/{lib/dodopayments → dodopayments}/resources/license_key_instances.rbi +3 -10
- data/rbi/{lib/dodopayments → dodopayments}/resources/license_keys.rbi +3 -9
- data/rbi/{lib/dodopayments → dodopayments}/resources/licenses.rbi +3 -7
- data/rbi/{lib/dodopayments → dodopayments}/resources/misc.rbi +1 -8
- data/rbi/{lib/dodopayments → dodopayments}/resources/payments.rbi +4 -7
- data/rbi/{lib/dodopayments → dodopayments}/resources/payouts.rbi +1 -1
- data/rbi/{lib/dodopayments → dodopayments}/resources/products/images.rbi +1 -5
- data/rbi/{lib/dodopayments → dodopayments}/resources/products.rbi +8 -26
- data/rbi/{lib/dodopayments → dodopayments}/resources/refunds.rbi +3 -11
- data/rbi/{lib/dodopayments → dodopayments}/resources/subscriptions.rbi +19 -15
- data/rbi/{lib/dodopayments → dodopayments}/resources/webhook_events.rbi +2 -5
- data/sig/dodopayments/client.rbs +4 -2
- data/sig/dodopayments/models/addon_cart_response_item.rbs +15 -0
- data/sig/dodopayments/models/addon_create_params.rbs +39 -0
- data/sig/dodopayments/models/addon_list_params.rbs +24 -0
- data/sig/dodopayments/models/addon_response.rbs +54 -0
- data/sig/dodopayments/models/addon_retrieve_params.rbs +15 -0
- data/sig/dodopayments/models/addon_update_images_params.rbs +15 -0
- data/sig/dodopayments/models/addon_update_images_response.rbs +15 -0
- data/sig/dodopayments/models/addon_update_params.rbs +43 -0
- data/sig/dodopayments/models/currency.rbs +302 -0
- data/sig/dodopayments/models/misc_list_supported_countries_response.rbs +1 -1
- data/sig/dodopayments/models/payment.rbs +10 -604
- data/sig/dodopayments/models/payment_create_params.rbs +3 -302
- data/sig/dodopayments/models/payment_list_response.rbs +3 -302
- data/sig/dodopayments/models/payout_list_response.rbs +3 -302
- data/sig/dodopayments/models/price.rbs +6 -604
- data/sig/dodopayments/models/product.rbs +3 -16
- data/sig/dodopayments/models/product_create_params.rbs +3 -16
- data/sig/dodopayments/models/product_list_response.rbs +6 -318
- data/sig/dodopayments/models/product_update_params.rbs +3 -16
- data/sig/dodopayments/models/refund.rbs +3 -302
- data/sig/dodopayments/models/subscription.rbs +11 -302
- data/sig/dodopayments/models/subscription_create_params.rbs +19 -302
- data/sig/dodopayments/models/subscription_create_response.rbs +4 -0
- data/sig/dodopayments/models/subscription_list_response.rbs +98 -0
- data/sig/dodopayments/models/subscription_update_params.rbs +14 -0
- data/sig/dodopayments/models/tax_category.rbs +16 -0
- data/sig/dodopayments/resources/addons.rbs +43 -0
- data/sig/dodopayments/resources/payments.rbs +1 -1
- data/sig/dodopayments/resources/products.rbs +2 -2
- data/sig/dodopayments/resources/subscriptions.rbs +4 -2
- metadata +160 -124
- data/rbi/lib/dodopayments/models/payment.rbi +0 -530
- data/rbi/lib/dodopayments/models/payment_create_params.rbi +0 -345
- data/rbi/lib/dodopayments/models/payment_list_response.rbi +0 -244
- data/rbi/lib/dodopayments/models/payout_list_response.rbi +0 -311
- data/rbi/lib/dodopayments/models/price.rbi +0 -530
- data/rbi/lib/dodopayments/models/product_list_response.rbi +0 -327
- data/rbi/lib/dodopayments/models/refund.rbi +0 -239
- data/rbi/lib/dodopayments/models/subscription.rbi +0 -338
- data/rbi/lib/dodopayments/models/subscription_create_params.rbi +0 -415
- /data/rbi/{lib/dodopayments → dodopayments}/file_part.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/default_page_number_pagination.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/transport/pooled_net_requester.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/array_of.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/base_model.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/base_page.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/boolean.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/converter.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/enum.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/file_input.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/hash_of.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/union.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/type/unknown.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal/util.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/internal.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/attach_existing_customer.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/billing_address.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/country_code.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/create_new_customer.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer_create_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer_limited_details.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer_portal_session.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer_request.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customer_update_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/customers/customer_portal_create_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/discount.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/discount_create_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/discount_delete_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/discount_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/discount_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/discount_type.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/discount_update_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/dispute.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/dispute_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/dispute_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/dispute_stage.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/dispute_status.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/intent_status.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/invoices/payment_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_activate_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_deactivate_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_duration.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_instance.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_instance_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_instance_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_instance_update_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_status.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_key_update_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_validate_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/license_validate_response.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/misc_list_supported_countries_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/misc_list_supported_countries_response.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/one_time_product_cart_item.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/payment_create_response.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/payment_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/payment_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/payout_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/product_delete_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/product_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/product_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/product_unarchive_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/products/image_update_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/products/image_update_response.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/refund_create_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/refund_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/refund_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/refund_status.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/subscription_change_plan_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/subscription_charge_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/subscription_charge_response.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/subscription_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/subscription_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/subscription_status.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/time_interval.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/webhook_event.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/webhook_event_list_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/models/webhook_event_retrieve_params.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/resources/invoices.rbi +0 -0
- /data/rbi/{lib/dodopayments → dodopayments}/version.rbi +0 -0
@@ -0,0 +1,190 @@
|
|
1
|
+
# typed: strong
|
2
|
+
|
3
|
+
module Dodopayments
|
4
|
+
module Models
|
5
|
+
class SubscriptionListResponse < Dodopayments::Internal::Type::BaseModel
|
6
|
+
sig { returns(Dodopayments::Models::BillingAddress) }
|
7
|
+
attr_reader :billing
|
8
|
+
|
9
|
+
sig { params(billing: T.any(Dodopayments::Models::BillingAddress, Dodopayments::Internal::AnyHash)).void }
|
10
|
+
attr_writer :billing
|
11
|
+
|
12
|
+
# Timestamp when the subscription was created
|
13
|
+
sig { returns(Time) }
|
14
|
+
attr_accessor :created_at
|
15
|
+
|
16
|
+
sig { returns(Dodopayments::Models::Currency::TaggedSymbol) }
|
17
|
+
attr_accessor :currency
|
18
|
+
|
19
|
+
sig { returns(Dodopayments::Models::CustomerLimitedDetails) }
|
20
|
+
attr_reader :customer
|
21
|
+
|
22
|
+
sig do
|
23
|
+
params(customer: T.any(Dodopayments::Models::CustomerLimitedDetails, Dodopayments::Internal::AnyHash)).void
|
24
|
+
end
|
25
|
+
attr_writer :customer
|
26
|
+
|
27
|
+
sig { returns(T::Hash[Symbol, String]) }
|
28
|
+
attr_accessor :metadata
|
29
|
+
|
30
|
+
# Timestamp of the next scheduled billing. Indicates the end of current billing
|
31
|
+
# period
|
32
|
+
sig { returns(Time) }
|
33
|
+
attr_accessor :next_billing_date
|
34
|
+
|
35
|
+
# Wether the subscription is on-demand or not
|
36
|
+
sig { returns(T::Boolean) }
|
37
|
+
attr_accessor :on_demand
|
38
|
+
|
39
|
+
# Number of payment frequency intervals
|
40
|
+
sig { returns(Integer) }
|
41
|
+
attr_accessor :payment_frequency_count
|
42
|
+
|
43
|
+
sig { returns(Dodopayments::Models::TimeInterval::TaggedSymbol) }
|
44
|
+
attr_accessor :payment_frequency_interval
|
45
|
+
|
46
|
+
# Timestamp of the last payment. Indicates the start of current billing period
|
47
|
+
sig { returns(Time) }
|
48
|
+
attr_accessor :previous_billing_date
|
49
|
+
|
50
|
+
# Identifier of the product associated with this subscription
|
51
|
+
sig { returns(String) }
|
52
|
+
attr_accessor :product_id
|
53
|
+
|
54
|
+
# Number of units/items included in the subscription
|
55
|
+
sig { returns(Integer) }
|
56
|
+
attr_accessor :quantity
|
57
|
+
|
58
|
+
# Amount charged before tax for each recurring payment in smallest currency unit
|
59
|
+
# (e.g. cents)
|
60
|
+
sig { returns(Integer) }
|
61
|
+
attr_accessor :recurring_pre_tax_amount
|
62
|
+
|
63
|
+
sig { returns(Dodopayments::Models::SubscriptionStatus::TaggedSymbol) }
|
64
|
+
attr_accessor :status
|
65
|
+
|
66
|
+
# Unique identifier for the subscription
|
67
|
+
sig { returns(String) }
|
68
|
+
attr_accessor :subscription_id
|
69
|
+
|
70
|
+
# Number of subscription period intervals
|
71
|
+
sig { returns(Integer) }
|
72
|
+
attr_accessor :subscription_period_count
|
73
|
+
|
74
|
+
sig { returns(Dodopayments::Models::TimeInterval::TaggedSymbol) }
|
75
|
+
attr_accessor :subscription_period_interval
|
76
|
+
|
77
|
+
# Indicates if the recurring_pre_tax_amount is tax inclusive
|
78
|
+
sig { returns(T::Boolean) }
|
79
|
+
attr_accessor :tax_inclusive
|
80
|
+
|
81
|
+
# Number of days in the trial period (0 if no trial)
|
82
|
+
sig { returns(Integer) }
|
83
|
+
attr_accessor :trial_period_days
|
84
|
+
|
85
|
+
# Cancelled timestamp if the subscription is cancelled
|
86
|
+
sig { returns(T.nilable(Time)) }
|
87
|
+
attr_accessor :cancelled_at
|
88
|
+
|
89
|
+
# The discount id if discount is applied
|
90
|
+
sig { returns(T.nilable(String)) }
|
91
|
+
attr_accessor :discount_id
|
92
|
+
|
93
|
+
# Response struct representing subscription details
|
94
|
+
sig do
|
95
|
+
params(
|
96
|
+
billing: T.any(Dodopayments::Models::BillingAddress, Dodopayments::Internal::AnyHash),
|
97
|
+
created_at: Time,
|
98
|
+
currency: Dodopayments::Models::Currency::OrSymbol,
|
99
|
+
customer: T.any(Dodopayments::Models::CustomerLimitedDetails, Dodopayments::Internal::AnyHash),
|
100
|
+
metadata: T::Hash[Symbol, String],
|
101
|
+
next_billing_date: Time,
|
102
|
+
on_demand: T::Boolean,
|
103
|
+
payment_frequency_count: Integer,
|
104
|
+
payment_frequency_interval: Dodopayments::Models::TimeInterval::OrSymbol,
|
105
|
+
previous_billing_date: Time,
|
106
|
+
product_id: String,
|
107
|
+
quantity: Integer,
|
108
|
+
recurring_pre_tax_amount: Integer,
|
109
|
+
status: Dodopayments::Models::SubscriptionStatus::OrSymbol,
|
110
|
+
subscription_id: String,
|
111
|
+
subscription_period_count: Integer,
|
112
|
+
subscription_period_interval: Dodopayments::Models::TimeInterval::OrSymbol,
|
113
|
+
tax_inclusive: T::Boolean,
|
114
|
+
trial_period_days: Integer,
|
115
|
+
cancelled_at: T.nilable(Time),
|
116
|
+
discount_id: T.nilable(String)
|
117
|
+
)
|
118
|
+
.returns(T.attached_class)
|
119
|
+
end
|
120
|
+
def self.new(
|
121
|
+
billing:,
|
122
|
+
# Timestamp when the subscription was created
|
123
|
+
created_at:,
|
124
|
+
currency:,
|
125
|
+
customer:,
|
126
|
+
metadata:,
|
127
|
+
# Timestamp of the next scheduled billing. Indicates the end of current billing
|
128
|
+
# period
|
129
|
+
next_billing_date:,
|
130
|
+
# Wether the subscription is on-demand or not
|
131
|
+
on_demand:,
|
132
|
+
# Number of payment frequency intervals
|
133
|
+
payment_frequency_count:,
|
134
|
+
payment_frequency_interval:,
|
135
|
+
# Timestamp of the last payment. Indicates the start of current billing period
|
136
|
+
previous_billing_date:,
|
137
|
+
# Identifier of the product associated with this subscription
|
138
|
+
product_id:,
|
139
|
+
# Number of units/items included in the subscription
|
140
|
+
quantity:,
|
141
|
+
# Amount charged before tax for each recurring payment in smallest currency unit
|
142
|
+
# (e.g. cents)
|
143
|
+
recurring_pre_tax_amount:,
|
144
|
+
status:,
|
145
|
+
# Unique identifier for the subscription
|
146
|
+
subscription_id:,
|
147
|
+
# Number of subscription period intervals
|
148
|
+
subscription_period_count:,
|
149
|
+
subscription_period_interval:,
|
150
|
+
# Indicates if the recurring_pre_tax_amount is tax inclusive
|
151
|
+
tax_inclusive:,
|
152
|
+
# Number of days in the trial period (0 if no trial)
|
153
|
+
trial_period_days:,
|
154
|
+
# Cancelled timestamp if the subscription is cancelled
|
155
|
+
cancelled_at: nil,
|
156
|
+
# The discount id if discount is applied
|
157
|
+
discount_id: nil
|
158
|
+
); end
|
159
|
+
sig do
|
160
|
+
override
|
161
|
+
.returns(
|
162
|
+
{
|
163
|
+
billing: Dodopayments::Models::BillingAddress,
|
164
|
+
created_at: Time,
|
165
|
+
currency: Dodopayments::Models::Currency::TaggedSymbol,
|
166
|
+
customer: Dodopayments::Models::CustomerLimitedDetails,
|
167
|
+
metadata: T::Hash[Symbol, String],
|
168
|
+
next_billing_date: Time,
|
169
|
+
on_demand: T::Boolean,
|
170
|
+
payment_frequency_count: Integer,
|
171
|
+
payment_frequency_interval: Dodopayments::Models::TimeInterval::TaggedSymbol,
|
172
|
+
previous_billing_date: Time,
|
173
|
+
product_id: String,
|
174
|
+
quantity: Integer,
|
175
|
+
recurring_pre_tax_amount: Integer,
|
176
|
+
status: Dodopayments::Models::SubscriptionStatus::TaggedSymbol,
|
177
|
+
subscription_id: String,
|
178
|
+
subscription_period_count: Integer,
|
179
|
+
subscription_period_interval: Dodopayments::Models::TimeInterval::TaggedSymbol,
|
180
|
+
tax_inclusive: T::Boolean,
|
181
|
+
trial_period_days: Integer,
|
182
|
+
cancelled_at: T.nilable(Time),
|
183
|
+
discount_id: T.nilable(String)
|
184
|
+
}
|
185
|
+
)
|
186
|
+
end
|
187
|
+
def to_hash; end
|
188
|
+
end
|
189
|
+
end
|
190
|
+
end
|
@@ -15,6 +15,19 @@ module Dodopayments
|
|
15
15
|
end
|
16
16
|
attr_writer :billing
|
17
17
|
|
18
|
+
sig { returns(T.nilable(Dodopayments::Models::SubscriptionUpdateParams::DisableOnDemand)) }
|
19
|
+
attr_reader :disable_on_demand
|
20
|
+
|
21
|
+
sig do
|
22
|
+
params(
|
23
|
+
disable_on_demand: T.nilable(
|
24
|
+
T.any(Dodopayments::Models::SubscriptionUpdateParams::DisableOnDemand, Dodopayments::Internal::AnyHash)
|
25
|
+
)
|
26
|
+
)
|
27
|
+
.void
|
28
|
+
end
|
29
|
+
attr_writer :disable_on_demand
|
30
|
+
|
18
31
|
sig { returns(T.nilable(T::Hash[Symbol, String])) }
|
19
32
|
attr_accessor :metadata
|
20
33
|
|
@@ -27,6 +40,9 @@ module Dodopayments
|
|
27
40
|
sig do
|
28
41
|
params(
|
29
42
|
billing: T.nilable(T.any(Dodopayments::Models::BillingAddress, Dodopayments::Internal::AnyHash)),
|
43
|
+
disable_on_demand: T.nilable(
|
44
|
+
T.any(Dodopayments::Models::SubscriptionUpdateParams::DisableOnDemand, Dodopayments::Internal::AnyHash)
|
45
|
+
),
|
30
46
|
metadata: T.nilable(T::Hash[Symbol, String]),
|
31
47
|
status: T.nilable(Dodopayments::Models::SubscriptionStatus::OrSymbol),
|
32
48
|
tax_id: T.nilable(String),
|
@@ -34,13 +50,22 @@ module Dodopayments
|
|
34
50
|
)
|
35
51
|
.returns(T.attached_class)
|
36
52
|
end
|
37
|
-
def self.new(
|
53
|
+
def self.new(
|
54
|
+
billing: nil,
|
55
|
+
disable_on_demand: nil,
|
56
|
+
metadata: nil,
|
57
|
+
status: nil,
|
58
|
+
tax_id: nil,
|
59
|
+
request_options: {}
|
60
|
+
)
|
61
|
+
end
|
38
62
|
|
39
63
|
sig do
|
40
64
|
override
|
41
65
|
.returns(
|
42
66
|
{
|
43
67
|
billing: T.nilable(Dodopayments::Models::BillingAddress),
|
68
|
+
disable_on_demand: T.nilable(Dodopayments::Models::SubscriptionUpdateParams::DisableOnDemand),
|
44
69
|
metadata: T.nilable(T::Hash[Symbol, String]),
|
45
70
|
status: T.nilable(Dodopayments::Models::SubscriptionStatus::OrSymbol),
|
46
71
|
tax_id: T.nilable(String),
|
@@ -49,6 +74,17 @@ module Dodopayments
|
|
49
74
|
)
|
50
75
|
end
|
51
76
|
def to_hash; end
|
77
|
+
|
78
|
+
class DisableOnDemand < Dodopayments::Internal::Type::BaseModel
|
79
|
+
sig { returns(Time) }
|
80
|
+
attr_accessor :next_billing_date
|
81
|
+
|
82
|
+
sig { params(next_billing_date: Time).returns(T.attached_class) }
|
83
|
+
def self.new(next_billing_date:); end
|
84
|
+
|
85
|
+
sig { override.returns({next_billing_date: Time}) }
|
86
|
+
def to_hash; end
|
87
|
+
end
|
52
88
|
end
|
53
89
|
end
|
54
90
|
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# typed: strong
|
2
|
+
|
3
|
+
module Dodopayments
|
4
|
+
module Models
|
5
|
+
# Represents the different categories of taxation applicable to various products
|
6
|
+
# and services.
|
7
|
+
module TaxCategory
|
8
|
+
extend Dodopayments::Internal::Type::Enum
|
9
|
+
|
10
|
+
TaggedSymbol = T.type_alias { T.all(Symbol, Dodopayments::Models::TaxCategory) }
|
11
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
12
|
+
|
13
|
+
DIGITAL_PRODUCTS = T.let(:digital_products, Dodopayments::Models::TaxCategory::TaggedSymbol)
|
14
|
+
SAAS = T.let(:saas, Dodopayments::Models::TaxCategory::TaggedSymbol)
|
15
|
+
E_BOOK = T.let(:e_book, Dodopayments::Models::TaxCategory::TaggedSymbol)
|
16
|
+
EDTECH = T.let(:edtech, Dodopayments::Models::TaxCategory::TaggedSymbol)
|
17
|
+
|
18
|
+
sig { override.returns(T::Array[Dodopayments::Models::TaxCategory::TaggedSymbol]) }
|
19
|
+
def self.values; end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
@@ -1,6 +1,8 @@
|
|
1
1
|
# typed: strong
|
2
2
|
|
3
3
|
module Dodopayments
|
4
|
+
RequestOpts = T.type_alias { T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash) }
|
5
|
+
|
4
6
|
# Specify HTTP behaviour to use for a specific request. These options supplement
|
5
7
|
# or override those provided at the client level.
|
6
8
|
#
|
@@ -0,0 +1,97 @@
|
|
1
|
+
# typed: strong
|
2
|
+
|
3
|
+
module Dodopayments
|
4
|
+
module Resources
|
5
|
+
class Addons
|
6
|
+
sig do
|
7
|
+
params(
|
8
|
+
currency: Dodopayments::Models::Currency::OrSymbol,
|
9
|
+
name: String,
|
10
|
+
price: Integer,
|
11
|
+
tax_category: Dodopayments::Models::TaxCategory::OrSymbol,
|
12
|
+
description: T.nilable(String),
|
13
|
+
request_options: Dodopayments::RequestOpts
|
14
|
+
)
|
15
|
+
.returns(Dodopayments::Models::AddonResponse)
|
16
|
+
end
|
17
|
+
def create(
|
18
|
+
currency:,
|
19
|
+
# Name of the Addon
|
20
|
+
name:,
|
21
|
+
# Amount of the addon
|
22
|
+
price:,
|
23
|
+
# Represents the different categories of taxation applicable to various products
|
24
|
+
# and services.
|
25
|
+
tax_category:,
|
26
|
+
# Optional description of the Addon
|
27
|
+
description: nil,
|
28
|
+
request_options: {}
|
29
|
+
); end
|
30
|
+
sig do
|
31
|
+
params(id: String, request_options: Dodopayments::RequestOpts).returns(Dodopayments::Models::AddonResponse)
|
32
|
+
end
|
33
|
+
def retrieve(
|
34
|
+
# Addon Id
|
35
|
+
id,
|
36
|
+
request_options: {}
|
37
|
+
); end
|
38
|
+
sig do
|
39
|
+
params(
|
40
|
+
id: String,
|
41
|
+
currency: T.nilable(Dodopayments::Models::Currency::OrSymbol),
|
42
|
+
description: T.nilable(String),
|
43
|
+
image_id: T.nilable(String),
|
44
|
+
name: T.nilable(String),
|
45
|
+
price: T.nilable(Integer),
|
46
|
+
tax_category: T.nilable(Dodopayments::Models::TaxCategory::OrSymbol),
|
47
|
+
request_options: Dodopayments::RequestOpts
|
48
|
+
)
|
49
|
+
.returns(Dodopayments::Models::AddonResponse)
|
50
|
+
end
|
51
|
+
def update(
|
52
|
+
# Addon Id
|
53
|
+
id,
|
54
|
+
currency: nil,
|
55
|
+
# Description of the Addon, optional and must be at most 1000 characters.
|
56
|
+
description: nil,
|
57
|
+
# Addon image id after its uploaded to S3
|
58
|
+
image_id: nil,
|
59
|
+
# Name of the Addon, optional and must be at most 100 characters.
|
60
|
+
name: nil,
|
61
|
+
# Amount of the addon
|
62
|
+
price: nil,
|
63
|
+
# Represents the different categories of taxation applicable to various products
|
64
|
+
# and services.
|
65
|
+
tax_category: nil,
|
66
|
+
request_options: {}
|
67
|
+
); end
|
68
|
+
sig do
|
69
|
+
params(
|
70
|
+
page_number: T.nilable(Integer),
|
71
|
+
page_size: T.nilable(Integer),
|
72
|
+
request_options: Dodopayments::RequestOpts
|
73
|
+
)
|
74
|
+
.returns(Dodopayments::Internal::DefaultPageNumberPagination[Dodopayments::Models::AddonResponse])
|
75
|
+
end
|
76
|
+
def list(
|
77
|
+
# Page number default is 0
|
78
|
+
page_number: nil,
|
79
|
+
# Page size default is 10 max is 100
|
80
|
+
page_size: nil,
|
81
|
+
request_options: {}
|
82
|
+
); end
|
83
|
+
sig do
|
84
|
+
params(id: String, request_options: Dodopayments::RequestOpts)
|
85
|
+
.returns(Dodopayments::Models::AddonUpdateImagesResponse)
|
86
|
+
end
|
87
|
+
def update_images(
|
88
|
+
# Addon Id
|
89
|
+
id,
|
90
|
+
request_options: {}
|
91
|
+
); end
|
92
|
+
# @api private
|
93
|
+
sig { params(client: Dodopayments::Client).returns(T.attached_class) }
|
94
|
+
def self.new(client:); end
|
95
|
+
end
|
96
|
+
end
|
97
|
+
end
|
@@ -8,7 +8,7 @@ module Dodopayments
|
|
8
8
|
params(
|
9
9
|
customer_id: String,
|
10
10
|
send_email: T.nilable(T::Boolean),
|
11
|
-
request_options:
|
11
|
+
request_options: Dodopayments::RequestOpts
|
12
12
|
)
|
13
13
|
.returns(Dodopayments::Models::CustomerPortalSession)
|
14
14
|
end
|
@@ -11,17 +11,14 @@ module Dodopayments
|
|
11
11
|
email: String,
|
12
12
|
name: String,
|
13
13
|
phone_number: T.nilable(String),
|
14
|
-
request_options:
|
14
|
+
request_options: Dodopayments::RequestOpts
|
15
15
|
)
|
16
16
|
.returns(Dodopayments::Models::Customer)
|
17
17
|
end
|
18
18
|
def create(email:, name:, phone_number: nil, request_options: {}); end
|
19
19
|
|
20
20
|
sig do
|
21
|
-
params(
|
22
|
-
customer_id: String,
|
23
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
24
|
-
)
|
21
|
+
params(customer_id: String, request_options: Dodopayments::RequestOpts)
|
25
22
|
.returns(Dodopayments::Models::Customer)
|
26
23
|
end
|
27
24
|
def retrieve(
|
@@ -34,7 +31,7 @@ module Dodopayments
|
|
34
31
|
customer_id: String,
|
35
32
|
name: T.nilable(String),
|
36
33
|
phone_number: T.nilable(String),
|
37
|
-
request_options:
|
34
|
+
request_options: Dodopayments::RequestOpts
|
38
35
|
)
|
39
36
|
.returns(Dodopayments::Models::Customer)
|
40
37
|
end
|
@@ -49,7 +46,7 @@ module Dodopayments
|
|
49
46
|
params(
|
50
47
|
page_number: T.nilable(Integer),
|
51
48
|
page_size: T.nilable(Integer),
|
52
|
-
request_options:
|
49
|
+
request_options: Dodopayments::RequestOpts
|
53
50
|
)
|
54
51
|
.returns(Dodopayments::Internal::DefaultPageNumberPagination[Dodopayments::Models::Customer])
|
55
52
|
end
|
@@ -13,7 +13,7 @@ module Dodopayments
|
|
13
13
|
name: T.nilable(String),
|
14
14
|
restricted_to: T.nilable(T::Array[String]),
|
15
15
|
usage_limit: T.nilable(Integer),
|
16
|
-
request_options:
|
16
|
+
request_options: Dodopayments::RequestOpts
|
17
17
|
)
|
18
18
|
.returns(Dodopayments::Models::Discount)
|
19
19
|
end
|
@@ -44,10 +44,7 @@ module Dodopayments
|
|
44
44
|
); end
|
45
45
|
# GET /discounts/{discount_id}
|
46
46
|
sig do
|
47
|
-
params(
|
48
|
-
discount_id: String,
|
49
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
50
|
-
)
|
47
|
+
params(discount_id: String, request_options: Dodopayments::RequestOpts)
|
51
48
|
.returns(Dodopayments::Models::Discount)
|
52
49
|
end
|
53
50
|
def retrieve(
|
@@ -66,7 +63,7 @@ module Dodopayments
|
|
66
63
|
restricted_to: T.nilable(T::Array[String]),
|
67
64
|
type: T.nilable(Dodopayments::Models::DiscountType::OrSymbol),
|
68
65
|
usage_limit: T.nilable(Integer),
|
69
|
-
request_options:
|
66
|
+
request_options: Dodopayments::RequestOpts
|
70
67
|
)
|
71
68
|
.returns(Dodopayments::Models::Discount)
|
72
69
|
end
|
@@ -97,7 +94,7 @@ module Dodopayments
|
|
97
94
|
params(
|
98
95
|
page_number: T.nilable(Integer),
|
99
96
|
page_size: T.nilable(Integer),
|
100
|
-
request_options:
|
97
|
+
request_options: Dodopayments::RequestOpts
|
101
98
|
)
|
102
99
|
.returns(Dodopayments::Internal::DefaultPageNumberPagination[Dodopayments::Models::Discount])
|
103
100
|
end
|
@@ -109,13 +106,7 @@ module Dodopayments
|
|
109
106
|
request_options: {}
|
110
107
|
); end
|
111
108
|
# DELETE /discounts/{discount_id}
|
112
|
-
sig
|
113
|
-
params(
|
114
|
-
discount_id: String,
|
115
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
116
|
-
)
|
117
|
-
.void
|
118
|
-
end
|
109
|
+
sig { params(discount_id: String, request_options: Dodopayments::RequestOpts).void }
|
119
110
|
def delete(
|
120
111
|
# Discount Id
|
121
112
|
discount_id,
|
@@ -4,10 +4,7 @@ module Dodopayments
|
|
4
4
|
module Resources
|
5
5
|
class Disputes
|
6
6
|
sig do
|
7
|
-
params(
|
8
|
-
dispute_id: String,
|
9
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
10
|
-
)
|
7
|
+
params(dispute_id: String, request_options: Dodopayments::RequestOpts)
|
11
8
|
.returns(Dodopayments::Models::Dispute)
|
12
9
|
end
|
13
10
|
def retrieve(
|
@@ -24,7 +21,7 @@ module Dodopayments
|
|
24
21
|
dispute_status: T.nilable(Dodopayments::Models::DisputeStatus::OrSymbol),
|
25
22
|
page_number: T.nilable(Integer),
|
26
23
|
page_size: T.nilable(Integer),
|
27
|
-
request_options:
|
24
|
+
request_options: Dodopayments::RequestOpts
|
28
25
|
)
|
29
26
|
.returns(Dodopayments::Internal::DefaultPageNumberPagination[Dodopayments::Models::Dispute])
|
30
27
|
end
|
@@ -4,13 +4,7 @@ module Dodopayments
|
|
4
4
|
module Resources
|
5
5
|
class Invoices
|
6
6
|
class Payments
|
7
|
-
sig
|
8
|
-
params(
|
9
|
-
payment_id: String,
|
10
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
11
|
-
)
|
12
|
-
.void
|
13
|
-
end
|
7
|
+
sig { params(payment_id: String, request_options: Dodopayments::RequestOpts).void }
|
14
8
|
def retrieve(payment_id, request_options: {}); end
|
15
9
|
|
16
10
|
# @api private
|
@@ -4,10 +4,7 @@ module Dodopayments
|
|
4
4
|
module Resources
|
5
5
|
class LicenseKeyInstances
|
6
6
|
sig do
|
7
|
-
params(
|
8
|
-
id: String,
|
9
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
10
|
-
)
|
7
|
+
params(id: String, request_options: Dodopayments::RequestOpts)
|
11
8
|
.returns(Dodopayments::Models::LicenseKeyInstance)
|
12
9
|
end
|
13
10
|
def retrieve(
|
@@ -16,11 +13,7 @@ module Dodopayments
|
|
16
13
|
request_options: {}
|
17
14
|
); end
|
18
15
|
sig do
|
19
|
-
params(
|
20
|
-
id: String,
|
21
|
-
name: String,
|
22
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
23
|
-
)
|
16
|
+
params(id: String, name: String, request_options: Dodopayments::RequestOpts)
|
24
17
|
.returns(Dodopayments::Models::LicenseKeyInstance)
|
25
18
|
end
|
26
19
|
def update(
|
@@ -34,7 +27,7 @@ module Dodopayments
|
|
34
27
|
license_key_id: T.nilable(String),
|
35
28
|
page_number: T.nilable(Integer),
|
36
29
|
page_size: T.nilable(Integer),
|
37
|
-
request_options:
|
30
|
+
request_options: Dodopayments::RequestOpts
|
38
31
|
)
|
39
32
|
.returns(Dodopayments::Internal::DefaultPageNumberPagination[Dodopayments::Models::LicenseKeyInstance])
|
40
33
|
end
|
@@ -3,13 +3,7 @@
|
|
3
3
|
module Dodopayments
|
4
4
|
module Resources
|
5
5
|
class LicenseKeys
|
6
|
-
sig
|
7
|
-
params(
|
8
|
-
id: String,
|
9
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
10
|
-
)
|
11
|
-
.returns(Dodopayments::Models::LicenseKey)
|
12
|
-
end
|
6
|
+
sig { params(id: String, request_options: Dodopayments::RequestOpts).returns(Dodopayments::Models::LicenseKey) }
|
13
7
|
def retrieve(
|
14
8
|
# License key ID
|
15
9
|
id,
|
@@ -21,7 +15,7 @@ module Dodopayments
|
|
21
15
|
activations_limit: T.nilable(Integer),
|
22
16
|
disabled: T.nilable(T::Boolean),
|
23
17
|
expires_at: T.nilable(Time),
|
24
|
-
request_options:
|
18
|
+
request_options: Dodopayments::RequestOpts
|
25
19
|
)
|
26
20
|
.returns(Dodopayments::Models::LicenseKey)
|
27
21
|
end
|
@@ -46,7 +40,7 @@ module Dodopayments
|
|
46
40
|
page_size: T.nilable(Integer),
|
47
41
|
product_id: T.nilable(String),
|
48
42
|
status: T.nilable(Dodopayments::Models::LicenseKeyStatus::OrSymbol),
|
49
|
-
request_options:
|
43
|
+
request_options: Dodopayments::RequestOpts
|
50
44
|
)
|
51
45
|
.returns(Dodopayments::Internal::DefaultPageNumberPagination[Dodopayments::Models::LicenseKey])
|
52
46
|
end
|
@@ -4,11 +4,7 @@ module Dodopayments
|
|
4
4
|
module Resources
|
5
5
|
class Licenses
|
6
6
|
sig do
|
7
|
-
params(
|
8
|
-
license_key: String,
|
9
|
-
name: String,
|
10
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
11
|
-
)
|
7
|
+
params(license_key: String, name: String, request_options: Dodopayments::RequestOpts)
|
12
8
|
.returns(Dodopayments::Models::LicenseKeyInstance)
|
13
9
|
end
|
14
10
|
def activate(license_key:, name:, request_options: {}); end
|
@@ -17,7 +13,7 @@ module Dodopayments
|
|
17
13
|
params(
|
18
14
|
license_key: String,
|
19
15
|
license_key_instance_id: String,
|
20
|
-
request_options:
|
16
|
+
request_options: Dodopayments::RequestOpts
|
21
17
|
)
|
22
18
|
.void
|
23
19
|
end
|
@@ -27,7 +23,7 @@ module Dodopayments
|
|
27
23
|
params(
|
28
24
|
license_key: String,
|
29
25
|
license_key_instance_id: T.nilable(String),
|
30
|
-
request_options:
|
26
|
+
request_options: Dodopayments::RequestOpts
|
31
27
|
)
|
32
28
|
.returns(Dodopayments::Models::LicenseValidateResponse)
|
33
29
|
end
|
@@ -4,14 +4,7 @@ module Dodopayments
|
|
4
4
|
module Resources
|
5
5
|
class Misc
|
6
6
|
sig do
|
7
|
-
params(
|
8
|
-
request_options: T.nilable(
|
9
|
-
T.any(
|
10
|
-
Dodopayments::RequestOptions,
|
11
|
-
Dodopayments::Internal::AnyHash
|
12
|
-
)
|
13
|
-
)
|
14
|
-
)
|
7
|
+
params(request_options: Dodopayments::RequestOpts)
|
15
8
|
.returns(T::Array[Dodopayments::Models::CountryCode::TaggedSymbol])
|
16
9
|
end
|
17
10
|
def list_supported_countries(request_options: {}); end
|
@@ -13,14 +13,14 @@ module Dodopayments
|
|
13
13
|
),
|
14
14
|
product_cart: T::Array[T.any(Dodopayments::Models::OneTimeProductCartItem, Dodopayments::Internal::AnyHash)],
|
15
15
|
allowed_payment_method_types: T.nilable(T::Array[Dodopayments::Models::PaymentCreateParams::AllowedPaymentMethodType::OrSymbol]),
|
16
|
-
billing_currency: T.nilable(Dodopayments::Models::
|
16
|
+
billing_currency: T.nilable(Dodopayments::Models::Currency::OrSymbol),
|
17
17
|
discount_code: T.nilable(String),
|
18
18
|
metadata: T::Hash[Symbol, String],
|
19
19
|
payment_link: T.nilable(T::Boolean),
|
20
20
|
return_url: T.nilable(String),
|
21
21
|
show_saved_payment_methods: T::Boolean,
|
22
22
|
tax_id: T.nilable(String),
|
23
|
-
request_options:
|
23
|
+
request_options: Dodopayments::RequestOpts
|
24
24
|
)
|
25
25
|
.returns(Dodopayments::Models::PaymentCreateResponse)
|
26
26
|
end
|
@@ -53,10 +53,7 @@ module Dodopayments
|
|
53
53
|
request_options: {}
|
54
54
|
); end
|
55
55
|
sig do
|
56
|
-
params(
|
57
|
-
payment_id: String,
|
58
|
-
request_options: T.nilable(T.any(Dodopayments::RequestOptions, Dodopayments::Internal::AnyHash))
|
59
|
-
)
|
56
|
+
params(payment_id: String, request_options: Dodopayments::RequestOpts)
|
60
57
|
.returns(Dodopayments::Models::Payment)
|
61
58
|
end
|
62
59
|
def retrieve(
|
@@ -73,7 +70,7 @@ module Dodopayments
|
|
73
70
|
page_size: T.nilable(Integer),
|
74
71
|
status: T.nilable(Dodopayments::Models::IntentStatus::OrSymbol),
|
75
72
|
subscription_id: T.nilable(String),
|
76
|
-
request_options:
|
73
|
+
request_options: Dodopayments::RequestOpts
|
77
74
|
)
|
78
75
|
.returns(Dodopayments::Internal::DefaultPageNumberPagination[Dodopayments::Models::PaymentListResponse])
|
79
76
|
end
|