Class: Chartmogul::Import::Subscription

Inherits:
Base
  • Object
show all
Defined in:
lib/chartmogul/import/subscription.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#create, #delete

Methods inherited from Base

method_missing

Instance Attribute Details

#customer_uuidObject (readonly)

Returns the value of attribute customer_uuid


4
5
6
# File 'lib/chartmogul/import/subscription.rb', line 4

def customer_uuid
  @customer_uuid
end

Instance Method Details

#cancel(uuid:, cancelled_at:) ⇒ Object


11
12
13
14
15
# File 'lib/chartmogul/import/subscription.rb', line 11

def cancel(uuid:, cancelled_at:)
  Chartmogul.patch_resource(
    subscription_end_point(uuid), cancelled_at: cancelled_at
  )
end

#list(customer_uuid:, **listing_options) ⇒ Object


6
7
8
9
# File 'lib/chartmogul/import/subscription.rb', line 6

def list(customer_uuid:, **listing_options)
  @customer_uuid = customer_uuid
  super(listing_options)
end