dodopayments 2.9.1 → 2.10.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 +15 -0
- data/README.md +1 -1
- data/lib/dodopayments/internal/transport/base_client.rb +2 -0
- data/lib/dodopayments/internal/type/union.rb +21 -7
- data/lib/dodopayments/models/abandoned_checkout_detected_webhook_event.rb +4 -16
- data/lib/dodopayments/models/abandoned_checkout_recovered_webhook_event.rb +4 -16
- data/lib/dodopayments/models/checkout_session_request.rb +15 -2
- data/lib/dodopayments/models/credit_added_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_balance_low_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_deducted_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_expired_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_manual_adjustment_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_overage_charged_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_overage_reset_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_rolled_over_webhook_event.rb +4 -16
- data/lib/dodopayments/models/credit_rollover_forfeited_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dispute_accepted_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dispute_cancelled_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dispute_challenged_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dispute_expired_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dispute_lost_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dispute_opened_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dispute_won_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dunning_recovered_webhook_event.rb +4 -16
- data/lib/dodopayments/models/dunning_started_webhook_event.rb +4 -16
- data/lib/dodopayments/models/entitlement_grant_created_webhook_event.rb +4 -16
- data/lib/dodopayments/models/entitlement_grant_delivered_webhook_event.rb +4 -16
- data/lib/dodopayments/models/entitlement_grant_failed_webhook_event.rb +4 -16
- data/lib/dodopayments/models/entitlement_grant_revoked_webhook_event.rb +4 -16
- data/lib/dodopayments/models/license_key_created_webhook_event.rb +4 -16
- data/lib/dodopayments/models/payment.rb +153 -3
- data/lib/dodopayments/models/payment_cancelled_webhook_event.rb +4 -16
- data/lib/dodopayments/models/payment_create_params.rb +15 -3
- data/lib/dodopayments/models/payment_create_response.rb +14 -3
- data/lib/dodopayments/models/payment_failed_webhook_event.rb +4 -16
- data/lib/dodopayments/models/payment_processing_webhook_event.rb +4 -16
- data/lib/dodopayments/models/payment_succeeded_webhook_event.rb +4 -16
- data/lib/dodopayments/models/payout_list_response.rb +6 -3
- data/lib/dodopayments/models/price.rb +20 -48
- data/lib/dodopayments/models/product.rb +3 -3
- data/lib/dodopayments/models/product_create_params.rb +3 -3
- data/lib/dodopayments/models/product_item_req.rb +42 -1
- data/lib/dodopayments/models/product_update_params.rb +3 -3
- data/lib/dodopayments/models/refund_failed_webhook_event.rb +4 -16
- data/lib/dodopayments/models/refund_succeeded_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription.rb +153 -5
- data/lib/dodopayments/models/subscription_active_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription_cancelled_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription_create_params.rb +15 -3
- data/lib/dodopayments/models/subscription_create_response.rb +14 -3
- data/lib/dodopayments/models/subscription_expired_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription_failed_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription_list_response.rb +36 -5
- data/lib/dodopayments/models/subscription_on_hold_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription_plan_changed_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription_preview_change_plan_response.rb +21 -49
- data/lib/dodopayments/models/subscription_renewed_webhook_event.rb +4 -16
- data/lib/dodopayments/models/subscription_update_payment_method_params.rb +12 -30
- data/lib/dodopayments/models/subscription_updated_webhook_event.rb +4 -16
- data/lib/dodopayments/models/unsafe_unwrap_webhook_event.rb +41 -39
- data/lib/dodopayments/models/unwrap_webhook_event.rb +41 -39
- data/lib/dodopayments/models/update_subscription_plan_req.rb +17 -6
- data/lib/dodopayments/models/webhook_event_type.rb +3 -0
- data/lib/dodopayments/models/webhook_payload.rb +52 -143
- data/lib/dodopayments/resources/checkout_sessions.rb +8 -4
- data/lib/dodopayments/resources/payments.rb +4 -2
- data/lib/dodopayments/resources/subscriptions.rb +12 -6
- data/lib/dodopayments/version.rb +1 -1
- data/rbi/dodopayments/models/abandoned_checkout_detected_webhook_event.rbi +4 -40
- data/rbi/dodopayments/models/abandoned_checkout_recovered_webhook_event.rbi +4 -40
- data/rbi/dodopayments/models/checkout_session_request.rbi +14 -0
- data/rbi/dodopayments/models/credit_added_webhook_event.rbi +4 -29
- data/rbi/dodopayments/models/credit_balance_low_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/credit_deducted_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/credit_expired_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/credit_manual_adjustment_webhook_event.rbi +4 -39
- data/rbi/dodopayments/models/credit_overage_charged_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/credit_overage_reset_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/credit_rolled_over_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/credit_rollover_forfeited_webhook_event.rbi +4 -40
- data/rbi/dodopayments/models/dispute_accepted_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/dispute_cancelled_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/dispute_challenged_webhook_event.rbi +4 -34
- data/rbi/dodopayments/models/dispute_expired_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/dispute_lost_webhook_event.rbi +4 -29
- data/rbi/dodopayments/models/dispute_opened_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/dispute_won_webhook_event.rbi +4 -29
- data/rbi/dodopayments/models/dunning_recovered_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/dunning_started_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/entitlement_grant_created_webhook_event.rbi +4 -40
- data/rbi/dodopayments/models/entitlement_grant_delivered_webhook_event.rbi +4 -40
- data/rbi/dodopayments/models/entitlement_grant_failed_webhook_event.rbi +4 -39
- data/rbi/dodopayments/models/entitlement_grant_revoked_webhook_event.rbi +4 -40
- data/rbi/dodopayments/models/license_key_created_webhook_event.rbi +4 -34
- data/rbi/dodopayments/models/payment.rbi +170 -2
- data/rbi/dodopayments/models/payment_cancelled_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/payment_create_params.rbi +14 -2
- data/rbi/dodopayments/models/payment_create_response.rbi +12 -2
- data/rbi/dodopayments/models/payment_failed_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/payment_processing_webhook_event.rbi +4 -34
- data/rbi/dodopayments/models/payment_succeeded_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/price.rbi +18 -90
- data/rbi/dodopayments/models/product_item_req.rbi +74 -3
- data/rbi/dodopayments/models/refund_failed_webhook_event.rbi +4 -31
- data/rbi/dodopayments/models/refund_succeeded_webhook_event.rbi +4 -33
- data/rbi/dodopayments/models/subscription.rbi +173 -4
- data/rbi/dodopayments/models/subscription_active_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/subscription_cancelled_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/subscription_create_params.rbi +14 -2
- data/rbi/dodopayments/models/subscription_create_response.rbi +12 -2
- data/rbi/dodopayments/models/subscription_expired_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/subscription_failed_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/subscription_list_response.rbi +67 -4
- data/rbi/dodopayments/models/subscription_on_hold_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/subscription_plan_changed_webhook_event.rbi +4 -40
- data/rbi/dodopayments/models/subscription_preview_change_plan_response.rbi +18 -123
- data/rbi/dodopayments/models/subscription_renewed_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/subscription_update_payment_method_params.rbi +12 -96
- data/rbi/dodopayments/models/subscription_updated_webhook_event.rbi +4 -36
- data/rbi/dodopayments/models/update_subscription_plan_req.rbi +18 -8
- data/rbi/dodopayments/models/webhook_event_type.rbi +15 -0
- data/rbi/dodopayments/models/webhook_payload.rbi +46 -466
- data/rbi/dodopayments/resources/checkout_sessions.rbi +12 -0
- data/rbi/dodopayments/resources/payments.rbi +6 -1
- data/rbi/dodopayments/resources/subscriptions.rbi +22 -9
- data/sig/dodopayments/models/abandoned_checkout_detected_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/abandoned_checkout_recovered_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/checkout_session_request.rbs +5 -0
- data/sig/dodopayments/models/credit_added_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_balance_low_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_deducted_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_expired_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_manual_adjustment_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_overage_charged_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_overage_reset_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_rolled_over_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/credit_rollover_forfeited_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dispute_accepted_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dispute_cancelled_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dispute_challenged_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dispute_expired_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dispute_lost_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dispute_opened_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dispute_won_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dunning_recovered_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/dunning_started_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/entitlement_grant_created_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/entitlement_grant_delivered_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/entitlement_grant_failed_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/entitlement_grant_revoked_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/license_key_created_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/payment.rbs +97 -0
- data/sig/dodopayments/models/payment_cancelled_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/payment_create_params.rbs +5 -0
- data/sig/dodopayments/models/payment_create_response.rbs +5 -0
- data/sig/dodopayments/models/payment_failed_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/payment_processing_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/payment_succeeded_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/price.rbs +15 -45
- data/sig/dodopayments/models/product_item_req.rbs +27 -3
- data/sig/dodopayments/models/refund_failed_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/refund_succeeded_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription.rbs +97 -0
- data/sig/dodopayments/models/subscription_active_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription_cancelled_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription_create_params.rbs +5 -0
- data/sig/dodopayments/models/subscription_create_response.rbs +5 -0
- data/sig/dodopayments/models/subscription_expired_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription_failed_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription_list_response.rbs +24 -0
- data/sig/dodopayments/models/subscription_on_hold_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription_plan_changed_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription_preview_change_plan_response.rbs +15 -45
- data/sig/dodopayments/models/subscription_renewed_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/subscription_update_payment_method_params.rbs +8 -48
- data/sig/dodopayments/models/subscription_updated_webhook_event.rbs +4 -14
- data/sig/dodopayments/models/update_subscription_plan_req.rbs +5 -0
- data/sig/dodopayments/models/webhook_event_type.rbs +6 -0
- data/sig/dodopayments/models/webhook_payload.rbs +50 -213
- data/sig/dodopayments/resources/checkout_sessions.rbs +2 -0
- data/sig/dodopayments/resources/payments.rbs +1 -0
- data/sig/dodopayments/resources/subscriptions.rbs +3 -0
- metadata +2 -2
|
@@ -23,29 +23,17 @@ module Dodopayments
|
|
|
23
23
|
# @!attribute type
|
|
24
24
|
# The event type
|
|
25
25
|
#
|
|
26
|
-
# @return [Symbol,
|
|
27
|
-
required :type,
|
|
26
|
+
# @return [Symbol, :"dispute.expired"]
|
|
27
|
+
required :type, const: :"dispute.expired"
|
|
28
28
|
|
|
29
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
29
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"dispute.expired")
|
|
30
30
|
# @param business_id [String] The business identifier
|
|
31
31
|
#
|
|
32
32
|
# @param data [Dodopayments::Models::Dispute]
|
|
33
33
|
#
|
|
34
34
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
35
35
|
#
|
|
36
|
-
# @param type [Symbol,
|
|
37
|
-
|
|
38
|
-
# The event type
|
|
39
|
-
#
|
|
40
|
-
# @see Dodopayments::Models::DisputeExpiredWebhookEvent#type
|
|
41
|
-
module Type
|
|
42
|
-
extend Dodopayments::Internal::Type::Enum
|
|
43
|
-
|
|
44
|
-
DISPUTE_EXPIRED = :"dispute.expired"
|
|
45
|
-
|
|
46
|
-
# @!method self.values
|
|
47
|
-
# @return [Array<Symbol>]
|
|
48
|
-
end
|
|
36
|
+
# @param type [Symbol, :"dispute.expired"] The event type
|
|
49
37
|
end
|
|
50
38
|
end
|
|
51
39
|
end
|
|
@@ -23,29 +23,17 @@ module Dodopayments
|
|
|
23
23
|
# @!attribute type
|
|
24
24
|
# The event type
|
|
25
25
|
#
|
|
26
|
-
# @return [Symbol,
|
|
27
|
-
required :type,
|
|
26
|
+
# @return [Symbol, :"dispute.lost"]
|
|
27
|
+
required :type, const: :"dispute.lost"
|
|
28
28
|
|
|
29
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
29
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"dispute.lost")
|
|
30
30
|
# @param business_id [String] The business identifier
|
|
31
31
|
#
|
|
32
32
|
# @param data [Dodopayments::Models::Dispute]
|
|
33
33
|
#
|
|
34
34
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
35
35
|
#
|
|
36
|
-
# @param type [Symbol,
|
|
37
|
-
|
|
38
|
-
# The event type
|
|
39
|
-
#
|
|
40
|
-
# @see Dodopayments::Models::DisputeLostWebhookEvent#type
|
|
41
|
-
module Type
|
|
42
|
-
extend Dodopayments::Internal::Type::Enum
|
|
43
|
-
|
|
44
|
-
DISPUTE_LOST = :"dispute.lost"
|
|
45
|
-
|
|
46
|
-
# @!method self.values
|
|
47
|
-
# @return [Array<Symbol>]
|
|
48
|
-
end
|
|
36
|
+
# @param type [Symbol, :"dispute.lost"] The event type
|
|
49
37
|
end
|
|
50
38
|
end
|
|
51
39
|
end
|
|
@@ -23,29 +23,17 @@ module Dodopayments
|
|
|
23
23
|
# @!attribute type
|
|
24
24
|
# The event type
|
|
25
25
|
#
|
|
26
|
-
# @return [Symbol,
|
|
27
|
-
required :type,
|
|
26
|
+
# @return [Symbol, :"dispute.opened"]
|
|
27
|
+
required :type, const: :"dispute.opened"
|
|
28
28
|
|
|
29
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
29
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"dispute.opened")
|
|
30
30
|
# @param business_id [String] The business identifier
|
|
31
31
|
#
|
|
32
32
|
# @param data [Dodopayments::Models::Dispute]
|
|
33
33
|
#
|
|
34
34
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
35
35
|
#
|
|
36
|
-
# @param type [Symbol,
|
|
37
|
-
|
|
38
|
-
# The event type
|
|
39
|
-
#
|
|
40
|
-
# @see Dodopayments::Models::DisputeOpenedWebhookEvent#type
|
|
41
|
-
module Type
|
|
42
|
-
extend Dodopayments::Internal::Type::Enum
|
|
43
|
-
|
|
44
|
-
DISPUTE_OPENED = :"dispute.opened"
|
|
45
|
-
|
|
46
|
-
# @!method self.values
|
|
47
|
-
# @return [Array<Symbol>]
|
|
48
|
-
end
|
|
36
|
+
# @param type [Symbol, :"dispute.opened"] The event type
|
|
49
37
|
end
|
|
50
38
|
end
|
|
51
39
|
end
|
|
@@ -23,29 +23,17 @@ module Dodopayments
|
|
|
23
23
|
# @!attribute type
|
|
24
24
|
# The event type
|
|
25
25
|
#
|
|
26
|
-
# @return [Symbol,
|
|
27
|
-
required :type,
|
|
26
|
+
# @return [Symbol, :"dispute.won"]
|
|
27
|
+
required :type, const: :"dispute.won"
|
|
28
28
|
|
|
29
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
29
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"dispute.won")
|
|
30
30
|
# @param business_id [String] The business identifier
|
|
31
31
|
#
|
|
32
32
|
# @param data [Dodopayments::Models::Dispute]
|
|
33
33
|
#
|
|
34
34
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
35
35
|
#
|
|
36
|
-
# @param type [Symbol,
|
|
37
|
-
|
|
38
|
-
# The event type
|
|
39
|
-
#
|
|
40
|
-
# @see Dodopayments::Models::DisputeWonWebhookEvent#type
|
|
41
|
-
module Type
|
|
42
|
-
extend Dodopayments::Internal::Type::Enum
|
|
43
|
-
|
|
44
|
-
DISPUTE_WON = :"dispute.won"
|
|
45
|
-
|
|
46
|
-
# @!method self.values
|
|
47
|
-
# @return [Array<Symbol>]
|
|
48
|
-
end
|
|
36
|
+
# @param type [Symbol, :"dispute.won"] The event type
|
|
49
37
|
end
|
|
50
38
|
end
|
|
51
39
|
end
|
|
@@ -24,17 +24,17 @@ module Dodopayments
|
|
|
24
24
|
# @!attribute type
|
|
25
25
|
# The event type
|
|
26
26
|
#
|
|
27
|
-
# @return [Symbol,
|
|
28
|
-
required :type,
|
|
27
|
+
# @return [Symbol, :"dunning.recovered"]
|
|
28
|
+
required :type, const: :"dunning.recovered"
|
|
29
29
|
|
|
30
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
30
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"dunning.recovered")
|
|
31
31
|
# @param business_id [String] The business identifier
|
|
32
32
|
#
|
|
33
33
|
# @param data [Dodopayments::Models::DunningRecoveredWebhookEvent::Data] Webhook payload for dunning.started and dunning.recovered events
|
|
34
34
|
#
|
|
35
35
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
36
36
|
#
|
|
37
|
-
# @param type [Symbol,
|
|
37
|
+
# @param type [Symbol, :"dunning.recovered"] The event type
|
|
38
38
|
|
|
39
39
|
# @see Dodopayments::Models::DunningRecoveredWebhookEvent#data
|
|
40
40
|
class Data < Dodopayments::Internal::Type::BaseModel
|
|
@@ -101,18 +101,6 @@ module Dodopayments
|
|
|
101
101
|
# @return [Array<Symbol>]
|
|
102
102
|
end
|
|
103
103
|
end
|
|
104
|
-
|
|
105
|
-
# The event type
|
|
106
|
-
#
|
|
107
|
-
# @see Dodopayments::Models::DunningRecoveredWebhookEvent#type
|
|
108
|
-
module Type
|
|
109
|
-
extend Dodopayments::Internal::Type::Enum
|
|
110
|
-
|
|
111
|
-
DUNNING_RECOVERED = :"dunning.recovered"
|
|
112
|
-
|
|
113
|
-
# @!method self.values
|
|
114
|
-
# @return [Array<Symbol>]
|
|
115
|
-
end
|
|
116
104
|
end
|
|
117
105
|
end
|
|
118
106
|
end
|
|
@@ -24,17 +24,17 @@ module Dodopayments
|
|
|
24
24
|
# @!attribute type
|
|
25
25
|
# The event type
|
|
26
26
|
#
|
|
27
|
-
# @return [Symbol,
|
|
28
|
-
required :type,
|
|
27
|
+
# @return [Symbol, :"dunning.started"]
|
|
28
|
+
required :type, const: :"dunning.started"
|
|
29
29
|
|
|
30
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
30
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"dunning.started")
|
|
31
31
|
# @param business_id [String] The business identifier
|
|
32
32
|
#
|
|
33
33
|
# @param data [Dodopayments::Models::DunningStartedWebhookEvent::Data] Webhook payload for dunning.started and dunning.recovered events
|
|
34
34
|
#
|
|
35
35
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
36
36
|
#
|
|
37
|
-
# @param type [Symbol,
|
|
37
|
+
# @param type [Symbol, :"dunning.started"] The event type
|
|
38
38
|
|
|
39
39
|
# @see Dodopayments::Models::DunningStartedWebhookEvent#data
|
|
40
40
|
class Data < Dodopayments::Internal::Type::BaseModel
|
|
@@ -101,18 +101,6 @@ module Dodopayments
|
|
|
101
101
|
# @return [Array<Symbol>]
|
|
102
102
|
end
|
|
103
103
|
end
|
|
104
|
-
|
|
105
|
-
# The event type
|
|
106
|
-
#
|
|
107
|
-
# @see Dodopayments::Models::DunningStartedWebhookEvent#type
|
|
108
|
-
module Type
|
|
109
|
-
extend Dodopayments::Internal::Type::Enum
|
|
110
|
-
|
|
111
|
-
DUNNING_STARTED = :"dunning.started"
|
|
112
|
-
|
|
113
|
-
# @!method self.values
|
|
114
|
-
# @return [Array<Symbol>]
|
|
115
|
-
end
|
|
116
104
|
end
|
|
117
105
|
end
|
|
118
106
|
end
|
|
@@ -25,10 +25,10 @@ module Dodopayments
|
|
|
25
25
|
# @!attribute type
|
|
26
26
|
# The event type
|
|
27
27
|
#
|
|
28
|
-
# @return [Symbol,
|
|
29
|
-
required :type,
|
|
28
|
+
# @return [Symbol, :"entitlement_grant.created"]
|
|
29
|
+
required :type, const: :"entitlement_grant.created"
|
|
30
30
|
|
|
31
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
31
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"entitlement_grant.created")
|
|
32
32
|
# Some parameter documentations has been truncated, see
|
|
33
33
|
# {Dodopayments::Models::EntitlementGrantCreatedWebhookEvent} for more details.
|
|
34
34
|
#
|
|
@@ -38,19 +38,7 @@ module Dodopayments
|
|
|
38
38
|
#
|
|
39
39
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
40
40
|
#
|
|
41
|
-
# @param type [Symbol,
|
|
42
|
-
|
|
43
|
-
# The event type
|
|
44
|
-
#
|
|
45
|
-
# @see Dodopayments::Models::EntitlementGrantCreatedWebhookEvent#type
|
|
46
|
-
module Type
|
|
47
|
-
extend Dodopayments::Internal::Type::Enum
|
|
48
|
-
|
|
49
|
-
ENTITLEMENT_GRANT_CREATED = :"entitlement_grant.created"
|
|
50
|
-
|
|
51
|
-
# @!method self.values
|
|
52
|
-
# @return [Array<Symbol>]
|
|
53
|
-
end
|
|
41
|
+
# @param type [Symbol, :"entitlement_grant.created"] The event type
|
|
54
42
|
end
|
|
55
43
|
end
|
|
56
44
|
end
|
|
@@ -25,10 +25,10 @@ module Dodopayments
|
|
|
25
25
|
# @!attribute type
|
|
26
26
|
# The event type
|
|
27
27
|
#
|
|
28
|
-
# @return [Symbol,
|
|
29
|
-
required :type,
|
|
28
|
+
# @return [Symbol, :"entitlement_grant.delivered"]
|
|
29
|
+
required :type, const: :"entitlement_grant.delivered"
|
|
30
30
|
|
|
31
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
31
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"entitlement_grant.delivered")
|
|
32
32
|
# Some parameter documentations has been truncated, see
|
|
33
33
|
# {Dodopayments::Models::EntitlementGrantDeliveredWebhookEvent} for more details.
|
|
34
34
|
#
|
|
@@ -38,19 +38,7 @@ module Dodopayments
|
|
|
38
38
|
#
|
|
39
39
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
40
40
|
#
|
|
41
|
-
# @param type [Symbol,
|
|
42
|
-
|
|
43
|
-
# The event type
|
|
44
|
-
#
|
|
45
|
-
# @see Dodopayments::Models::EntitlementGrantDeliveredWebhookEvent#type
|
|
46
|
-
module Type
|
|
47
|
-
extend Dodopayments::Internal::Type::Enum
|
|
48
|
-
|
|
49
|
-
ENTITLEMENT_GRANT_DELIVERED = :"entitlement_grant.delivered"
|
|
50
|
-
|
|
51
|
-
# @!method self.values
|
|
52
|
-
# @return [Array<Symbol>]
|
|
53
|
-
end
|
|
41
|
+
# @param type [Symbol, :"entitlement_grant.delivered"] The event type
|
|
54
42
|
end
|
|
55
43
|
end
|
|
56
44
|
end
|
|
@@ -25,10 +25,10 @@ module Dodopayments
|
|
|
25
25
|
# @!attribute type
|
|
26
26
|
# The event type
|
|
27
27
|
#
|
|
28
|
-
# @return [Symbol,
|
|
29
|
-
required :type,
|
|
28
|
+
# @return [Symbol, :"entitlement_grant.failed"]
|
|
29
|
+
required :type, const: :"entitlement_grant.failed"
|
|
30
30
|
|
|
31
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
31
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"entitlement_grant.failed")
|
|
32
32
|
# Some parameter documentations has been truncated, see
|
|
33
33
|
# {Dodopayments::Models::EntitlementGrantFailedWebhookEvent} for more details.
|
|
34
34
|
#
|
|
@@ -38,19 +38,7 @@ module Dodopayments
|
|
|
38
38
|
#
|
|
39
39
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
40
40
|
#
|
|
41
|
-
# @param type [Symbol,
|
|
42
|
-
|
|
43
|
-
# The event type
|
|
44
|
-
#
|
|
45
|
-
# @see Dodopayments::Models::EntitlementGrantFailedWebhookEvent#type
|
|
46
|
-
module Type
|
|
47
|
-
extend Dodopayments::Internal::Type::Enum
|
|
48
|
-
|
|
49
|
-
ENTITLEMENT_GRANT_FAILED = :"entitlement_grant.failed"
|
|
50
|
-
|
|
51
|
-
# @!method self.values
|
|
52
|
-
# @return [Array<Symbol>]
|
|
53
|
-
end
|
|
41
|
+
# @param type [Symbol, :"entitlement_grant.failed"] The event type
|
|
54
42
|
end
|
|
55
43
|
end
|
|
56
44
|
end
|
|
@@ -25,10 +25,10 @@ module Dodopayments
|
|
|
25
25
|
# @!attribute type
|
|
26
26
|
# The event type
|
|
27
27
|
#
|
|
28
|
-
# @return [Symbol,
|
|
29
|
-
required :type,
|
|
28
|
+
# @return [Symbol, :"entitlement_grant.revoked"]
|
|
29
|
+
required :type, const: :"entitlement_grant.revoked"
|
|
30
30
|
|
|
31
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
31
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"entitlement_grant.revoked")
|
|
32
32
|
# Some parameter documentations has been truncated, see
|
|
33
33
|
# {Dodopayments::Models::EntitlementGrantRevokedWebhookEvent} for more details.
|
|
34
34
|
#
|
|
@@ -38,19 +38,7 @@ module Dodopayments
|
|
|
38
38
|
#
|
|
39
39
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
40
40
|
#
|
|
41
|
-
# @param type [Symbol,
|
|
42
|
-
|
|
43
|
-
# The event type
|
|
44
|
-
#
|
|
45
|
-
# @see Dodopayments::Models::EntitlementGrantRevokedWebhookEvent#type
|
|
46
|
-
module Type
|
|
47
|
-
extend Dodopayments::Internal::Type::Enum
|
|
48
|
-
|
|
49
|
-
ENTITLEMENT_GRANT_REVOKED = :"entitlement_grant.revoked"
|
|
50
|
-
|
|
51
|
-
# @!method self.values
|
|
52
|
-
# @return [Array<Symbol>]
|
|
53
|
-
end
|
|
41
|
+
# @param type [Symbol, :"entitlement_grant.revoked"] The event type
|
|
54
42
|
end
|
|
55
43
|
end
|
|
56
44
|
end
|
|
@@ -23,29 +23,17 @@ module Dodopayments
|
|
|
23
23
|
# @!attribute type
|
|
24
24
|
# The event type
|
|
25
25
|
#
|
|
26
|
-
# @return [Symbol,
|
|
27
|
-
required :type,
|
|
26
|
+
# @return [Symbol, :"license_key.created"]
|
|
27
|
+
required :type, const: :"license_key.created"
|
|
28
28
|
|
|
29
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
29
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"license_key.created")
|
|
30
30
|
# @param business_id [String] The business identifier
|
|
31
31
|
#
|
|
32
32
|
# @param data [Dodopayments::Models::LicenseKey]
|
|
33
33
|
#
|
|
34
34
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
35
35
|
#
|
|
36
|
-
# @param type [Symbol,
|
|
37
|
-
|
|
38
|
-
# The event type
|
|
39
|
-
#
|
|
40
|
-
# @see Dodopayments::Models::LicenseKeyCreatedWebhookEvent#type
|
|
41
|
-
module Type
|
|
42
|
-
extend Dodopayments::Internal::Type::Enum
|
|
43
|
-
|
|
44
|
-
LICENSE_KEY_CREATED = :"license_key.created"
|
|
45
|
-
|
|
46
|
-
# @!method self.values
|
|
47
|
-
# @return [Array<Symbol>]
|
|
48
|
-
end
|
|
36
|
+
# @param type [Symbol, :"license_key.created"] The event type
|
|
49
37
|
end
|
|
50
38
|
end
|
|
51
39
|
end
|
|
@@ -139,11 +139,21 @@ module Dodopayments
|
|
|
139
139
|
nil?: true
|
|
140
140
|
|
|
141
141
|
# @!attribute discount_id
|
|
142
|
-
#
|
|
142
|
+
# @deprecated Use `discounts` instead.
|
|
143
|
+
#
|
|
144
|
+
# DEPRECATED: Use discounts instead. Returns the first discount's ID if present.
|
|
143
145
|
#
|
|
144
146
|
# @return [String, nil]
|
|
145
147
|
optional :discount_id, String, nil?: true
|
|
146
148
|
|
|
149
|
+
# @!attribute discounts
|
|
150
|
+
# All stacked discounts applied, ordered by position
|
|
151
|
+
#
|
|
152
|
+
# @return [Array<Dodopayments::Models::Payment::Discount>, nil]
|
|
153
|
+
optional :discounts,
|
|
154
|
+
-> { Dodopayments::Internal::Type::ArrayOf[Dodopayments::Payment::Discount] },
|
|
155
|
+
nil?: true
|
|
156
|
+
|
|
147
157
|
# @!attribute error_code
|
|
148
158
|
# An error code if the payment failed
|
|
149
159
|
#
|
|
@@ -233,7 +243,7 @@ module Dodopayments
|
|
|
233
243
|
# @return [Time, nil]
|
|
234
244
|
optional :updated_at, Time, nil?: true
|
|
235
245
|
|
|
236
|
-
# @!method initialize(billing:, brand_id:, business_id:, created_at:, currency:, customer:, digital_products_delivered:, disputes:, metadata:, payment_id:, refunds:, settlement_amount:, settlement_currency:, total_amount:, card_holder_name: nil, card_issuing_country: nil, card_last_four: nil, card_network: nil, card_type: nil, checkout_session_id: nil, custom_field_responses: nil, discount_id: nil, error_code: nil, error_message: nil, invoice_id: nil, invoice_url: nil, payment_link: nil, payment_method: nil, payment_method_type: nil, product_cart: nil, refund_status: nil, settlement_tax: nil, status: nil, subscription_id: nil, tax: nil, updated_at: nil)
|
|
246
|
+
# @!method initialize(billing:, brand_id:, business_id:, created_at:, currency:, customer:, digital_products_delivered:, disputes:, metadata:, payment_id:, refunds:, settlement_amount:, settlement_currency:, total_amount:, card_holder_name: nil, card_issuing_country: nil, card_last_four: nil, card_network: nil, card_type: nil, checkout_session_id: nil, custom_field_responses: nil, discount_id: nil, discounts: nil, error_code: nil, error_message: nil, invoice_id: nil, invoice_url: nil, payment_link: nil, payment_method: nil, payment_method_type: nil, product_cart: nil, refund_status: nil, settlement_tax: nil, status: nil, subscription_id: nil, tax: nil, updated_at: nil)
|
|
237
247
|
# Some parameter documentations has been truncated, see
|
|
238
248
|
# {Dodopayments::Models::Payment} for more details.
|
|
239
249
|
#
|
|
@@ -279,7 +289,9 @@ module Dodopayments
|
|
|
279
289
|
#
|
|
280
290
|
# @param custom_field_responses [Array<Dodopayments::Models::CustomFieldResponse>, nil] Customer's responses to custom fields collected during checkout
|
|
281
291
|
#
|
|
282
|
-
# @param discount_id [String, nil]
|
|
292
|
+
# @param discount_id [String, nil] DEPRECATED: Use discounts instead. Returns the first discount's ID if present.
|
|
293
|
+
#
|
|
294
|
+
# @param discounts [Array<Dodopayments::Models::Payment::Discount>, nil] All stacked discounts applied, ordered by position
|
|
283
295
|
#
|
|
284
296
|
# @param error_code [String, nil] An error code if the payment failed
|
|
285
297
|
#
|
|
@@ -309,6 +321,144 @@ module Dodopayments
|
|
|
309
321
|
#
|
|
310
322
|
# @param updated_at [Time, nil] Timestamp when the payment was last updated
|
|
311
323
|
|
|
324
|
+
class Discount < Dodopayments::Internal::Type::BaseModel
|
|
325
|
+
# @!attribute amount
|
|
326
|
+
# The discount amount (basis points for percentage, USD cents for flat)
|
|
327
|
+
#
|
|
328
|
+
# @return [Integer]
|
|
329
|
+
required :amount, Integer
|
|
330
|
+
|
|
331
|
+
# @!attribute business_id
|
|
332
|
+
# The business this discount belongs to
|
|
333
|
+
#
|
|
334
|
+
# @return [String]
|
|
335
|
+
required :business_id, String
|
|
336
|
+
|
|
337
|
+
# @!attribute code
|
|
338
|
+
# The discount code
|
|
339
|
+
#
|
|
340
|
+
# @return [String]
|
|
341
|
+
required :code, String
|
|
342
|
+
|
|
343
|
+
# @!attribute created_at
|
|
344
|
+
# Timestamp when the discount was created
|
|
345
|
+
#
|
|
346
|
+
# @return [Time]
|
|
347
|
+
required :created_at, Time
|
|
348
|
+
|
|
349
|
+
# @!attribute discount_id
|
|
350
|
+
# The unique discount ID
|
|
351
|
+
#
|
|
352
|
+
# @return [String]
|
|
353
|
+
required :discount_id, String
|
|
354
|
+
|
|
355
|
+
# @!attribute metadata
|
|
356
|
+
# Additional metadata
|
|
357
|
+
#
|
|
358
|
+
# @return [Hash{Symbol=>String}]
|
|
359
|
+
required :metadata, Dodopayments::Internal::Type::HashOf[String]
|
|
360
|
+
|
|
361
|
+
# @!attribute position
|
|
362
|
+
# Position of this discount in the stack (0-based)
|
|
363
|
+
#
|
|
364
|
+
# @return [Integer]
|
|
365
|
+
required :position, Integer
|
|
366
|
+
|
|
367
|
+
# @!attribute preserve_on_plan_change
|
|
368
|
+
# Whether this discount should be preserved when a subscription changes plans
|
|
369
|
+
#
|
|
370
|
+
# @return [Boolean]
|
|
371
|
+
required :preserve_on_plan_change, Dodopayments::Internal::Type::Boolean
|
|
372
|
+
|
|
373
|
+
# @!attribute restricted_to
|
|
374
|
+
# List of product IDs to which this discount is restricted
|
|
375
|
+
#
|
|
376
|
+
# @return [Array<String>]
|
|
377
|
+
required :restricted_to, Dodopayments::Internal::Type::ArrayOf[String]
|
|
378
|
+
|
|
379
|
+
# @!attribute times_used
|
|
380
|
+
# How many times this discount has been used
|
|
381
|
+
#
|
|
382
|
+
# @return [Integer]
|
|
383
|
+
required :times_used, Integer
|
|
384
|
+
|
|
385
|
+
# @!attribute type
|
|
386
|
+
# The type of discount
|
|
387
|
+
#
|
|
388
|
+
# @return [Symbol, Dodopayments::Models::DiscountType]
|
|
389
|
+
required :type, enum: -> { Dodopayments::DiscountType }
|
|
390
|
+
|
|
391
|
+
# @!attribute cycles_remaining
|
|
392
|
+
# Remaining billing cycles for this discount on this subscription (None for
|
|
393
|
+
# one-time payments)
|
|
394
|
+
#
|
|
395
|
+
# @return [Integer, nil]
|
|
396
|
+
optional :cycles_remaining, Integer, nil?: true
|
|
397
|
+
|
|
398
|
+
# @!attribute expires_at
|
|
399
|
+
# Optional date/time after which discount is expired
|
|
400
|
+
#
|
|
401
|
+
# @return [Time, nil]
|
|
402
|
+
optional :expires_at, Time, nil?: true
|
|
403
|
+
|
|
404
|
+
# @!attribute name
|
|
405
|
+
# Name for the Discount
|
|
406
|
+
#
|
|
407
|
+
# @return [String, nil]
|
|
408
|
+
optional :name, String, nil?: true
|
|
409
|
+
|
|
410
|
+
# @!attribute subscription_cycles
|
|
411
|
+
# Number of subscription billing cycles this discount is valid for
|
|
412
|
+
#
|
|
413
|
+
# @return [Integer, nil]
|
|
414
|
+
optional :subscription_cycles, Integer, nil?: true
|
|
415
|
+
|
|
416
|
+
# @!attribute usage_limit
|
|
417
|
+
# Usage limit for this discount, if any
|
|
418
|
+
#
|
|
419
|
+
# @return [Integer, nil]
|
|
420
|
+
optional :usage_limit, Integer, nil?: true
|
|
421
|
+
|
|
422
|
+
# @!method initialize(amount:, business_id:, code:, created_at:, discount_id:, metadata:, position:, preserve_on_plan_change:, restricted_to:, times_used:, type:, cycles_remaining: nil, expires_at: nil, name: nil, subscription_cycles: nil, usage_limit: nil)
|
|
423
|
+
# Some parameter documentations has been truncated, see
|
|
424
|
+
# {Dodopayments::Models::Payment::Discount} for more details.
|
|
425
|
+
#
|
|
426
|
+
# Response struct for a discount with its position in a stack and optional
|
|
427
|
+
# cycle-tracking information (for subscriptions).
|
|
428
|
+
#
|
|
429
|
+
# @param amount [Integer] The discount amount (basis points for percentage, USD cents for flat)
|
|
430
|
+
#
|
|
431
|
+
# @param business_id [String] The business this discount belongs to
|
|
432
|
+
#
|
|
433
|
+
# @param code [String] The discount code
|
|
434
|
+
#
|
|
435
|
+
# @param created_at [Time] Timestamp when the discount was created
|
|
436
|
+
#
|
|
437
|
+
# @param discount_id [String] The unique discount ID
|
|
438
|
+
#
|
|
439
|
+
# @param metadata [Hash{Symbol=>String}] Additional metadata
|
|
440
|
+
#
|
|
441
|
+
# @param position [Integer] Position of this discount in the stack (0-based)
|
|
442
|
+
#
|
|
443
|
+
# @param preserve_on_plan_change [Boolean] Whether this discount should be preserved when a subscription changes plans
|
|
444
|
+
#
|
|
445
|
+
# @param restricted_to [Array<String>] List of product IDs to which this discount is restricted
|
|
446
|
+
#
|
|
447
|
+
# @param times_used [Integer] How many times this discount has been used
|
|
448
|
+
#
|
|
449
|
+
# @param type [Symbol, Dodopayments::Models::DiscountType] The type of discount
|
|
450
|
+
#
|
|
451
|
+
# @param cycles_remaining [Integer, nil] Remaining billing cycles for this discount on this subscription (None for one-ti
|
|
452
|
+
#
|
|
453
|
+
# @param expires_at [Time, nil] Optional date/time after which discount is expired
|
|
454
|
+
#
|
|
455
|
+
# @param name [String, nil] Name for the Discount
|
|
456
|
+
#
|
|
457
|
+
# @param subscription_cycles [Integer, nil] Number of subscription billing cycles this discount is valid for
|
|
458
|
+
#
|
|
459
|
+
# @param usage_limit [Integer, nil] Usage limit for this discount, if any
|
|
460
|
+
end
|
|
461
|
+
|
|
312
462
|
class ProductCart < Dodopayments::Internal::Type::BaseModel
|
|
313
463
|
# @!attribute product_id
|
|
314
464
|
#
|
|
@@ -23,29 +23,17 @@ module Dodopayments
|
|
|
23
23
|
# @!attribute type
|
|
24
24
|
# The event type
|
|
25
25
|
#
|
|
26
|
-
# @return [Symbol,
|
|
27
|
-
required :type,
|
|
26
|
+
# @return [Symbol, :"payment.cancelled"]
|
|
27
|
+
required :type, const: :"payment.cancelled"
|
|
28
28
|
|
|
29
|
-
# @!method initialize(business_id:, data:, timestamp:, type:)
|
|
29
|
+
# @!method initialize(business_id:, data:, timestamp:, type: :"payment.cancelled")
|
|
30
30
|
# @param business_id [String] The business identifier
|
|
31
31
|
#
|
|
32
32
|
# @param data [Dodopayments::Models::Payment]
|
|
33
33
|
#
|
|
34
34
|
# @param timestamp [Time] The timestamp of when the event occurred
|
|
35
35
|
#
|
|
36
|
-
# @param type [Symbol,
|
|
37
|
-
|
|
38
|
-
# The event type
|
|
39
|
-
#
|
|
40
|
-
# @see Dodopayments::Models::PaymentCancelledWebhookEvent#type
|
|
41
|
-
module Type
|
|
42
|
-
extend Dodopayments::Internal::Type::Enum
|
|
43
|
-
|
|
44
|
-
PAYMENT_CANCELLED = :"payment.cancelled"
|
|
45
|
-
|
|
46
|
-
# @!method self.values
|
|
47
|
-
# @return [Array<Symbol>]
|
|
48
|
-
end
|
|
36
|
+
# @param type [Symbol, :"payment.cancelled"] The event type
|
|
49
37
|
end
|
|
50
38
|
end
|
|
51
39
|
end
|
|
@@ -53,11 +53,21 @@ module Dodopayments
|
|
|
53
53
|
optional :billing_currency, enum: -> { Dodopayments::Currency }, nil?: true
|
|
54
54
|
|
|
55
55
|
# @!attribute discount_code
|
|
56
|
-
#
|
|
56
|
+
# @deprecated Use `discount_id` instead.
|
|
57
|
+
#
|
|
58
|
+
# DEPRECATED: Use discount_codes instead. Cannot be used together with
|
|
59
|
+
# discount_codes.
|
|
57
60
|
#
|
|
58
61
|
# @return [String, nil]
|
|
59
62
|
optional :discount_code, String, nil?: true
|
|
60
63
|
|
|
64
|
+
# @!attribute discount_codes
|
|
65
|
+
# Stacked discount codes to apply, in order of application. Max 20. Cannot be used
|
|
66
|
+
# together with discount_code.
|
|
67
|
+
#
|
|
68
|
+
# @return [Array<String>, nil]
|
|
69
|
+
optional :discount_codes, Dodopayments::Internal::Type::ArrayOf[String], nil?: true
|
|
70
|
+
|
|
61
71
|
# @!attribute force_3ds
|
|
62
72
|
# Override merchant default 3DS behaviour for this payment
|
|
63
73
|
#
|
|
@@ -126,7 +136,7 @@ module Dodopayments
|
|
|
126
136
|
# @return [String, nil]
|
|
127
137
|
optional :tax_id, String, nil?: true
|
|
128
138
|
|
|
129
|
-
# @!method initialize(billing:, customer:, product_cart:, adaptive_currency_fees_inclusive: nil, allowed_payment_method_types: nil, billing_currency: nil, discount_code: nil, force_3ds: nil, metadata: nil, payment_link: nil, payment_method_id: nil, redirect_immediately: nil, require_phone_number: nil, return_url: nil, short_link: nil, show_saved_payment_methods: nil, tax_id: nil, request_options: {})
|
|
139
|
+
# @!method initialize(billing:, customer:, product_cart:, adaptive_currency_fees_inclusive: nil, allowed_payment_method_types: nil, billing_currency: nil, discount_code: nil, discount_codes: nil, force_3ds: nil, metadata: nil, payment_link: nil, payment_method_id: nil, redirect_immediately: nil, require_phone_number: nil, return_url: nil, short_link: nil, show_saved_payment_methods: nil, tax_id: nil, request_options: {})
|
|
130
140
|
# Some parameter documentations has been truncated, see
|
|
131
141
|
# {Dodopayments::Models::PaymentCreateParams} for more details.
|
|
132
142
|
#
|
|
@@ -142,7 +152,9 @@ module Dodopayments
|
|
|
142
152
|
#
|
|
143
153
|
# @param billing_currency [Symbol, Dodopayments::Models::Currency, nil] Fix the currency in which the end customer is billed.
|
|
144
154
|
#
|
|
145
|
-
# @param discount_code [String, nil]
|
|
155
|
+
# @param discount_code [String, nil] DEPRECATED: Use discount_codes instead. Cannot be used together with discount_co
|
|
156
|
+
#
|
|
157
|
+
# @param discount_codes [Array<String>, nil] Stacked discount codes to apply, in order of application. Max 20.
|
|
146
158
|
#
|
|
147
159
|
# @param force_3ds [Boolean, nil] Override merchant default 3DS behaviour for this payment
|
|
148
160
|
#
|