Class: Stigg::Models::V1::ContractCreateParams::Subscription::NewSubscription::Addon

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/stigg/models/v1/contract_create_params.rb,
sig/stigg/models/v1/contract_create_params.rbs

Instance Attribute Summary collapse

Instance Method Summary collapse

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(customer_id:, plan_id:, id: nil, addons: nil, applied_coupon: nil, await_payment_confirmation: nil, billing_country_code: nil, billing_cycle_anchor: nil, billing_id: nil, billing_information: nil, billing_period: nil, budget: nil, cancellation_date: nil, charges: nil, checkout_options: nil, entitlements: nil, metadata: nil, minimum_spend: nil, paying_customer_id: nil, payment_collection_method: nil, price_overrides: nil, resource_id: nil, salesforce_id: nil, schedule_strategy: nil, start_date: nil, trial_override_configuration: nil, unit_quantity: nil) ⇒ Addon

A new subscription to create, using the same body the provision-subscription endpoint accepts

Parameters:



377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
# File 'lib/stigg/models/v1/contract_create_params.rb', line 377

class Addon < Stigg::Internal::Type::BaseModel
  # @!attribute id
  #   Addon ID
  #
  #   @return [String]
  required :id, String

  # @!attribute quantity
  #   Number of addon instances
  #
  #   @return [Integer]
  required :quantity, Integer

  # @!method initialize(id:, quantity:)
  #   Addon configuration
  #
  #   @param id [String] Addon ID
  #
  #   @param quantity [Integer] Number of addon instances
end

Instance Attribute Details

#idString

Addon ID

Parameters:

  • value (String)

Returns:

  • (String)


382
# File 'lib/stigg/models/v1/contract_create_params.rb', line 382

required :id, String

#quantityInteger

Number of addon instances

Parameters:

  • value (Integer)

Returns:

  • (Integer)


388
# File 'lib/stigg/models/v1/contract_create_params.rb', line 388

required :quantity, Integer

Instance Method Details

#to_hash{ id: String, quantity: Integer }

Returns:

  • ({ id: String, quantity: Integer })


318
# File 'sig/stigg/models/v1/contract_create_params.rbs', line 318

def to_hash: -> { id: String, quantity: Integer }