dodopayments 2.18.1 → 2.19.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 +8 -0
- data/README.md +1 -1
- data/lib/dodopayments/models/checkout_session_request.rb +5 -3
- data/lib/dodopayments/models/credit_entitlements/balance_create_ledger_entry_params.rb +5 -3
- data/lib/dodopayments/models/credit_entitlements/balance_list_grants_response.rb +24 -3
- data/lib/dodopayments/models/credit_entitlements/credit_ledger_entry.rb +3 -3
- data/lib/dodopayments/models/customer.rb +3 -3
- data/lib/dodopayments/models/customer_create_params.rb +3 -3
- data/lib/dodopayments/models/customer_limited_details.rb +3 -3
- data/lib/dodopayments/models/customer_list_entitlement_grants_params.rb +85 -0
- data/lib/dodopayments/models/customer_update_params.rb +5 -3
- data/lib/dodopayments/models/discount.rb +4 -3
- data/lib/dodopayments/models/discount_create_params.rb +3 -3
- data/lib/dodopayments/models/discount_detail.rb +3 -3
- data/lib/dodopayments/models/discount_update_params.rb +5 -3
- data/lib/dodopayments/models/entitlement.rb +5 -5
- data/lib/dodopayments/models/entitlement_create_params.rb +5 -5
- data/lib/dodopayments/models/entitlement_integration_type.rb +1 -0
- data/lib/dodopayments/models/entitlement_list_params.rb +1 -0
- data/lib/dodopayments/models/entitlement_update_params.rb +12 -5
- data/lib/dodopayments/models/entitlements/entitlement_grant.rb +13 -4
- data/lib/dodopayments/models/feature.rb +26 -0
- data/lib/dodopayments/models/feature_type.rb +15 -0
- data/lib/dodopayments/models/integration_config.rb +30 -1
- data/lib/dodopayments/models/integration_config_response.rb +22 -1
- data/lib/dodopayments/models/metadata.rb +15 -1
- data/lib/dodopayments/models/payment.rb +3 -3
- data/lib/dodopayments/models/payment_create_params.rb +3 -3
- data/lib/dodopayments/models/payment_create_response.rb +3 -3
- data/lib/dodopayments/models/payment_list_response.rb +4 -3
- data/lib/dodopayments/models/product.rb +3 -3
- data/lib/dodopayments/models/product_create_params.rb +3 -3
- data/lib/dodopayments/models/product_entitlement_summary.rb +2 -2
- data/lib/dodopayments/models/product_list_response.rb +3 -3
- data/lib/dodopayments/models/product_update_params.rb +5 -3
- data/lib/dodopayments/models/refund.rb +3 -3
- data/lib/dodopayments/models/refund_create_params.rb +3 -3
- data/lib/dodopayments/models/subscription.rb +3 -3
- data/lib/dodopayments/models/subscription_charge_params.rb +5 -3
- data/lib/dodopayments/models/subscription_create_params.rb +3 -3
- data/lib/dodopayments/models/subscription_create_response.rb +3 -3
- data/lib/dodopayments/models/subscription_list_response.rb +3 -3
- data/lib/dodopayments/models/subscription_update_params.rb +6 -3
- data/lib/dodopayments/models/update_subscription_plan_req.rb +5 -3
- data/lib/dodopayments/models.rb +8 -0
- data/lib/dodopayments/resources/checkout_sessions.rb +2 -2
- data/lib/dodopayments/resources/credit_entitlements/balances.rb +1 -1
- data/lib/dodopayments/resources/customers.rb +35 -2
- data/lib/dodopayments/resources/discounts.rb +2 -2
- data/lib/dodopayments/resources/entitlements.rb +4 -4
- data/lib/dodopayments/resources/payments.rb +1 -1
- data/lib/dodopayments/resources/products.rb +2 -2
- data/lib/dodopayments/resources/refunds.rb +1 -1
- data/lib/dodopayments/resources/subscriptions.rb +5 -5
- data/lib/dodopayments/version.rb +1 -1
- data/lib/dodopayments.rb +3 -0
- data/rbi/dodopayments/models/checkout_session_request.rbi +9 -3
- data/rbi/dodopayments/models/credit_entitlements/balance_create_ledger_entry_params.rbi +11 -3
- data/rbi/dodopayments/models/credit_entitlements/balance_list_grants_response.rbi +13 -3
- data/rbi/dodopayments/models/credit_entitlements/credit_ledger_entry.rbi +3 -3
- data/rbi/dodopayments/models/customer.rbi +12 -4
- data/rbi/dodopayments/models/customer_create_params.rbi +12 -4
- data/rbi/dodopayments/models/customer_limited_details.rbi +12 -4
- data/rbi/dodopayments/models/customer_list_entitlement_grants_params.rbi +229 -0
- data/rbi/dodopayments/models/customer_update_params.rbi +9 -3
- data/rbi/dodopayments/models/discount.rbi +5 -3
- data/rbi/dodopayments/models/discount_create_params.rbi +12 -4
- data/rbi/dodopayments/models/discount_detail.rbi +3 -3
- data/rbi/dodopayments/models/discount_update_params.rbi +9 -3
- data/rbi/dodopayments/models/entitlement.rbi +4 -3
- data/rbi/dodopayments/models/entitlement_create_params.rbi +15 -4
- data/rbi/dodopayments/models/entitlement_integration_type.rbi +5 -0
- data/rbi/dodopayments/models/entitlement_list_params.rbi +5 -0
- data/rbi/dodopayments/models/entitlement_update_params.rbi +22 -3
- data/rbi/dodopayments/models/entitlements/entitlement_grant.rbi +16 -3
- data/rbi/dodopayments/models/feature.rbi +46 -0
- data/rbi/dodopayments/models/feature_type.rbi +21 -0
- data/rbi/dodopayments/models/integration_config.rbi +50 -0
- data/rbi/dodopayments/models/integration_config_response.rbi +44 -0
- data/rbi/dodopayments/models/metadata.rbi +12 -1
- data/rbi/dodopayments/models/payment.rbi +3 -3
- data/rbi/dodopayments/models/payment_create_params.rbi +12 -4
- data/rbi/dodopayments/models/payment_create_response.rbi +3 -3
- data/rbi/dodopayments/models/payment_list_response.rbi +5 -3
- data/rbi/dodopayments/models/product.rbi +3 -3
- data/rbi/dodopayments/models/product_create_params.rbi +12 -4
- data/rbi/dodopayments/models/product_entitlement_summary.rbi +1 -0
- data/rbi/dodopayments/models/product_list_response.rbi +3 -3
- data/rbi/dodopayments/models/product_update_params.rbi +9 -3
- data/rbi/dodopayments/models/refund.rbi +3 -3
- data/rbi/dodopayments/models/refund_create_params.rbi +12 -4
- data/rbi/dodopayments/models/subscription.rbi +3 -3
- data/rbi/dodopayments/models/subscription_charge_params.rbi +9 -3
- data/rbi/dodopayments/models/subscription_create_params.rbi +12 -4
- data/rbi/dodopayments/models/subscription_create_response.rbi +3 -3
- data/rbi/dodopayments/models/subscription_list_response.rbi +3 -3
- data/rbi/dodopayments/models/subscription_update_params.rbi +11 -3
- data/rbi/dodopayments/models/update_subscription_plan_req.rbi +9 -3
- data/rbi/dodopayments/models.rbi +9 -0
- data/rbi/dodopayments/resources/checkout_sessions.rbi +4 -2
- data/rbi/dodopayments/resources/credit_entitlements/balances.rbi +2 -1
- data/rbi/dodopayments/resources/customers.rbi +36 -2
- data/rbi/dodopayments/resources/discounts.rbi +3 -2
- data/rbi/dodopayments/resources/entitlements.rbi +10 -2
- data/rbi/dodopayments/resources/payments.rbi +1 -1
- data/rbi/dodopayments/resources/products.rbi +3 -2
- data/rbi/dodopayments/resources/refunds.rbi +1 -1
- data/rbi/dodopayments/resources/subscriptions.rbi +10 -5
- data/sig/dodopayments/models/customer_list_entitlement_grants_params.rbs +98 -0
- data/sig/dodopayments/models/entitlement_integration_type.rbs +2 -0
- data/sig/dodopayments/models/entitlement_list_params.rbs +2 -0
- data/sig/dodopayments/models/entitlements/entitlement_grant.rbs +5 -0
- data/sig/dodopayments/models/feature.rbs +22 -0
- data/sig/dodopayments/models/feature_type.rbs +13 -0
- data/sig/dodopayments/models/integration_config.rbs +21 -1
- data/sig/dodopayments/models/integration_config_response.rbs +21 -1
- data/sig/dodopayments/models/metadata.rbs +9 -1
- data/sig/dodopayments/models.rbs +8 -0
- data/sig/dodopayments/resources/customers.rbs +9 -0
- metadata +11 -2
|
@@ -4,9 +4,15 @@ module Dodopayments
|
|
|
4
4
|
module Models
|
|
5
5
|
# Integration-specific configuration supplied when creating or updating an
|
|
6
6
|
# entitlement. The shape required matches the entitlement's `integration_type`.
|
|
7
|
+
#
|
|
8
|
+
# Untagged enum: variants are matched in order. `FeatureFlag` must precede
|
|
9
|
+
# `LicenseKey`, whose fields are all optional and would otherwise match a
|
|
10
|
+
# `feature_flag` config.
|
|
7
11
|
module IntegrationConfig
|
|
8
12
|
extend Dodopayments::Internal::Type::Union
|
|
9
13
|
|
|
14
|
+
variant -> { Dodopayments::IntegrationConfig::FeatureFlagConfig }
|
|
15
|
+
|
|
10
16
|
variant -> { Dodopayments::IntegrationConfig::GitHubConfig }
|
|
11
17
|
|
|
12
18
|
variant -> { Dodopayments::IntegrationConfig::DiscordConfig }
|
|
@@ -23,6 +29,29 @@ module Dodopayments
|
|
|
23
29
|
|
|
24
30
|
variant -> { Dodopayments::IntegrationConfig::LicenseKeyConfig }
|
|
25
31
|
|
|
32
|
+
class FeatureFlagConfig < Dodopayments::Internal::Type::BaseModel
|
|
33
|
+
# @!attribute feature_id
|
|
34
|
+
# Merchant-chosen identifier for the capability this entitlement unlocks. Not
|
|
35
|
+
# unique across entitlements.
|
|
36
|
+
#
|
|
37
|
+
# @return [String]
|
|
38
|
+
required :feature_id, String
|
|
39
|
+
|
|
40
|
+
# @!attribute feature_type
|
|
41
|
+
# Type of capability conferred.
|
|
42
|
+
#
|
|
43
|
+
# @return [Symbol, Dodopayments::Models::FeatureType]
|
|
44
|
+
required :feature_type, enum: -> { Dodopayments::FeatureType }
|
|
45
|
+
|
|
46
|
+
# @!method initialize(feature_id:, feature_type:)
|
|
47
|
+
# Some parameter documentations has been truncated, see
|
|
48
|
+
# {Dodopayments::Models::IntegrationConfig::FeatureFlagConfig} for more details.
|
|
49
|
+
#
|
|
50
|
+
# @param feature_id [String] Merchant-chosen identifier for the capability this entitlement
|
|
51
|
+
#
|
|
52
|
+
# @param feature_type [Symbol, Dodopayments::Models::FeatureType] Type of capability conferred.
|
|
53
|
+
end
|
|
54
|
+
|
|
26
55
|
class GitHubConfig < Dodopayments::Internal::Type::BaseModel
|
|
27
56
|
# @!attribute permission
|
|
28
57
|
# Permission to grant on the repository.
|
|
@@ -222,7 +251,7 @@ module Dodopayments
|
|
|
222
251
|
end
|
|
223
252
|
|
|
224
253
|
# @!method self.variants
|
|
225
|
-
# @return [Array(Dodopayments::Models::IntegrationConfig::GitHubConfig, Dodopayments::Models::IntegrationConfig::DiscordConfig, Dodopayments::Models::IntegrationConfig::TelegramConfig, Dodopayments::Models::IntegrationConfig::FigmaConfig, Dodopayments::Models::IntegrationConfig::FramerConfig, Dodopayments::Models::IntegrationConfig::NotionConfig, Dodopayments::Models::IntegrationConfig::DigitalFilesConfig, Dodopayments::Models::IntegrationConfig::LicenseKeyConfig)]
|
|
254
|
+
# @return [Array(Dodopayments::Models::IntegrationConfig::FeatureFlagConfig, Dodopayments::Models::IntegrationConfig::GitHubConfig, Dodopayments::Models::IntegrationConfig::DiscordConfig, Dodopayments::Models::IntegrationConfig::TelegramConfig, Dodopayments::Models::IntegrationConfig::FigmaConfig, Dodopayments::Models::IntegrationConfig::FramerConfig, Dodopayments::Models::IntegrationConfig::NotionConfig, Dodopayments::Models::IntegrationConfig::DigitalFilesConfig, Dodopayments::Models::IntegrationConfig::LicenseKeyConfig)]
|
|
226
255
|
end
|
|
227
256
|
end
|
|
228
257
|
end
|
|
@@ -9,6 +9,8 @@ module Dodopayments
|
|
|
9
9
|
module IntegrationConfigResponse
|
|
10
10
|
extend Dodopayments::Internal::Type::Union
|
|
11
11
|
|
|
12
|
+
variant -> { Dodopayments::IntegrationConfigResponse::FeatureFlagConfig }
|
|
13
|
+
|
|
12
14
|
variant -> { Dodopayments::IntegrationConfigResponse::GitHubConfig }
|
|
13
15
|
|
|
14
16
|
variant -> { Dodopayments::IntegrationConfigResponse::DiscordConfig }
|
|
@@ -25,6 +27,25 @@ module Dodopayments
|
|
|
25
27
|
|
|
26
28
|
variant -> { Dodopayments::IntegrationConfigResponse::LicenseKeyConfig }
|
|
27
29
|
|
|
30
|
+
class FeatureFlagConfig < Dodopayments::Internal::Type::BaseModel
|
|
31
|
+
# @!attribute feature_id
|
|
32
|
+
# Merchant-chosen identifier for the capability this entitlement unlocks.
|
|
33
|
+
#
|
|
34
|
+
# @return [String]
|
|
35
|
+
required :feature_id, String
|
|
36
|
+
|
|
37
|
+
# @!attribute feature_type
|
|
38
|
+
# Type of capability conferred. Only `boolean` is supported today.
|
|
39
|
+
#
|
|
40
|
+
# @return [Symbol, Dodopayments::Models::FeatureType]
|
|
41
|
+
required :feature_type, enum: -> { Dodopayments::FeatureType }
|
|
42
|
+
|
|
43
|
+
# @!method initialize(feature_id:, feature_type:)
|
|
44
|
+
# @param feature_id [String] Merchant-chosen identifier for the capability this entitlement unlocks.
|
|
45
|
+
#
|
|
46
|
+
# @param feature_type [Symbol, Dodopayments::Models::FeatureType] Type of capability conferred. Only `boolean` is supported today.
|
|
47
|
+
end
|
|
48
|
+
|
|
28
49
|
class GitHubConfig < Dodopayments::Internal::Type::BaseModel
|
|
29
50
|
# @!attribute permission
|
|
30
51
|
# Permission to grant on the repository.
|
|
@@ -283,7 +304,7 @@ module Dodopayments
|
|
|
283
304
|
end
|
|
284
305
|
|
|
285
306
|
# @!method self.variants
|
|
286
|
-
# @return [Array(Dodopayments::Models::IntegrationConfigResponse::GitHubConfig, Dodopayments::Models::IntegrationConfigResponse::DiscordConfig, Dodopayments::Models::IntegrationConfigResponse::TelegramConfig, Dodopayments::Models::IntegrationConfigResponse::FigmaConfig, Dodopayments::Models::IntegrationConfigResponse::FramerConfig, Dodopayments::Models::IntegrationConfigResponse::NotionConfig, Dodopayments::Models::IntegrationConfigResponse::DigitalFilesConfig, Dodopayments::Models::IntegrationConfigResponse::LicenseKeyConfig)]
|
|
307
|
+
# @return [Array(Dodopayments::Models::IntegrationConfigResponse::FeatureFlagConfig, Dodopayments::Models::IntegrationConfigResponse::GitHubConfig, Dodopayments::Models::IntegrationConfigResponse::DiscordConfig, Dodopayments::Models::IntegrationConfigResponse::TelegramConfig, Dodopayments::Models::IntegrationConfigResponse::FigmaConfig, Dodopayments::Models::IntegrationConfigResponse::FramerConfig, Dodopayments::Models::IntegrationConfigResponse::NotionConfig, Dodopayments::Models::IntegrationConfigResponse::DigitalFilesConfig, Dodopayments::Models::IntegrationConfigResponse::LicenseKeyConfig)]
|
|
287
308
|
end
|
|
288
309
|
end
|
|
289
310
|
end
|
|
@@ -2,7 +2,21 @@
|
|
|
2
2
|
|
|
3
3
|
module Dodopayments
|
|
4
4
|
module Models
|
|
5
|
+
# Metadata value can be a string, integer, number, or boolean
|
|
6
|
+
module MetadataItem
|
|
7
|
+
extend Dodopayments::Internal::Type::Union
|
|
8
|
+
|
|
9
|
+
variant String
|
|
10
|
+
|
|
11
|
+
variant Float
|
|
12
|
+
|
|
13
|
+
variant Dodopayments::Internal::Type::Boolean
|
|
14
|
+
|
|
15
|
+
# @!method self.variants
|
|
16
|
+
# @return [Array(String, Float, Boolean)]
|
|
17
|
+
end
|
|
18
|
+
|
|
5
19
|
# @type [Dodopayments::Internal::Type::Converter]
|
|
6
|
-
Metadata = Dodopayments::Internal::Type::HashOf[
|
|
20
|
+
Metadata = Dodopayments::Internal::Type::HashOf[union: -> { Dodopayments::MetadataItem }]
|
|
7
21
|
end
|
|
8
22
|
end
|
|
@@ -55,8 +55,8 @@ module Dodopayments
|
|
|
55
55
|
# @!attribute metadata
|
|
56
56
|
# Additional custom data associated with the payment
|
|
57
57
|
#
|
|
58
|
-
# @return [Hash{Symbol=>String}]
|
|
59
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
58
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
59
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
60
60
|
|
|
61
61
|
# @!attribute payment_id
|
|
62
62
|
# Unique identifier for the payment
|
|
@@ -280,7 +280,7 @@ module Dodopayments
|
|
|
280
280
|
#
|
|
281
281
|
# @param disputes [Array<Dodopayments::Models::Dispute>] List of disputes associated with this payment
|
|
282
282
|
#
|
|
283
|
-
# @param metadata [Hash{Symbol=>String}] Additional custom data associated with the payment
|
|
283
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional custom data associated with the payment
|
|
284
284
|
#
|
|
285
285
|
# @param payment_id [String] Unique identifier for the payment
|
|
286
286
|
#
|
|
@@ -86,8 +86,8 @@ module Dodopayments
|
|
|
86
86
|
# Additional metadata associated with the payment. Defaults to empty if not
|
|
87
87
|
# provided.
|
|
88
88
|
#
|
|
89
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
90
|
-
optional :metadata, Dodopayments::Internal::Type::HashOf[
|
|
89
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
90
|
+
optional :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
91
91
|
|
|
92
92
|
# @!attribute payment_link
|
|
93
93
|
# Whether to generate a payment link. Defaults to false if not specified.
|
|
@@ -168,7 +168,7 @@ module Dodopayments
|
|
|
168
168
|
#
|
|
169
169
|
# @param force_3ds [Boolean, nil] Override merchant default 3DS behaviour for this payment
|
|
170
170
|
#
|
|
171
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata associated with the payment.
|
|
171
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata associated with the payment.
|
|
172
172
|
#
|
|
173
173
|
# @param payment_link [Boolean, nil] Whether to generate a payment link. Defaults to false if not specified.
|
|
174
174
|
#
|
|
@@ -20,8 +20,8 @@ module Dodopayments
|
|
|
20
20
|
# @!attribute metadata
|
|
21
21
|
# Additional metadata associated with the payment
|
|
22
22
|
#
|
|
23
|
-
# @return [Hash{Symbol=>String}]
|
|
24
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
23
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
24
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
25
25
|
|
|
26
26
|
# @!attribute payment_id
|
|
27
27
|
# Unique identifier for the payment
|
|
@@ -79,7 +79,7 @@ module Dodopayments
|
|
|
79
79
|
#
|
|
80
80
|
# @param customer [Dodopayments::Models::CustomerLimitedDetails] Limited details about the customer making the payment
|
|
81
81
|
#
|
|
82
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata associated with the payment
|
|
82
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata associated with the payment
|
|
83
83
|
#
|
|
84
84
|
# @param payment_id [String] Unique identifier for the payment
|
|
85
85
|
#
|
|
@@ -35,9 +35,10 @@ module Dodopayments
|
|
|
35
35
|
required :has_license_key, Dodopayments::Internal::Type::Boolean
|
|
36
36
|
|
|
37
37
|
# @!attribute metadata
|
|
38
|
+
# Arbitrary key-value metadata. Values can be string, integer, number, or boolean.
|
|
38
39
|
#
|
|
39
|
-
# @return [Hash{Symbol=>String}]
|
|
40
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
40
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
41
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
41
42
|
|
|
42
43
|
# @!attribute payment_id
|
|
43
44
|
#
|
|
@@ -129,7 +130,7 @@ module Dodopayments
|
|
|
129
130
|
#
|
|
130
131
|
# @param has_license_key [Boolean]
|
|
131
132
|
#
|
|
132
|
-
# @param metadata [Hash{Symbol=>String}]
|
|
133
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Arbitrary key-value metadata. Values can be string, integer, number, or boolean.
|
|
133
134
|
#
|
|
134
135
|
# @param payment_id [String]
|
|
135
136
|
#
|
|
@@ -52,8 +52,8 @@ module Dodopayments
|
|
|
52
52
|
# @!attribute metadata
|
|
53
53
|
# Additional custom data associated with the product
|
|
54
54
|
#
|
|
55
|
-
# @return [Hash{Symbol=>String}]
|
|
56
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
55
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
56
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
57
57
|
|
|
58
58
|
# @!attribute price
|
|
59
59
|
# Pricing information for the product.
|
|
@@ -163,7 +163,7 @@ module Dodopayments
|
|
|
163
163
|
#
|
|
164
164
|
# @param license_key_enabled [Boolean] Indicates whether the product requires a license key.
|
|
165
165
|
#
|
|
166
|
-
# @param metadata [Hash{Symbol=>String}] Additional custom data associated with the product
|
|
166
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional custom data associated with the product
|
|
167
167
|
#
|
|
168
168
|
# @param price [Dodopayments::Models::Price::OneTimePrice, Dodopayments::Models::Price::RecurringPrice, Dodopayments::Models::Price::UsageBasedPrice] Pricing information for the product.
|
|
169
169
|
#
|
|
@@ -117,8 +117,8 @@ module Dodopayments
|
|
|
117
117
|
# @!attribute metadata
|
|
118
118
|
# Additional metadata for the product
|
|
119
119
|
#
|
|
120
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
121
|
-
optional :metadata, Dodopayments::Internal::Type::HashOf[
|
|
120
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
121
|
+
optional :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
122
122
|
|
|
123
123
|
# @!attribute pricing_mode
|
|
124
124
|
# Pricing mode for localized pricing. When set, rules from
|
|
@@ -158,7 +158,7 @@ module Dodopayments
|
|
|
158
158
|
#
|
|
159
159
|
# @param license_key_enabled [Boolean, nil] When true, generates and sends a license key to your customer.
|
|
160
160
|
#
|
|
161
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata for the product
|
|
161
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata for the product
|
|
162
162
|
#
|
|
163
163
|
# @param pricing_mode [Symbol, Dodopayments::Models::Products::PricingMode, nil] Pricing mode for localized pricing. When set, rules from
|
|
164
164
|
#
|
|
@@ -14,7 +14,7 @@ module Dodopayments
|
|
|
14
14
|
# For `digital_files` entitlements the response includes presigned download URLs
|
|
15
15
|
# for each attached file; other integrations match the shape supplied at creation.
|
|
16
16
|
#
|
|
17
|
-
# @return [Dodopayments::Models::IntegrationConfigResponse::GitHubConfig, Dodopayments::Models::IntegrationConfigResponse::DiscordConfig, Dodopayments::Models::IntegrationConfigResponse::TelegramConfig, Dodopayments::Models::IntegrationConfigResponse::FigmaConfig, Dodopayments::Models::IntegrationConfigResponse::FramerConfig, Dodopayments::Models::IntegrationConfigResponse::NotionConfig, Dodopayments::Models::IntegrationConfigResponse::DigitalFilesConfig, Dodopayments::Models::IntegrationConfigResponse::LicenseKeyConfig]
|
|
17
|
+
# @return [Dodopayments::Models::IntegrationConfigResponse::FeatureFlagConfig, Dodopayments::Models::IntegrationConfigResponse::GitHubConfig, Dodopayments::Models::IntegrationConfigResponse::DiscordConfig, Dodopayments::Models::IntegrationConfigResponse::TelegramConfig, Dodopayments::Models::IntegrationConfigResponse::FigmaConfig, Dodopayments::Models::IntegrationConfigResponse::FramerConfig, Dodopayments::Models::IntegrationConfigResponse::NotionConfig, Dodopayments::Models::IntegrationConfigResponse::DigitalFilesConfig, Dodopayments::Models::IntegrationConfigResponse::LicenseKeyConfig]
|
|
18
18
|
required :integration_config, union: -> { Dodopayments::IntegrationConfigResponse }
|
|
19
19
|
|
|
20
20
|
# @!attribute integration_type
|
|
@@ -45,7 +45,7 @@ module Dodopayments
|
|
|
45
45
|
#
|
|
46
46
|
# @param id [String]
|
|
47
47
|
#
|
|
48
|
-
# @param integration_config [Dodopayments::Models::IntegrationConfigResponse::GitHubConfig, Dodopayments::Models::IntegrationConfigResponse::DiscordConfig, Dodopayments::Models::IntegrationConfigResponse::TelegramConfig, Dodopayments::Models::IntegrationConfigResponse::FigmaConfig, Dodopayments::Models::IntegrationConfigResponse::FramerConfig, Dodopayments::Models::IntegrationConfigResponse::NotionConfig, Dodopayments::Models::IntegrationConfigResponse::DigitalFilesConfig, Dodopayments::Models::IntegrationConfigResponse::LicenseKeyConfig] Integration-specific configuration on an entitlement read response.
|
|
48
|
+
# @param integration_config [Dodopayments::Models::IntegrationConfigResponse::FeatureFlagConfig, Dodopayments::Models::IntegrationConfigResponse::GitHubConfig, Dodopayments::Models::IntegrationConfigResponse::DiscordConfig, Dodopayments::Models::IntegrationConfigResponse::TelegramConfig, Dodopayments::Models::IntegrationConfigResponse::FigmaConfig, Dodopayments::Models::IntegrationConfigResponse::FramerConfig, Dodopayments::Models::IntegrationConfigResponse::NotionConfig, Dodopayments::Models::IntegrationConfigResponse::DigitalFilesConfig, Dodopayments::Models::IntegrationConfigResponse::LicenseKeyConfig] Integration-specific configuration on an entitlement read response.
|
|
49
49
|
#
|
|
50
50
|
# @param integration_type [Symbol, Dodopayments::Models::EntitlementIntegrationType]
|
|
51
51
|
#
|
|
@@ -32,8 +32,8 @@ module Dodopayments
|
|
|
32
32
|
# @!attribute metadata
|
|
33
33
|
# Additional custom data associated with the product
|
|
34
34
|
#
|
|
35
|
-
# @return [Hash{Symbol=>String}]
|
|
36
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
35
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
36
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
37
37
|
|
|
38
38
|
# @!attribute product_id
|
|
39
39
|
# Unique identifier for the product.
|
|
@@ -123,7 +123,7 @@ module Dodopayments
|
|
|
123
123
|
#
|
|
124
124
|
# @param is_recurring [Boolean] Indicates if the product is recurring (e.g., subscriptions).
|
|
125
125
|
#
|
|
126
|
-
# @param metadata [Hash{Symbol=>String}] Additional custom data associated with the product
|
|
126
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional custom data associated with the product
|
|
127
127
|
#
|
|
128
128
|
# @param product_id [String] Unique identifier for the product.
|
|
129
129
|
#
|
|
@@ -116,8 +116,10 @@ module Dodopayments
|
|
|
116
116
|
# @!attribute metadata
|
|
117
117
|
# Additional metadata for the product
|
|
118
118
|
#
|
|
119
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
120
|
-
optional :metadata,
|
|
119
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
120
|
+
optional :metadata,
|
|
121
|
+
-> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] },
|
|
122
|
+
nil?: true
|
|
121
123
|
|
|
122
124
|
# @!attribute name
|
|
123
125
|
# Name of the product, optional and must be at most 100 characters.
|
|
@@ -173,7 +175,7 @@ module Dodopayments
|
|
|
173
175
|
#
|
|
174
176
|
# @param license_key_enabled [Boolean, nil] Whether the product requires a license key.
|
|
175
177
|
#
|
|
176
|
-
# @param metadata [Hash{Symbol=>String}, nil] Additional metadata for the product
|
|
178
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Additional metadata for the product
|
|
177
179
|
#
|
|
178
180
|
# @param name [String, nil] Name of the product, optional and must be at most 100 characters.
|
|
179
181
|
#
|
|
@@ -37,8 +37,8 @@ module Dodopayments
|
|
|
37
37
|
# @!attribute metadata
|
|
38
38
|
# Additional metadata stored with the refund.
|
|
39
39
|
#
|
|
40
|
-
# @return [Hash{Symbol=>String}]
|
|
41
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
40
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
41
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
42
42
|
|
|
43
43
|
# @!attribute payment_id
|
|
44
44
|
# The unique identifier of the payment associated with the refund.
|
|
@@ -87,7 +87,7 @@ module Dodopayments
|
|
|
87
87
|
#
|
|
88
88
|
# @param is_partial [Boolean] If true the refund is a partial refund
|
|
89
89
|
#
|
|
90
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata stored with the refund.
|
|
90
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata stored with the refund.
|
|
91
91
|
#
|
|
92
92
|
# @param payment_id [String] The unique identifier of the payment associated with the refund.
|
|
93
93
|
#
|
|
@@ -24,8 +24,8 @@ module Dodopayments
|
|
|
24
24
|
# @!attribute metadata
|
|
25
25
|
# Additional metadata associated with the refund.
|
|
26
26
|
#
|
|
27
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
28
|
-
optional :metadata, Dodopayments::Internal::Type::HashOf[
|
|
27
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
28
|
+
optional :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
29
29
|
|
|
30
30
|
# @!attribute reason
|
|
31
31
|
# The reason for the refund, if any. Maximum length is 3000 characters. Optional.
|
|
@@ -38,7 +38,7 @@ module Dodopayments
|
|
|
38
38
|
#
|
|
39
39
|
# @param items [Array<Dodopayments::Models::RefundCreateParams::Item>, nil] Partially Refund an Individual Item
|
|
40
40
|
#
|
|
41
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata associated with the refund.
|
|
41
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata associated with the refund.
|
|
42
42
|
#
|
|
43
43
|
# @param reason [String, nil] The reason for the refund, if any. Maximum length is 3000 characters. Optional.
|
|
44
44
|
#
|
|
@@ -56,8 +56,8 @@ module Dodopayments
|
|
|
56
56
|
# @!attribute metadata
|
|
57
57
|
# Additional custom data associated with the subscription
|
|
58
58
|
#
|
|
59
|
-
# @return [Hash{Symbol=>String}]
|
|
60
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
59
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
60
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
61
61
|
|
|
62
62
|
# @!attribute meter_credit_entitlement_cart
|
|
63
63
|
# Meter credit entitlement cart settings for this subscription
|
|
@@ -257,7 +257,7 @@ module Dodopayments
|
|
|
257
257
|
#
|
|
258
258
|
# @param customer [Dodopayments::Models::CustomerLimitedDetails] Customer details associated with the subscription
|
|
259
259
|
#
|
|
260
|
-
# @param metadata [Hash{Symbol=>String}] Additional custom data associated with the subscription
|
|
260
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional custom data associated with the subscription
|
|
261
261
|
#
|
|
262
262
|
# @param meter_credit_entitlement_cart [Array<Dodopayments::Models::MeterCreditEntitlementCartResponse>] Meter credit entitlement cart settings for this subscription
|
|
263
263
|
#
|
|
@@ -39,8 +39,10 @@ module Dodopayments
|
|
|
39
39
|
# Metadata for the payment. If not passed, the metadata of the subscription will
|
|
40
40
|
# be taken
|
|
41
41
|
#
|
|
42
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
43
|
-
optional :metadata,
|
|
42
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
43
|
+
optional :metadata,
|
|
44
|
+
-> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] },
|
|
45
|
+
nil?: true
|
|
44
46
|
|
|
45
47
|
# @!attribute product_currency
|
|
46
48
|
# Optional currency of the product price. If not specified, defaults to the
|
|
@@ -68,7 +70,7 @@ module Dodopayments
|
|
|
68
70
|
#
|
|
69
71
|
# @param customer_balance_config [Dodopayments::Models::SubscriptionChargeParams::CustomerBalanceConfig, nil] Specify how customer balance is used for the payment
|
|
70
72
|
#
|
|
71
|
-
# @param metadata [Hash{Symbol=>String}, nil] Metadata for the payment. If not passed, the metadata of the subscription will b
|
|
73
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Metadata for the payment. If not passed, the metadata of the subscription will b
|
|
72
74
|
#
|
|
73
75
|
# @param product_currency [Symbol, Dodopayments::Models::Currency, nil] Optional currency of the product price. If not specified, defaults to the curren
|
|
74
76
|
#
|
|
@@ -101,8 +101,8 @@ module Dodopayments
|
|
|
101
101
|
# @!attribute metadata
|
|
102
102
|
# Additional metadata for the subscription Defaults to empty if not specified
|
|
103
103
|
#
|
|
104
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
105
|
-
optional :metadata, Dodopayments::Internal::Type::HashOf[
|
|
104
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
105
|
+
optional :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
106
106
|
|
|
107
107
|
# @!attribute on_demand
|
|
108
108
|
#
|
|
@@ -207,7 +207,7 @@ module Dodopayments
|
|
|
207
207
|
#
|
|
208
208
|
# @param mandate_min_amount_inr_paise [Integer, nil] Override the merchant-level mandate floor (in INR paise) for INR
|
|
209
209
|
#
|
|
210
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata for the subscription
|
|
210
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata for the subscription
|
|
211
211
|
#
|
|
212
212
|
# @param on_demand [Dodopayments::Models::OnDemandSubscription, nil]
|
|
213
213
|
#
|
|
@@ -19,8 +19,8 @@ module Dodopayments
|
|
|
19
19
|
# @!attribute metadata
|
|
20
20
|
# Additional metadata associated with the subscription
|
|
21
21
|
#
|
|
22
|
-
# @return [Hash{Symbol=>String}]
|
|
23
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
22
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
23
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
24
24
|
|
|
25
25
|
# @!attribute payment_id
|
|
26
26
|
# First payment id for the subscription
|
|
@@ -91,7 +91,7 @@ module Dodopayments
|
|
|
91
91
|
#
|
|
92
92
|
# @param customer [Dodopayments::Models::CustomerLimitedDetails] Customer details associated with this subscription
|
|
93
93
|
#
|
|
94
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata associated with the subscription
|
|
94
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata associated with the subscription
|
|
95
95
|
#
|
|
96
96
|
# @param payment_id [String] First payment id for the subscription
|
|
97
97
|
#
|
|
@@ -44,8 +44,8 @@ module Dodopayments
|
|
|
44
44
|
# @!attribute metadata
|
|
45
45
|
# Additional custom data associated with the subscription
|
|
46
46
|
#
|
|
47
|
-
# @return [Hash{Symbol=>String}]
|
|
48
|
-
required :metadata, Dodopayments::Internal::Type::HashOf[
|
|
47
|
+
# @return [Hash{Symbol=>String, Float, Boolean}]
|
|
48
|
+
required :metadata, -> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] }
|
|
49
49
|
|
|
50
50
|
# @!attribute next_billing_date
|
|
51
51
|
# Timestamp of the next scheduled billing. Indicates the end of current billing
|
|
@@ -200,7 +200,7 @@ module Dodopayments
|
|
|
200
200
|
#
|
|
201
201
|
# @param discounts [Array<Dodopayments::Models::SubscriptionListResponse::Discount>] All stacked discounts applied, in order of application
|
|
202
202
|
#
|
|
203
|
-
# @param metadata [Hash{Symbol=>String}] Additional custom data associated with the subscription
|
|
203
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional custom data associated with the subscription
|
|
204
204
|
#
|
|
205
205
|
# @param next_billing_date [Time] Timestamp of the next scheduled billing. Indicates the end of current billing pe
|
|
206
206
|
#
|
|
@@ -72,9 +72,12 @@ module Dodopayments
|
|
|
72
72
|
optional :disable_on_demand, -> { Dodopayments::SubscriptionUpdateParams::DisableOnDemand }, nil?: true
|
|
73
73
|
|
|
74
74
|
# @!attribute metadata
|
|
75
|
+
# Arbitrary key-value metadata. Values can be string, integer, number, or boolean.
|
|
75
76
|
#
|
|
76
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
77
|
-
optional :metadata,
|
|
77
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
78
|
+
optional :metadata,
|
|
79
|
+
-> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] },
|
|
80
|
+
nil?: true
|
|
78
81
|
|
|
79
82
|
# @!attribute next_billing_date
|
|
80
83
|
#
|
|
@@ -115,7 +118,7 @@ module Dodopayments
|
|
|
115
118
|
#
|
|
116
119
|
# @param disable_on_demand [Dodopayments::Models::SubscriptionUpdateParams::DisableOnDemand, nil]
|
|
117
120
|
#
|
|
118
|
-
# @param metadata [Hash{Symbol=>String}, nil]
|
|
121
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Arbitrary key-value metadata. Values can be string, integer, number, or boolean.
|
|
119
122
|
#
|
|
120
123
|
# @param next_billing_date [Time, nil]
|
|
121
124
|
#
|
|
@@ -67,8 +67,10 @@ module Dodopayments
|
|
|
67
67
|
# Metadata for the payment. If not passed, the metadata of the subscription will
|
|
68
68
|
# be taken
|
|
69
69
|
#
|
|
70
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
71
|
-
optional :metadata,
|
|
70
|
+
# @return [Hash{Symbol=>String, Float, Boolean}, nil]
|
|
71
|
+
optional :metadata,
|
|
72
|
+
-> { Dodopayments::Internal::Type::HashOf[union: Dodopayments::MetadataItem] },
|
|
73
|
+
nil?: true
|
|
72
74
|
|
|
73
75
|
# @!attribute on_payment_failure
|
|
74
76
|
# Controls behavior when the plan change payment fails.
|
|
@@ -104,7 +106,7 @@ module Dodopayments
|
|
|
104
106
|
#
|
|
105
107
|
# @param effective_at [Symbol, Dodopayments::Models::UpdateSubscriptionPlanReq::EffectiveAt] When to apply the plan change.
|
|
106
108
|
#
|
|
107
|
-
# @param metadata [Hash{Symbol=>String}, nil] Metadata for the payment. If not passed, the metadata of the subscription will b
|
|
109
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Metadata for the payment. If not passed, the metadata of the subscription will b
|
|
108
110
|
#
|
|
109
111
|
# @param on_payment_failure [Symbol, Dodopayments::Models::UpdateSubscriptionPlanReq::OnPaymentFailure, nil] Controls behavior when the plan change payment fails.
|
|
110
112
|
|
data/lib/dodopayments/models.rb
CHANGED
|
@@ -165,6 +165,8 @@ module Dodopayments
|
|
|
165
165
|
|
|
166
166
|
CustomerListCreditEntitlementsParams = Dodopayments::Models::CustomerListCreditEntitlementsParams
|
|
167
167
|
|
|
168
|
+
CustomerListEntitlementGrantsParams = Dodopayments::Models::CustomerListEntitlementGrantsParams
|
|
169
|
+
|
|
168
170
|
CustomerListEntitlementsParams = Dodopayments::Models::CustomerListEntitlementsParams
|
|
169
171
|
|
|
170
172
|
CustomerListParams = Dodopayments::Models::CustomerListParams
|
|
@@ -263,6 +265,10 @@ module Dodopayments
|
|
|
263
265
|
|
|
264
266
|
EventInput = Dodopayments::Models::EventInput
|
|
265
267
|
|
|
268
|
+
Feature = Dodopayments::Models::Feature
|
|
269
|
+
|
|
270
|
+
FeatureType = Dodopayments::Models::FeatureType
|
|
271
|
+
|
|
266
272
|
FilterOperator = Dodopayments::Models::FilterOperator
|
|
267
273
|
|
|
268
274
|
FilterType = Dodopayments::Models::FilterType
|
|
@@ -312,6 +318,8 @@ module Dodopayments
|
|
|
312
318
|
# @type [Dodopayments::Internal::Type::Converter]
|
|
313
319
|
Metadata = Dodopayments::Models::Metadata
|
|
314
320
|
|
|
321
|
+
MetadataItem = Dodopayments::Models::MetadataItem
|
|
322
|
+
|
|
315
323
|
Meter = Dodopayments::Models::Meter
|
|
316
324
|
|
|
317
325
|
MeterAggregation = Dodopayments::Models::MeterAggregation
|
|
@@ -38,7 +38,7 @@ module Dodopayments
|
|
|
38
38
|
#
|
|
39
39
|
# @param mandate_min_amount_inr_paise [Integer, nil] Override the merchant-level mandate floor (in INR paise) for INR
|
|
40
40
|
#
|
|
41
|
-
# @param metadata [Hash{Symbol=>String}, nil] Additional metadata associated with the payment. Defaults to empty if not provid
|
|
41
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Additional metadata associated with the payment. Defaults to empty if not provid
|
|
42
42
|
#
|
|
43
43
|
# @param minimal_address [Boolean] If true, only zipcode is required when confirm is true; other address fields rem
|
|
44
44
|
#
|
|
@@ -125,7 +125,7 @@ module Dodopayments
|
|
|
125
125
|
#
|
|
126
126
|
# @param mandate_min_amount_inr_paise [Integer, nil] Override the merchant-level mandate floor (in INR paise) for INR
|
|
127
127
|
#
|
|
128
|
-
# @param metadata [Hash{Symbol=>String}, nil] Additional metadata associated with the payment. Defaults to empty if not provid
|
|
128
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Additional metadata associated with the payment. Defaults to empty if not provid
|
|
129
129
|
#
|
|
130
130
|
# @param minimal_address [Boolean] If true, only zipcode is required when confirm is true; other address fields rem
|
|
131
131
|
#
|
|
@@ -144,7 +144,7 @@ module Dodopayments
|
|
|
144
144
|
#
|
|
145
145
|
# @param idempotency_key [String, nil] Body param: Idempotency key to prevent duplicate entries
|
|
146
146
|
#
|
|
147
|
-
# @param metadata [Hash{Symbol=>String}, nil] Body param: Optional metadata (max 50 key-value pairs, key max 40 chars, value m
|
|
147
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Body param: Optional metadata (max 50 key-value pairs, key max 40 chars, value m
|
|
148
148
|
#
|
|
149
149
|
# @param reason [String, nil] Body param: Human-readable reason for the entry
|
|
150
150
|
#
|
|
@@ -15,7 +15,7 @@ module Dodopayments
|
|
|
15
15
|
#
|
|
16
16
|
# @param name [String]
|
|
17
17
|
#
|
|
18
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata for the customer
|
|
18
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata for the customer
|
|
19
19
|
#
|
|
20
20
|
# @param phone_number [String, nil]
|
|
21
21
|
#
|
|
@@ -59,7 +59,7 @@ module Dodopayments
|
|
|
59
59
|
#
|
|
60
60
|
# @param email [String, nil]
|
|
61
61
|
#
|
|
62
|
-
# @param metadata [Hash{Symbol=>String}, nil] Additional metadata for the customer
|
|
62
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Additional metadata for the customer
|
|
63
63
|
#
|
|
64
64
|
# @param name [String, nil]
|
|
65
65
|
#
|
|
@@ -158,6 +158,39 @@ module Dodopayments
|
|
|
158
158
|
)
|
|
159
159
|
end
|
|
160
160
|
|
|
161
|
+
# List all of a customer's entitlement grants across every entitlement. One row
|
|
162
|
+
# per grant.
|
|
163
|
+
#
|
|
164
|
+
# @overload list_entitlement_grants(customer_id, integration_type: nil, page_number: nil, page_size: nil, status: nil, request_options: {})
|
|
165
|
+
#
|
|
166
|
+
# @param customer_id [String] Customer ID
|
|
167
|
+
#
|
|
168
|
+
# @param integration_type [Symbol, Dodopayments::Models::CustomerListEntitlementGrantsParams::IntegrationType] Filter by integration type (e.g. `feature_flag`)
|
|
169
|
+
#
|
|
170
|
+
# @param page_number [Integer] Page number (default 0)
|
|
171
|
+
#
|
|
172
|
+
# @param page_size [Integer] Page size (default 10, max 100)
|
|
173
|
+
#
|
|
174
|
+
# @param status [Symbol, Dodopayments::Models::CustomerListEntitlementGrantsParams::Status] Filter by grant status
|
|
175
|
+
#
|
|
176
|
+
# @param request_options [Dodopayments::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
177
|
+
#
|
|
178
|
+
# @return [Dodopayments::Internal::DefaultPageNumberPagination<Dodopayments::Models::Entitlements::EntitlementGrant>]
|
|
179
|
+
#
|
|
180
|
+
# @see Dodopayments::Models::CustomerListEntitlementGrantsParams
|
|
181
|
+
def list_entitlement_grants(customer_id, params = {})
|
|
182
|
+
parsed, options = Dodopayments::CustomerListEntitlementGrantsParams.dump_request(params)
|
|
183
|
+
query = Dodopayments::Internal::Util.encode_query_params(parsed)
|
|
184
|
+
@client.request(
|
|
185
|
+
method: :get,
|
|
186
|
+
path: ["customers/%1$s/entitlement-grants", customer_id],
|
|
187
|
+
query: query,
|
|
188
|
+
page: Dodopayments::Internal::DefaultPageNumberPagination,
|
|
189
|
+
model: Dodopayments::Entitlements::EntitlementGrant,
|
|
190
|
+
options: options
|
|
191
|
+
)
|
|
192
|
+
end
|
|
193
|
+
|
|
161
194
|
# List all entitlement grants delivered (or in flight) to a customer.
|
|
162
195
|
#
|
|
163
196
|
# @overload list_entitlements(customer_id, request_options: {})
|
|
@@ -19,7 +19,7 @@ module Dodopayments
|
|
|
19
19
|
#
|
|
20
20
|
# @param expires_at [Time, nil] When the discount expires, if ever.
|
|
21
21
|
#
|
|
22
|
-
# @param metadata [Hash{Symbol=>String}] Additional metadata for the discount
|
|
22
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}] Additional metadata for the discount
|
|
23
23
|
#
|
|
24
24
|
# @param name [String, nil]
|
|
25
25
|
#
|
|
@@ -82,7 +82,7 @@ module Dodopayments
|
|
|
82
82
|
#
|
|
83
83
|
# @param expires_at [Time, nil]
|
|
84
84
|
#
|
|
85
|
-
# @param metadata [Hash{Symbol=>String}, nil] Additional metadata for the discount
|
|
85
|
+
# @param metadata [Hash{Symbol=>String, Float, Boolean}, nil] Additional metadata for the discount
|
|
86
86
|
#
|
|
87
87
|
# @param name [String, nil]
|
|
88
88
|
#
|