Class: Dodopayments::Models::SubscriptionListResponse::Discount
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Dodopayments::Models::SubscriptionListResponse::Discount
- Defined in:
- lib/dodopayments/models/subscription_list_response.rb,
sig/dodopayments/models/subscription_list_response.rbs
Instance Attribute Summary collapse
-
#discount_cycles_remaining ⇒ Integer?
Remaining billing cycles for this discount on this subscription.
-
#discount_id ⇒ String
The unique discount ID.
Instance Method Summary collapse
-
#initialize(discount_id:, discount_cycles_remaining: nil) ⇒ Object
constructor
Lightweight discount info for list endpoints.
- #to_hash ⇒ {
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(discount_id:, discount_cycles_remaining: nil) ⇒ Object
Lightweight discount info for list endpoints. Array order represents position (no explicit position field).
268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 |
# File 'lib/dodopayments/models/subscription_list_response.rb', line 268 class Discount < Dodopayments::Internal::Type::BaseModel # @!attribute discount_id # The unique discount ID # # @return [String] required :discount_id, String # @!attribute discount_cycles_remaining # Remaining billing cycles for this discount on this subscription # # @return [Integer, nil] optional :discount_cycles_remaining, Integer, nil?: true # @!method initialize(discount_id:, discount_cycles_remaining: nil) # Lightweight discount info for list endpoints. Array order represents position # (no explicit position field). # # @param discount_id [String] The unique discount ID # # @param discount_cycles_remaining [Integer, nil] Remaining billing cycles for this discount on this subscription end |
Instance Attribute Details
#discount_cycles_remaining ⇒ Integer?
Remaining billing cycles for this discount on this subscription
279 |
# File 'lib/dodopayments/models/subscription_list_response.rb', line 279 optional :discount_cycles_remaining, Integer, nil?: true |
#discount_id ⇒ String
The unique discount ID
273 |
# File 'lib/dodopayments/models/subscription_list_response.rb', line 273 required :discount_id, String |
Instance Method Details
#to_hash ⇒ {
182 |
# File 'sig/dodopayments/models/subscription_list_response.rbs', line 182
def to_hash: -> {
|