Class: Stripe::PromotionCodeCreateParams::Promotion

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/params/promotion_code_create_params.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(coupon: nil, type: nil) ⇒ Promotion

Returns a new instance of Promotion.



12
13
14
15
# File 'lib/stripe/params/promotion_code_create_params.rb', line 12

def initialize(coupon: nil, type: nil)
  @coupon = coupon
  @type = type
end

Instance Attribute Details

#couponObject

If promotion ‘type` is `coupon`, the coupon for this promotion code.



8
9
10
# File 'lib/stripe/params/promotion_code_create_params.rb', line 8

def coupon
  @coupon
end

#typeObject

Specifies the type of promotion.



10
11
12
# File 'lib/stripe/params/promotion_code_create_params.rb', line 10

def type
  @type
end