Class: Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/resources/subscription_schedule.rb

Defined Under Namespace

Classes: Duration

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(duration: nil, timestamp: nil, type: nil) ⇒ DiscountEnd

Returns a new instance of DiscountEnd.



2201
2202
2203
2204
2205
# File 'lib/stripe/resources/subscription_schedule.rb', line 2201

def initialize(duration: nil, timestamp: nil, type: nil)
  @duration = duration
  @timestamp = timestamp
  @type = type
end

Instance Attribute Details

#durationObject

Time span for the redeemed discount.



2195
2196
2197
# File 'lib/stripe/resources/subscription_schedule.rb', line 2195

def duration
  @duration
end

#timestampObject

A precise Unix timestamp for the discount to end. Must be in the future.



2197
2198
2199
# File 'lib/stripe/resources/subscription_schedule.rb', line 2197

def timestamp
  @timestamp
end

#typeObject

The type of calculation made to determine when the discount ends.



2199
2200
2201
# File 'lib/stripe/resources/subscription_schedule.rb', line 2199

def type
  @type
end