Class: TerminalShop::Models::SubscriptionAPI
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- TerminalShop::Models::SubscriptionAPI
- Defined in:
- lib/terminal_shop/models/subscription.rb
Direct Known Subclasses
Defined Under Namespace
Modules: Schedule
Instance Attribute Summary collapse
-
#address_id ⇒ String
ID of the shipping address used for the subscription.
-
#card_id ⇒ String
ID of the card used for the subscription.
-
#created ⇒ String
Date the subscription was created.
-
#id ⇒ String
Unique object identifier.
-
#next_ ⇒ String?
Next shipment and billing date for the subscription.
-
#price ⇒ Integer
Price of the subscription in cents (USD).
-
#product_variant_id ⇒ String
ID of the product variant being subscribed to.
-
#quantity ⇒ Integer
Quantity of the subscription.
-
#schedule ⇒ TerminalShop::Models::SubscriptionAPI::Schedule::Fixed, ...
Schedule of the subscription.
Instance Method Summary collapse
-
#initialize(id:, address_id:, card_id:, created:, price:, product_variant_id:, quantity:, next_: nil, schedule: nil) ⇒ Object
constructor
Some parameter documentations has been truncated, see SubscriptionAPI for more details.
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(id:, address_id:, card_id:, created:, price:, product_variant_id:, quantity:, next_: nil, schedule: nil) ⇒ Object
Some parameter documentations has been truncated, see TerminalShop::Models::SubscriptionAPI for more details.
Subscription to a Terminal shop product.
|
|
# File 'lib/terminal_shop/models/subscription.rb', line 60
|
Instance Attribute Details
#address_id ⇒ String
ID of the shipping address used for the subscription.
16 |
# File 'lib/terminal_shop/models/subscription.rb', line 16 required :address_id, String, api_name: :addressID |
#card_id ⇒ String
ID of the card used for the subscription.
22 |
# File 'lib/terminal_shop/models/subscription.rb', line 22 required :card_id, String, api_name: :cardID |
#created ⇒ String
Date the subscription was created.
28 |
# File 'lib/terminal_shop/models/subscription.rb', line 28 required :created, String |
#id ⇒ String
Unique object identifier. The format and length of IDs may change over time.
10 |
# File 'lib/terminal_shop/models/subscription.rb', line 10 required :id, String |
#next_ ⇒ String?
Next shipment and billing date for the subscription.
52 |
# File 'lib/terminal_shop/models/subscription.rb', line 52 optional :next_, String, api_name: :next |
#price ⇒ Integer
Price of the subscription in cents (USD).
34 |
# File 'lib/terminal_shop/models/subscription.rb', line 34 required :price, Integer |
#product_variant_id ⇒ String
ID of the product variant being subscribed to.
40 |
# File 'lib/terminal_shop/models/subscription.rb', line 40 required :product_variant_id, String, api_name: :productVariantID |
#quantity ⇒ Integer
Quantity of the subscription.
46 |
# File 'lib/terminal_shop/models/subscription.rb', line 46 required :quantity, Integer |
#schedule ⇒ TerminalShop::Models::SubscriptionAPI::Schedule::Fixed, ...
Schedule of the subscription.
58 |
# File 'lib/terminal_shop/models/subscription.rb', line 58 optional :schedule, union: -> { TerminalShop::SubscriptionAPI::Schedule } |